Ghost file in trash bin

Hello!
I have just run into a small problem. Before transferring some pictures to my IPhoto Library, I decided to delete a couple of files from the SD card. While deleting the files (by moving them to the trash and then emptying the trash) I had a system crash that required me to reset my Mac by holding the Power button.

After restarting, I was able to empty the trash, but I noticed that a "ghost" alias file had been created and was sitting there in my trash bin. Even though I deleted all the files, that file still lingers inside my trash bin and will not go away. If I touch the file with the mouse, it disappears for a moment, but comes back to 'life' again when I open the trash bin. It is a 0kb file, but if I try to drag it onto the desktop or even look at the file's information, it disappears for the moment.

What should I do to remove that file?

I would appreciate if anyone could give me some hint of what to do.

Thank you very much in advance

MacBook Pro, Mac OS X (10.5.1)

Posted on Dec 10, 2007 1:17 AM

Reply
3 replies

Dec 10, 2007 3:00 AM in response to Leonardo Kajioka

Open your terminal application.


then type the following command leaving a space after the f

sudo rm -rf

then drag the offending file onto the terminal window. this should then cause the terminal to write out the full path of the file name. Then press enter. You will then be prompted to enter your admin password. Do so and you should delete that file.

Please note that if the original file was not successfully deleted from your SD card it may reappear when you mount the sd card again.

Dec 10, 2007 3:18 AM in response to Tim Haigh

Tim, thanks for the reply !
Well, i tried using the Terminal to delete it but it didn't work!
As soon as I start typing the command and drag the file onto the Terminal, something happens and the filename and location is somehow 'cloned' and the terminal command does not find it.

Another weird thing that happens with that file is, if I drag it onto my desktop for example, it disappears from the trash bin. However, as soon as I open Finder again, the file reappears!

This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

Ghost file in trash bin

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.