I have run into a little problem and I'm not entirely sure what the correct approach would be to fix it...
Short problem description:
I had a FS corruption last week and used fsck to repair it. After the repair I have two empty directories with the same inode and the system won't let me delete them.
The long problem description:
About a week ago we had a FS corrupted message in the error report. I subsequently unmounted the FS and ran fsck to repair it and it said that everything was fixed. However running a find on the FS gives out a bunch of "find: 0652-019 The status on ./path/filename is not valid." errors. I noticed that the empty directory /image2.nfs/image/util/200412010247359002/fps.icr had a reference count of three instead of the usual two.
So I have now tracked down the error to two directories that have the same inode number and I wish to just delete those directories.
But I can not do that because the system keeps giving me a "rm: 0653-611 Directory /image2.nfs/image/util/200507150329310032 is not empty." error.
The two directories with the same inode number are:
/image2.nfs/image/util/200412010247359002/fps.icr
/image2.nfs/image/util/200507150329310032
The impact on our system is that the backup (SysBack) does not work correctly because all the files in the find after /image2.nfs/image/util/200412010247359002/fps.icr comes up with an error.
Here's the shell output from my trouble-shooting:
[tt]TAX183:/image2.nfs/image/util
# ls -ld 200412010247359002
drwxrwsrwx 2 fp1 staff 512 Dec 03 2004
200412010247359002
TAX183:/image2.nfs/image/util
# ls -ial 200412010247359002
total 792
12294 drwxrwsrwx 2 fp1 staff 512 Dec 03 2004 .
2049 drwxrwsrwx1828 751 staff 396288 Sep 19 09:43 ..
12295 drwxrwsrwx 3 fp1 staff 512 Jul 18 14:49 fps.icr
[highlight]TAX183:/image2.nfs/image/util
# ls -ial 200412010247359002/fps.icr
total 784
12295 drwxrwsrwx 3 fp1 staff 512 Jul 18 14:49 .
2049 drwxrwsrwx1831 751 staff 396288 Sep 19 09:44 .. [/highlight]
TAX183:/image2.nfs/image/util
# rm -rf 200412010247359002
rm: 0653-611 Directory 200412010247359002/fps.icr is not empty.
rm: 0653-611 Directory 200412010247359002 is not empty.
[highlight]TAX183:/
# find /image2.nfs -inum 12295 -print 2>/dev/null
/image2.nfs/image/util/200507150329310032
/image2.nfs/image/util/200412010247359002/fps.icr [/highlight]
TAX183:/
# ls -ldia /image2.nfs/image/util/200507150329310032
12295 drwxrwsrwx 3 fp1 staff 512 Jul 18 14:49
/image2.nfs/image/util/200507150329310032
[highlight]TAX183:/
# ls -lia /image2.nfs/image/util/200507150329310032
total 784
12295 drwxrwsrwx 3 fp1 staff 512 Jul 18 14:49 .
2049 drwxrwsrwx1853 751 staff 396288 Sep 19 09:47 .. [/highlight]
TAX183:/
# rm -r /image2.nfs/image/util/200507150329310032
rm: 0653-611 Directory /image2.nfs/image/util/200507150329310032 is
not empty.[/tt]
Short problem description:
I had a FS corruption last week and used fsck to repair it. After the repair I have two empty directories with the same inode and the system won't let me delete them.
The long problem description:
About a week ago we had a FS corrupted message in the error report. I subsequently unmounted the FS and ran fsck to repair it and it said that everything was fixed. However running a find on the FS gives out a bunch of "find: 0652-019 The status on ./path/filename is not valid." errors. I noticed that the empty directory /image2.nfs/image/util/200412010247359002/fps.icr had a reference count of three instead of the usual two.
So I have now tracked down the error to two directories that have the same inode number and I wish to just delete those directories.
But I can not do that because the system keeps giving me a "rm: 0653-611 Directory /image2.nfs/image/util/200507150329310032 is not empty." error.
The two directories with the same inode number are:
/image2.nfs/image/util/200412010247359002/fps.icr
/image2.nfs/image/util/200507150329310032
The impact on our system is that the backup (SysBack) does not work correctly because all the files in the find after /image2.nfs/image/util/200412010247359002/fps.icr comes up with an error.
Here's the shell output from my trouble-shooting:
[tt]TAX183:/image2.nfs/image/util
# ls -ld 200412010247359002
drwxrwsrwx 2 fp1 staff 512 Dec 03 2004
200412010247359002
TAX183:/image2.nfs/image/util
# ls -ial 200412010247359002
total 792
12294 drwxrwsrwx 2 fp1 staff 512 Dec 03 2004 .
2049 drwxrwsrwx1828 751 staff 396288 Sep 19 09:43 ..
12295 drwxrwsrwx 3 fp1 staff 512 Jul 18 14:49 fps.icr
[highlight]TAX183:/image2.nfs/image/util
# ls -ial 200412010247359002/fps.icr
total 784
12295 drwxrwsrwx 3 fp1 staff 512 Jul 18 14:49 .
2049 drwxrwsrwx1831 751 staff 396288 Sep 19 09:44 .. [/highlight]
TAX183:/image2.nfs/image/util
# rm -rf 200412010247359002
rm: 0653-611 Directory 200412010247359002/fps.icr is not empty.
rm: 0653-611 Directory 200412010247359002 is not empty.
[highlight]TAX183:/
# find /image2.nfs -inum 12295 -print 2>/dev/null
/image2.nfs/image/util/200507150329310032
/image2.nfs/image/util/200412010247359002/fps.icr [/highlight]
TAX183:/
# ls -ldia /image2.nfs/image/util/200507150329310032
12295 drwxrwsrwx 3 fp1 staff 512 Jul 18 14:49
/image2.nfs/image/util/200507150329310032
[highlight]TAX183:/
# ls -lia /image2.nfs/image/util/200507150329310032
total 784
12295 drwxrwsrwx 3 fp1 staff 512 Jul 18 14:49 .
2049 drwxrwsrwx1853 751 staff 396288 Sep 19 09:47 .. [/highlight]
TAX183:/
# rm -r /image2.nfs/image/util/200507150329310032
rm: 0653-611 Directory /image2.nfs/image/util/200507150329310032 is
not empty.[/tt]