2

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.

2 Answers 2

3

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.

0

Just change the ownership to yourself (via sudo chown -R .libs) then recursively remove the directory (rm -R .libs)... if that fails: sudo su -; change into directory; remove contents; return to previous directory and remove the directory.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .