bug-diffutils
[Top][All Lists]
Advanced

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

[bug-diffutils] bug#33467: bug#33467: bug#33467: "diff" can not scan dir


From: Eric Blake
Subject: [bug-diffutils] bug#33467: bug#33467: bug#33467: "diff" can not scan directories with same dev/inode
Date: Thu, 29 Nov 2018 16:39:48 -0600
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.3.0

On 11/29/18 4:32 PM, Mark Raymond wrote:
This sounds similar to a problem I have just encountered.

If I have filesystems mounted at:

     /mnt/foo
     /mnt/foo/subfs

then do

     mount --bind /mnt/foo /mnt/bar

then the contents of `/mnt/foo` and `/mnt/bar` are different, because `/mnt/foo/subfs` has contents but `/mnt/bar/subfs` does not have contents. However

     diff -r /mnt/foo /mnt/bar

returns no results. However in my case, rsync is also unable to show the differences.

POSIX says that a file is uniquely determined by its inode and device number. If you have a file system that reports the same device for different contents, your file system is broken, and it's no wonder that LOTS of Unix tools will fail to see the differences, because your file system is lying. We can't fix it in diffutils; that would have to be a fix in the kernel implementation of your file system driver.

--
Eric Blake, Principal Software Engineer
Red Hat, Inc.           +1-919-301-3266
Virtualization:  qemu.org | libvirt.org





reply via email to

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