Re: Swap

Trond Myklebust (trond.myklebust@fys.uio.no)
21 Nov 2001 00:17:44 +0100


>>>>> " " == Dan Maas <dmaas@dcine.com> writes:

> But NFS still allows atomic rename() right? Isn't it considered
> essential to write the new executable or library under a
> different name, and then atomically rename() over the old one?
> If you write() directly into the executable, you will get what
> you deserve...

Atomic rename works fine, on NFS, so if you just rename the old
library, you're quite safe. The bugs start to surface if you:

a) Reuse the the old library's inode by doing something along the
lines of open("lib.so",O_TRUNC|O_WRONLY).
or
b) erase the old library.

Cheers,
Trond
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/