FS damage

Richard Gooch (rgooch@atnf.csiro.au)
Wed, 21 Aug 1996 12:12:51 +1000

Hi, all. Last night I had a system hang while the X server was
starting up, and lost many files from the fsck -A -a cleanup. Some
files were in /dev (tty1 tty2 tty), which is possibly expected since
the files were opened read-write, but what I didn't expect was that
files such as : /usr/X11R6/lib/X11/rgb.txt (which only has read
access) were also removed by fsck. Tracing the server I note that
rgb.txt is opened read-only, mmaped with PROT_READ|PROT_WRITE, closed
and unmapped. After this the server starts probing the hardware, and
sometime later it hangs the machine.
This would seem to be a bug in the FS code, since the file was not
written to, and hence there should be nothing to flush from the buffer
cache. Does anyone have any clues as to what's going on?
I'm running kernel 2.0.0, libc 5.3.7 with ext2fs filesystems.