How to remove a directory which looks corrupted
5,477
You can try removing the file using it's inode:
ls -il
you should see somehting like:
99999 d????????? ? ? ? ? ? .libs/
where 99999 is the inode number. Then try
find . -inum 99999 -exec rm -i {} \;
you will probably have to 'sudo' the find command, since the ownership is corrupted.
If this directory had files in it, you will end up creating orphans & will need to fsck your disk.
Related videos on Youtube
Author by
hap497
Updated on September 17, 2022Comments
-
hap497 over 1 year
I am using Ubuntu 9.10. When I examine a directory, it shows as '?' for user/ownership.
How can I remove it?
-rw-r--r-- 1 hap497 hap497 1822 2010-01-28 22:48 IntSizeHash.h d????????? ? ? ? ? ? .libs/ -rw-r--r-- 1 hap497 hap497 194 2010-02-25 12:12 libwebkit_1_0_la-BitmapImage.lo
I have tried rm and sudo rm but get an error:
$ sudo rm -Rf .libs rm: cannot remove `.libs': Input/output error
Thank you for any pointers.