Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 21 Feb 2004 16:32:36 -0500
From:      Brian Fundakowski Feldman <green@FreeBSD.org>
To:        mckusick@FreeBSD.org, fs@FreeBSD.org
Subject:   SoftUpdates/fsck considered harmful
Message-ID:  <200402212132.i1LLWa7P057630@green.homeunix.org>

next in thread | raw e-mail | index | archive | help
I lost some data which was important to me (thankfully, not lost completely, 
as a fgrep on the hard disk was able to find a copy) because of a crash 
while SoftUpdates had some data not yet flushed.  I simply had done this:

1. vi file
2. *edit edit edit, :wq*
3. ci file
4. co -l file

That should have left me with several copies of it, but when the system 
panicked, upon reboot fsck told me:

Feb 19 21:34:46 green fsck: /dev/ad0s2e: UNREF FILE I=448021  OWNER=green MODE=100644
Feb 19 21:34:46 green fsck: /dev/ad0s2e: SIZE=6298 MTIME=Feb 19 20:38 2004  (CLEARED)

I'm certain this was the file I was editing.  SoftUpdates only guarantees 
the disk is in a valid state, not that I won't lost files, but if fsck 
hadn't decided that "UNREF" meant "the user did not intend this file to 
exist any longer", I would have had a copy of it in /home/lost+found!  Can 
there please be a less harmful behavior than simply not restoring unlinked 
files just because they appear to be "UNREF"?

-- 
Brian Fundakowski Feldman                           \'[ FreeBSD ]''''''''''\
  <> green@FreeBSD.org                               \  The Power to Serve! \
 Opinions expressed are my own.                       \,,,,,,,,,,,,,,,,,,,,,,\




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200402212132.i1LLWa7P057630>