bug-gnu-utils
[Top][All Lists]
Advanced

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

Error in diff reporting


From: Marty
Subject: Error in diff reporting
Date: Thu, 24 Feb 2005 14:47:35 -0500
User-agent: Mozilla/5.0 (X11; U; Linux i586; en-US; rv:1.7.5) Gecko/20050105 Debian/1.7.5-1

Hello,

I have my root filesystem backed up to partition /dev/hda3.
I used the following command (in a single line script named
"compare-dirs") to compare the two directory trees:

diff -rq $1 $2  2>>/dev/null |egrep -v 'fifo|socket|special'

The command I used to invoke the script was:

# compare-dirs /mnt/hda3/ /

I had expected that the actual command to be run, after shell
expansion of the input variables, was:

diff -rq /mnt/hda3/ /  2>>/dev/null |egrep -v 'fifo|socket|special'

The output seems to confirm my expectation, except for the following
lines:

Only in /mnt/hda3: backup-diffs.txt
Only in /mnt/hda3: bin
Only in /mnt/hda3: boot
Only in /mnt/hda3: cdrom
Only in /mnt/hda3: dev
Only in /mnt/hda3: dev.bak
Only in /mnt/hda3: etc
Only in /mnt/hda3: etc.bak
Only in /mnt/hda3: etc.moved
Only in /mnt/hda3: floppy
Only in /mnt/hda3: home
Only in /mnt/hda3: initrd
Only in /mnt/hda3: initrd.img
Only in /mnt/hda3: initrd.img.2.4.18
Only in /mnt/hda3: installed-diffs-post-upgrade.txt
Only in /mnt/hda3: installed-diffs.txt
Only in /mnt/hda3: lib
Only in /mnt/hda3: lost+found
Only in /mnt/hda3: md5sums.gz
Only in /mnt/hda3: md5sums.old.gz
Only in /mnt/hda3: media
Only in /mnt/hda3: mnt
Only in /mnt/hda3: nfs
Only in /mnt/hda3: nfs-indio
Only in /mnt/hda3: opt
Only in /mnt/hda3: proc
Only in /mnt/hda3: root
Only in /mnt/hda3: sbin
Only in /mnt/hda3: sys
Only in /mnt/hda3: tmp
Only in /mnt/hda3: usr
Only in /mnt/hda3: var
Only in /mnt/indio: backup

This seems to indicate that the / directory contains no files or
subdirectories, but other lines of output indicate that the trees
were compared normally, e.g:

Files /mnt/hda3/var/log/XFree86.0.log and /var/log/XFree86.0.log differ

Obviously this output is conflicting and inconsistent, which is why I have
labelled this as a reporting bug. Since I've never seen this before I suspect it was triggered by one or both of two special (for me) conditions: the comparison
of a directory with it's own subdirectory, and/or a comparison involving /.

In spite of the presumably erroneous output, the top level of each of the
compared directory trees are identical except for a single directory,
/backup.  The contents of the /backup are larger than the rest of the /
filesystem combined.  I mention this in case it's somehow involved in
triggering the bug.

My distribution is debian testing with diff version 2.8.1-9

I hope that's enough to help you find the bug.  Let me know if you need
any more information.  Thanks,

Marty




reply via email to

[Prev in Thread] Current Thread [Next in Thread]