From owner-freebsd-current@FreeBSD.ORG Wed Jun 20 17:25:14 2012 Return-Path: Delivered-To: current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id BB89A106564A; Wed, 20 Jun 2012 17:25:14 +0000 (UTC) (envelope-from brooks@lor.one-eyed-alien.net) Received: from lor.one-eyed-alien.net (lor.one-eyed-alien.net [69.66.77.232]) by mx1.freebsd.org (Postfix) with ESMTP id 1FA0F8FC15; Wed, 20 Jun 2012 17:25:14 +0000 (UTC) Received: from lor.one-eyed-alien.net (localhost [127.0.0.1]) by lor.one-eyed-alien.net (8.14.4/8.14.4) with ESMTP id q5KHNqdF005389; Wed, 20 Jun 2012 12:23:52 -0500 (CDT) (envelope-from brooks@lor.one-eyed-alien.net) Received: (from brooks@localhost) by lor.one-eyed-alien.net (8.14.4/8.14.4/Submit) id q5KHNqXT005388; Wed, 20 Jun 2012 12:23:52 -0500 (CDT) (envelope-from brooks) Date: Wed, 20 Jun 2012 12:23:52 -0500 From: Brooks Davis To: John Baldwin Message-ID: <20120620172352.GA97444@lor.one-eyed-alien.net> References: <201206200935.27511.jhb@freebsd.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="WIyZ46R2i8wDzkSu" Content-Disposition: inline In-Reply-To: <201206200935.27511.jhb@freebsd.org> User-Agent: Mutt/1.5.21 (2010-09-15) Cc: Bjoern Zeeb , current@freebsd.org Subject: Re: [PATCH] Trim some noise from the daily disk check X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 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: Wed, 20 Jun 2012 17:25:14 -0000 --WIyZ46R2i8wDzkSu Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Jun 20, 2012 at 09:35:27AM -0400, John Baldwin wrote: > The daily periodic e-mails for my boxes always include useless output fro= m=20 > dump -W. I think the daily e-mail should only do that if the sysadmin is= =20 > actually using dump. The patch below skips the dump reporting it=20 > /etc/dumpdates doesn't exist or exists and is an empty file (the latter i= s=20 > what you get out-of-the-box): >=20 > Index: 400.status-disks > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > --- 400.status-disks (revision 237227) > +++ 400.status-disks (working copy) > @@ -19,13 +19,16 @@ case "$daily_status_disks_enable" in > df $daily_status_disks_df_flags && rc=3D1 || rc=3D3 > =20 > # display which filesystems need backing up > - if ! [ -f /etc/fstab ]; then > - export PATH_FSTAB=3D/dev/null > + if [ -s /etc/dumpdates ]; then > + if ! [ -f /etc/fstab ]; then > + export PATH_FSTAB=3D/dev/null > + fi > + > + echo "" > + dump W || rc=3D3 > fi > + ;; > =20 > - echo "" > - dump W || rc=3D3;; > - > *) rc=3D0;; > esac > =20 > Thoughts? This seems sensible to me. -- Brooks --WIyZ46R2i8wDzkSu Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.11 (FreeBSD) iD8DBQFP4gcnXY6L6fI4GtQRAgIhAJ4iUoW4pVm+ejmoikKjdZAiOzFjmQCggO/H /9C426YZI7nW4EkEHQXtqeM= =2sVV -----END PGP SIGNATURE----- --WIyZ46R2i8wDzkSu--