From owner-freebsd-current@FreeBSD.ORG Fri Mar 26 12:09:03 2004 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id F350116A4CF for ; Fri, 26 Mar 2004 12:09:02 -0800 (PST) Received: from core.zp.ua (core.zp.ua [193.108.112.7]) by mx1.FreeBSD.org (Postfix) with ESMTP id 2E86243D2F for ; Fri, 26 Mar 2004 12:09:01 -0800 (PST) (envelope-from oleg@core.zp.ua) Received: from core.zp.ua (oleg@localhost [127.0.0.1]) by core.zp.ua with ESMTPœ id i2QK8utk025062 for ; Fri, 26 Mar 2004 22:08:56 +0200 (EET) (envelope-from oleg@core.zp.ua)œ Received: (from oleg@localhost) by core.zp.ua id i2QK8udQ025061 for freebsd-current@freebsd.org; Fri, 26 Mar 2004 22:08:56 +0200 (EET) Date: Fri, 26 Mar 2004 22:08:56 +0200 From: "Oleg V. Naumann" To: freebsd-current@freebsd.org Message-ID: <20040326200856.GG21046@core.zp.ua> Mail-Followup-To: freebsd-current@freebsd.org Mime-Version: 1.0 Content-Type: text/plain; charset=koi8-r Content-Disposition: inline User-Agent: Mutt/1.5.6i Subject: background_fsck and kernel without SOFTUPDATES X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 26 Mar 2004 20:09:03 -0000 Here is small problem. After removing 'options SOFTUPDATES' from my kernel and rebooting I noticed message from fsck: 'kernel lacks background fsck support'. After that fsck leaves fs's in the inconsistent state. Yes, I know about dependency between SOFTUPDATES and background fsck. But from my point of view it looks better if /etc/rc.d/fsck will be fallback to the traditional fsck way, if kernel lacks SOFTUPDATES support, may be in some manner as that: [root@core]/etc/rc.d# diff -u fsck.orig fsck --- fsck.orig Mon Jan 20 16:37:47 2003 +++ fsck Fri Mar 26 20:48:02 2004 @@ -36,6 +36,11 @@ echo "Starting file system checks:" case ${OSTYPE} in FreeBSD) /sbin/sysctl debug.max_softdeps > /dev/null 2>&1 + if [ $? -ne 0 ]; then + echo "warning: SOFTUPDATES not supported, fallback to the foreground check" + background_fsck="NO" + fi if checkyesno background_fsck; then fsck -F -p else It looks like fsck_ffs does check more that one sysctl which supports SOFTUPDATES, may be 'debug.max_softdeps' is not better, but idea clear here, I hope. I can fill a PR, if it is advisable. -- NO37-RIPE