in reply to Unix rename behaviour

Presuming the second process has an open handle it should still see the original contents. It's similar to how processes with open descriptors can still read the file's contents even after the last link in the filesystem has been unlink'd (i.e. the way you get truly anonymous tmp files). Once that descriptor's closed (and presuming no other hard links to the original filea exist) the blocks for filea would go back on the free list and it's completely inaccessible (unless one really wants to grobble through a raw block device with dd or a filesystem debugger, of course :).

Additionally: it shouldn't matter if it's one of the owners of an open descriptor or not that does the rename call; so long as anyone's got an open descriptor it all should point to the same blocks on disk.

Replies are listed 'Best First'.