From owner-svn-src-all@freebsd.org Sat Mar 10 14:10:21 2018 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 29073F3A98F for ; Sat, 10 Mar 2018 14:10:21 +0000 (UTC) (envelope-from ian@freebsd.org) Received: from outbound1a.eu.mailhop.org (outbound1a.eu.mailhop.org [52.58.109.202]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id A8ED574D18 for ; Sat, 10 Mar 2018 14:10:20 +0000 (UTC) (envelope-from ian@freebsd.org) X-MHO-User: c1424ca3-246c-11e8-91c6-33ffc249f3e8 X-Report-Abuse-To: https://support.duocircle.com/support/solutions/articles/5000540958-duocircle-standard-smtp-abuse-information X-Originating-IP: 67.177.211.60 X-Mail-Handler: DuoCircle Outbound SMTP Received: from ilsoft.org (unknown [67.177.211.60]) by outbound1.eu.mailhop.org (Halon) with ESMTPSA id c1424ca3-246c-11e8-91c6-33ffc249f3e8; Sat, 10 Mar 2018 14:10:16 +0000 (UTC) Received: from rev (rev [172.22.42.240]) by ilsoft.org (8.15.2/8.15.2) with ESMTP id w2AEABHB010938; Sat, 10 Mar 2018 07:10:11 -0700 (MST) (envelope-from ian@freebsd.org) Message-ID: <1520691011.84937.115.camel@freebsd.org> Subject: Re: svn commit: r328013 - head/sbin/fsck_ffs From: Ian Lepore To: David Bright Cc: Mark Johnston , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Date: Sat, 10 Mar 2018 07:10:11 -0700 In-Reply-To: References: <201801151925.w0FJPCKA019434@repo.freebsd.org> <20180309220940.GG6174@raichu> <1520634689.84937.74.camel@freebsd.org> Content-Type: text/plain; charset="windows-1251" X-Mailer: Evolution 3.18.5.1 FreeBSD GNOME Team Port Mime-Version: 1.0 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 10 Mar 2018 14:10:21 -0000 On Fri, 2018-03-09 at 21:36 -0500, David Bright wrote: > On Mar 9, 2018, at 17:31, Ian Lepore wrote: > > > > > > On Fri, 2018-03-09 at 17:09 -0500, Mark Johnston wrote: > > > > > > > > > etc/rc.d/fsck doesn't know how to interpret the new exit code and > > > now > > > just drops to a single-user shell when it is encountered. […] > > > > > > Is there any reason etc/rc.d/fsck shouldn't automatically retry > > > (up to > This is, in fact, the reason that I made the change I did. I was > trying to put in a retry loop to rc.d/fsck, but found that I couldn’t > get it to work because fsck and fsck_ffs were not exiting with non- > zero status. The drop to single user is not really due to the > specific (new) error code of 16, it is due to the fact that fsck_ffs > is now exiting with a non-zero status when it hasn’t completely > cleaned the file system; /any/ non-zero status would cause the > current rc.d/fsck script to go to single user. Prior to my change, > fsck_ffs was exiting with a zero status even though it had not > completely cleaned the filesystem and told the user to run it again. > > > > > > > fsck_ffs already has a -R flag to automatically retry, wouldn't > > that be > > a better mechanism for handling this new type of retry? > That’s true; however, there is currently no way to pass that flag > through the filesystem-agnostic fsck wrapper called from rc.d/fsck to > the filesystem-specific fsck_ffs program that it calls. One could > implement a similar flag on the fsck wrapper to be passed along to > the filesystem-specific checker, but I think fsck_ffs is the only one > that currently implements such a flag.  > > fsck -T ffs:-R -- Ian