Re: Precaution!

From: M. Warner Losh <imp_at_bsdimp.com>
Date: Tue, 06 May 2003 00:31:14 -0600 (MDT)
In message: <20030506012317.GA610_at_chihiro.leafy.idv.tw>
            leafy <leafy_at_leafy.idv.tw> writes:
: On Mon, May 05, 2003 at 11:26:25AM -0600, M. Warner Losh wrote:
: > If you booted a kernel from approximately April 15th through May 3th,
: > there were a number of small, but critical, vm bugs.  This can cause
: > file system corruption, and leave silent landmines for later.  It is
: > recommended that if you did boot these kernels, you build a newer
: > kernel, come up in single user and force an fsck on all filesystems.
: > This is to prevent 'false' panics later that are a result of the
: > corruption that might be dormant in them now.
: > 
: > Warner
: Is there a way to mimick rc.early in rcNG so that I can force a 'fsck -y' 
: remotely?

I think that background_fsck to 'no' and fsck_y_enable to 'yes' will
do approximately what you want.

Alternatively, the following script in /etc/rc.d might do the trick.
I just typed it into text editor, and ran rcorder, so you need to test
it before use:

$!/bin/sh

# BEFORE: initdiskless
# KEYWORD: FreeBSD

. /etc/rc.subr

name="force_fsck"
start_cmd="force_fsck_start"
stop_cmd=":"

force_fsck_start()
{
	fsck -y
}

load_rc_config $name
run_rc_command "$1"

Warner
Received on Mon May 05 2003 - 21:33:45 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:37:06 UTC