« Return to Thread: hardlink patch series

Re: hardlink patch series

by Jeff Layton-2 :: Rate this Message:

Reply to Author | View in Thread

On Thu, 25 Jun 2009 15:55:09 -0500
Steve French <smfrench@...> wrote:

> I have been reviewing Jeff's series of (large) patches for hardlink
> fixup.   The only problem I have noticed so far is the rename error
> path - we have cached inode information which could have stale inode
> numbers for source and target (they could be up to 1 second old) so we
> may incorrectly think that source and target are different inodes in
> the EEXIST case (Jeff removed the logic which checks if source/target
> inode numbers are the same on EEXIST).  It may not matter to current
> Samba (more recent POSIX extensions) but still trying to check that
> ...
>

I don't know that there's much we can do about that. This sort of thing
is always racy with a netfs like CIFS or NFS. The VFS does do a lookup
prior to calling cifs_rename. One thing we could do is force a
revalidation when LOOKUP_RENAME_TARGET is set (for the target dentry),
but even that won't be sufficient to eliminate races 100%, and that
doesn't help the case where the inode number of the source has changed.

IMO, that's not a case to worry overly much about. I doubt it happens
much in practice and we can consider how best to clean it up later.

--
Jeff Layton <jlayton@...>
_______________________________________________
linux-cifs-client mailing list
linux-cifs-client@...
https://lists.samba.org/mailman/listinfo/linux-cifs-client

 « Return to Thread: hardlink patch series