Date: Tue, 7 Nov 2006 13:01:45 +0100 (CET) From: Oliver Fromme <olli@lurza.secnetix.de> To: freebsd-geom@FreeBSD.ORG, rick-freebsd@kiwi-computer.com Subject: Re: FSCKing a RO partition Message-ID: <200611071201.kA7C1jST044243@lurza.secnetix.de> In-Reply-To: <20061106212307.GA75478@keira.kiwi-computer.com>
next in thread | previous in thread | raw e-mail | index | archive | help
Rick C. Petty wrote: > Oliver Fromme wrote: > > > > > > I also tried with the mount command and -u -r options with the same > > > result. > > > > A quick workaround would be to run "fsck -p" yourself on > > the root partition before you remount it read-write. > > Of course, if you mount root read/write in the process of booting > single-user to edit /etc/fstab, for instance, and you decide you want to > preen a la "fsck -p", you can't. Even if you use "mount -u -r /", the > preen fails on the root partition and you can't quickly check the other > file systems. This is a bug and a regression since it used to work in > 4.x just fine! Sure, it's clearly a bug that needs to be fixed. That's why I wrote "workaround" (not "solution"). > Sometimes I'm often tempted to reboot and wait 10 minutes for the BIOS > to POST just because of the effort/time to manually run fsck on each > partition. If you remember to always do "fsck -p" immediately from the > single-user prompt, you're fine. The original poster has a modified init(8) that does the remounting, so there's no need to remember anything. He just has to call "fsck -p" (and check the exit code, of course) from his code right before remounting the root FS read-write. Personally, when I enter single-user mode and need to mount any partition for writing, "fsck -p" is always the first thing I type. It's hardcoded into my fingers (and should be for every admin), so there's nothing to remember either. :-) Just to repeat again: The fact that the standard fsck fails in FreeBSD 6 after the roto FS has been remounted read-only _is_ a bug and a regression. It definitely needs to be fixed. Best regards Oliver -- Oliver Fromme, secnetix GmbH & Co. KG, Marktplatz 29, 85567 Grafing Dienstleistungen mit Schwerpunkt FreeBSD: http://www.secnetix.de/bsd Any opinions expressed in this message may be personal to the author and may not necessarily reflect the opinions of secnetix in any way. "The last good thing written in C was Franz Schubert's Symphony number 9." -- Erwin Dieterich
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200611071201.kA7C1jST044243>