From owner-svn-src-head@FreeBSD.ORG Wed Jun 10 19:03:23 2009 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id AC0BD1065789; Wed, 10 Jun 2009 19:03:23 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 9A8878FC29; Wed, 10 Jun 2009 19:03:23 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id n5AJ3NoI023066; Wed, 10 Jun 2009 19:03:23 GMT (envelope-from avg@svn.freebsd.org) Received: (from avg@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id n5AJ3Nt6023064; Wed, 10 Jun 2009 19:03:23 GMT (envelope-from avg@svn.freebsd.org) Message-Id: <200906101903.n5AJ3Nt6023064@svn.freebsd.org> From: Andriy Gapon Date: Wed, 10 Jun 2009 19:03:23 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r193944 - in head/etc: defaults rc.d X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 10 Jun 2009 19:03:24 -0000 Author: avg Date: Wed Jun 10 19:03:23 2009 New Revision: 193944 URL: http://svn.freebsd.org/changeset/base/193944 Log: rc.d/fsck: allow additional options for fsck_y_enable via fsck_y_flags Primary intention is to allow to pass -C option to avoid (re-)checking clean filesystems when preening fails and fsck -y kicks in. Submitted by: marck Reviewed by: current@ Approved by: jhb (mentor) MFC after: 1 week Modified: head/etc/defaults/rc.conf head/etc/rc.d/fsck Modified: head/etc/defaults/rc.conf ============================================================================== --- head/etc/defaults/rc.conf Wed Jun 10 19:02:54 2009 (r193943) +++ head/etc/defaults/rc.conf Wed Jun 10 19:03:23 2009 (r193944) @@ -83,6 +83,7 @@ geli_swap_flags="-e aes -l 256 -s 4096 - root_rw_mount="YES" # Set to NO to inhibit remounting root read-write. fsck_y_enable="NO" # Set to YES to do fsck -y if the initial preen fails. +fsck_y_flags="" # Additional flags for fsck -y background_fsck="YES" # Attempt to run fsck in the background where possible. background_fsck_delay="60" # Time to wait (seconds) before starting the fsck. netfs_types="nfs:NFS nfs4:NFS4 smbfs:SMB portalfs:PORTAL nwfs:NWFS" # Net filesystems. Modified: head/etc/rc.d/fsck ============================================================================== --- head/etc/rc.d/fsck Wed Jun 10 19:02:54 2009 (r193943) +++ head/etc/rc.d/fsck Wed Jun 10 19:03:23 2009 (r193944) @@ -44,8 +44,8 @@ fsck_start() ;; 8) if checkyesno fsck_y_enable; then - echo "File system preen failed, trying fsck -y." - fsck -y + echo "File system preen failed, trying fsck -y ${fsck_y_flags}" + fsck -y ${fsck_y_flags} case $? in 0) ;;