Messages in this thread | | | Date | Sun, 2 Jul 2000 19:11:26 +0100 (BST) | From | Tigran Aivazian <> | Subject | Re: closefd: closes a file of any process |
| |
On Sat, 1 Jul 2000, Horst von Brand wrote:
> Jamie Lokier <lk@tantalophile.demon.co.uk> said: > > Werner Almesberger wrote: > > > Your original proposal, moving to nullfs, gives you simply the possibility > > > to have a "hard" or a "soft" failure. The basic assumption is still that > > > the program didn't really need to access the file in the first place. > > > > So I'm still wondering if a clean exit/kill wouldn't be better in almost > > > all cases. > > > revoke() without killing the process would be quite useful for floppies > > removed from the drive... > > Which presuposes applications capable of handling said event gracefully. > I.e., zilch. >
no, incorrect. It doesn't presuppose anything _at all_!
The point of revoking or forcibly umounting is _not_ to satisfy some nasty applications (if it were we wouldn't be SIGKILLing them first, see fuser -k manpage to see what it does (yes, there is an non-portable -signal parameter but probably nobody uses it)). The point is to be able to free the underlying resources in a consistent manner, consistent filesystem-wise and obviously not necessarily application-wise. The kernel can never guarantee application consistency and shouldn't even try to.
Therefore, both BSD-style revoke(2) and Solaris8 style generic forced umount will be generally useful and require no assumptions on applications side (for a simple reason that "we can't and therefore don't care" ;)
Regards, Tigran
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/
| |