Well, I don't pretend to know much about kernel internals, but I would assume
the reason your case #2 isn't a problem is because the files canonicalize
to the same exact pathnames in both processes, and presumably there must
be some kernel-level synchronization of such things as renaming, based on
the pathnames... So, basically, either one or the other of those processes
will succeed, and the second will fail, because the target director no longer
exists at that point, because the first process beat it to the punch... But,
as I understand it, the issue with the arbitrarily-named hard-links is that
there's no way to recognize that "a/dir1" is the exact same thing as "b/dir1",
and hence no way to possibly synchronize these things, and prevent them from
clashing with each other... And, as such, I would think your example #3 is
also a problem...
Copyright © 2017, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds