0 byte file with no name????

Please help me in removing the 2nd file :

-rw-rw-rw- 1 fup03a fup03a 9216 Aug 16 00:45 med_delay_log
-rw-rw-rw- 1 fup03a fup03a 0 Aug 16 18:04

You may find what is the "invisible" character by issuing the ls command piped with od and obtain a "description" of the character:

ls | od -t a

Then (in some manner, like CTRL+V followed by a key) you could reproduce the character and pass it to the rm command.

I think that we can remove the file also by mean of its inode number, but I don't know how. Obtaining the inode number is simple (ls -i), and then? Someone could explain?

Thanks :slight_smile:

Thanks...
I have got the following output...I did not understand the CTRK + V ?
Can you please explain

byfusp01 $ ls | od -t a
0000000 sp nl d i r _ t i m e . c f g nl d
0000020 i r _ t i m e . t m p nl f i l e
0000040 _ d e l a y . s h nl m e d _ d e
0000060 l a y _ l o g _ 2 0 0 7 0 8 1 5
0000100 nl m e d _ d e l a y _ l o g _ 2
0000120 0 0 7 0 8 1 6 nl m e d _ d e l a
0000140 y _ l o g _ 2 0 0 7 0 8 1 7 nl m
0000160 e d _ d e l a y _ n e w 2 . d s
0000200 d nl m e d _ d e l a y _ t e m p
0000220 . t x t nl
0000225

The character is "sp"
when i write "rm sp" obviously it would say file not found.
Can you please tell how to proceed ....

If the character is a space, simply try:

rm " "

You can also try "rm -i *", which asks you a confirmation for each file you want to delete and then remove only the "ghost" file.

I searched in google for deleting a file using inode...

I have managed to delete the file using the following...

by inode

#ls -i
#find . -inum 968746 -exec rm -i {} \;

Thanks for the idea Robotronic :slight_smile: