From owner-cvs-all Sun May 28 22:11:16 2000 Delivered-To: cvs-all@freebsd.org Received: from gidora.zeta.org.au (gidora.zeta.org.au [203.26.10.25]) by hub.freebsd.org (Postfix) with SMTP id 5EEFF37BA4C for ; Sun, 28 May 2000 22:10:58 -0700 (PDT) (envelope-from bde@zeta.org.au) Received: (qmail 18173 invoked from network); 29 May 2000 05:10:54 -0000 Received: from unknown (HELO bde.zeta.org.au) (203.2.228.102) by gidora.zeta.org.au with SMTP; 29 May 2000 05:10:54 -0000 Date: Mon, 29 May 2000 15:10:50 +1000 (EST) From: Bruce Evans X-Sender: bde@besplex.bde.org To: Doug Barton Cc: Jeroen Ruigrok van der Werven , cvs-committers@FreeBSD.ORG, cvs-all@FreeBSD.ORG Subject: Re: cvs commit: src/etc rc In-Reply-To: <39318FE0.604973F3@gorean.org> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-cvs-all@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On Sun, 28 May 2000, Doug Barton wrote: > Bruce Evans wrote: > > > > To: doug@gorean.com > > I'm @gorean.org. I'd never dis' you like that Bruce. :) You are of Oops. There is a gorean.com, and it seems to have blackholed the mail. > course exactly correct, I don't know what I was thinking there. The > attached patch does the right thing, tested both with and without nfs > mounts in /etc/fstab. > Index: rc > =================================================================== > RCS file: /usr/ncvs/src/etc/rc,v > retrieving revision 1.216 > diff -u -r1.216 rc > --- rc 2000/05/11 06:31:59 1.216 > +++ rc 2000/05/28 20:40:41 > @@ -202,11 +202,14 @@ > esac > > # Mount NFS filesystems if present in /etc/fstab > -if mount -d -a -t nfs | grep -q nfs >/dev/null 2>&1; then > +test_nfs_in_fstab=`mount -d -a -t nfs` > +case "${test_nfs_in_fstab}" in > +*mount_nfs*) > echo -n "Mounting NFS file systems" > mount -a -t nfs > echo . > -fi > + ;; > +esac > ... I think this can be simplified to if [ "`mount -d -a -t nfs`" != "" ]; then ... (since -t nfs already filters out everything that doesn't match *mount_nfs*). While testing this, I noticed that mount -a always remounts "/". "/" is special because mount -u is implicit for it. However, null updates probably shouldn't be done. Bruce To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message