Description of problem: in the vicinity of a mount point directory, two directories may have the same device and inode number. This is a serious problem because many tools treat the condition as indicating a hard directory cycle, which usually indicates file system corruption.
Version-Release number of selected component (if applicable):
2.6.31.5-122.fc12.x86_64
# mount | grep ^/
...
/dev/sda8 on /home type ext4 (rw,noatime)
...
# top=/home
# cat /etc/exports
# printf "/ *(fsid=0,crossmnt)\n$top *(crossmnt)\n" >> /etc/exports
# service nfs restart
...
# mkdir /tmp/mnt
# mount -t nfs4 localhost:/ /tmp/mnt
# stat --printf "%d %i %n\n" /tmp/mnt{,$top}
22 2 /tmp/mnt
22 2 /tmp/mnt/home
Then, using the very latest du from upstream coreutils.git,
I see this:
$ du /tmp/mnt > /dev/null
du: WARNING: Circular directory structure.
This almost certainly means that you have a corrupted file system.
NOTIFY YOUR SYSTEM MANAGER.
The following directory is part of the cycle:
`/tmp/mnt/home'
Actual results: above
Expected results: different dev and/or inode, no du failure
Description of problem: in the vicinity of a mount point directory, two directories may have the same device and inode number. This is a serious problem because many tools treat the condition as indicating a hard directory cycle, which usually indicates file system corruption.
Version-Release number of selected component (if applicable): 5-122.fc12. x86_64
2.6.31.
How reproducible: every time
Steps to Reproduce: /bugzilla. redhat. com/show_ bug.cgi? id=501848# c45
Based on the set-up from Kamil Dudka in https:/
# mount | grep ^/ 0,crossmnt) \n$top *(crossmnt)\n" >> /etc/exports
...
/dev/sda8 on /home type ext4 (rw,noatime)
...
# top=/home
# cat /etc/exports
# printf "/ *(fsid=
# service nfs restart
...
# mkdir /tmp/mnt
# mount -t nfs4 localhost:/ /tmp/mnt
# stat --printf "%d %i %n\n" /tmp/mnt{,$top}
22 2 /tmp/mnt
22 2 /tmp/mnt/home
Then, using the very latest du from upstream coreutils.git,
I see this:
$ du /tmp/mnt > /dev/null /tmp/mnt/ home'
du: WARNING: Circular directory structure.
This almost certainly means that you have a corrupted file system.
NOTIFY YOUR SYSTEM MANAGER.
The following directory is part of the cycle:
`
Actual results: above
Expected results: different dev and/or inode, no du failure
Additional info: