[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: Distinct transactions



On Sun, Nov 11, 2001 at 07:20:30AM -0500, Charlie Woloszynski wrote:
> Mike:
> 
> But the symlink is not atomic.  when I use strace on a "ln -s -f " the system does
> an unlink then symlink.  So, if the system crashes in the middle of these actions,
> the system will not have a 'proper' configuration.
> 
> I guess I can store the targeted symlink in a second file.  If I use ordered mode,
> then the data for this file will be guaranteed to be updated before the unlink can
> proceed.
> 
> Does this sound right?
>

What about 

ln -s dir tmp; 
mv tmp target

???

> Charlie
> 
> P.S.  Is the problem with hard links of directories a limitation of ext2/ext3?
> 
> 

I don't believe so...  I mean, how do you store two parent directories in
one inode?  

Mike





[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]