Subject: Re: FFS reliability problems
To: NetBSD Kernel Technical Discussion List <tech-kern@netbsd.org>
From: None <kpneal@pobox.com>
List: tech-kern
Date: 06/12/2002 21:46:05
On Wed, Jun 12, 2002 at 04:17:35PM -0400, Greg A. Woods wrote:
> [ On Monday, June 10, 2002 at 19:51:00 (+0700), Robert Elz wrote: ]
> > Subject: Re: FFS reliability problems 
> 
> >  The situation is just the same, the kernel knows
> > that the application aborted, as fsck can infer that the system crashed.
> > The kernel knows even better than fsck does that the file in question
> > was one which was open, but had been unlinked.
> > 
> > So, should the kernel be taking such files and linking them into
> > lost+found instead of deleting them?   By your argument, that's the only
> > conclusion I think, yet it would be absurd.
> 
> I'm OK with that, and I'm sure greywolf will agree -- though perhaps in
> this case lost+found is the wrong place since the kernel could also
> remember exactly where the file was created in the first place.
> 
> Maybe someday applications will all be converted to use atexit() to
> register their cleanup routines and this silly garbage collection
> technique will no longer be necessary at which time the unlinking of an
> open file can be disallowed.  Maybe that should happen immediately and
> the issue should be forced.

Who wants to try to explain to users why sometimes they can rm a file
and sometimes they can't? 

Who wants to make upgrades of a running system impossible because
programs currently running can't be removed? I suppose you could get
around this by renaming things first, but that seems gross and a giant
leap backwards. 

Warping the way the filesystem works in order to work around broken
applications seems like the exact wrong thing to do. 

What's next? Eliminating use of mfs for /tmp because a system crash
could blow away important data that a running app *might* have *possibly*
wanted to write to a more permanent location? 

C'mon.
-- 
"A method for inducing cats to exercise consists of directing a beam of
invisible light produced by a hand-held laser apparatus onto the floor ...
in the vicinity of the cat, then moving the laser ... in an irregular way
fascinating to cats,..." -- US patent 5443036, "Method of exercising a cat"