NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: misc/40977: /var/backups/work/device.current is overly sensitive to ls(1) columnar alignment

The following reply was made to PR misc/40977; it has been noted by GNATS.

From: Taylor R Campbell <>
Cc:,,, David Holland 
Subject: Re: misc/40977: /var/backups/work/device.current is overly
        sensitive to ls(1) columnar alignment
Date: Mon, 3 Aug 2009 11:02:49 -0400

 This is a multi-part message in MIME format.
    Date: Sun, 29 Mar 2009 18:40:04 +0000 (UTC)
    From: David Holland <>
    On Sat, Mar 07, 2009 at 04:25:00AM +0000, Taylor R Campbell wrote:
    >   Any change in the columnar alignment in the listing of a
    >   single device in /var/backups/work/device.current as generated
    >   by /etc/security causes every other line to change.  This
    >   makes the RCS history accumulate excessively, about a thousand
    >   times faster than the useful information is accumulating, and
    >   renders the diffs useless for the naked eye.
    Does setting "diff_options=-uw" in security.conf produce suitable
 Sorry for the late reply.  Setting diff_options doesn't change what
 gets recorded in the RCS file; it affects only the messages that the
 security script sends by mail.  Here's a patch to the security script
 to make it do what I want, by using the -exec option to find(1) rather
 than xargs(1).  Unfortunately, this slows the security script down a
 great deal by causing it to fork many more times, but it does reduce
 informationless clutter, which causes backups to use much less disk
 space and which makes them more useful to humans.
 Perhaps find(1) should be extended with an option to set the `ls(1)
 flags' that it uses (emulates) for `find -ls', which is faster than
 either `find -exec ls' or xargs(1).
 Content-Type: text/plain; charset="ISO-8859-1"; name="security"
 Content-Transfer-Encoding: quoted-printable
 Content-Disposition: attachment; filename="security.patch"
 --- security.~1~       2009-08-03 15:00:12.000000000 +0000
 +++ security   2009-08-03 15:01:09.000000000 +0000
 @@ -673,8 +673,8 @@
        find / $ignexpr \
            \( \( -perm -u+s -a ! -type d \) -o \
               \( -perm -g+s -a ! -type d \) -o \
 -             -type b -o -type c \) -print0 | \
 -      xargs -0 ls -ldgTq | sort +9 > $LIST
 +             -type b -o -type c \) \
 +          -exec ls -ldgTq \{\} \; | sort +9 > $LIST
        ) 2> $OUTPUT

Home | Main Index | Thread Index | Old Index