Looks like no one’s replied in a while. To start the conversation again, simply ask a new question.

Impossible to delete a file

I've found a file on my Mac, named Thumbs.db/encryptable.
I was able to delete (put in trash), but when I empty the trash the file stay there.

I try disk repairing from OSX dvd boot.
Try deleting in single user mode, and a lot of other method what I've found on google.
Try delete by id.
Nothing...

This is the main drive, mac os extended journaled.
The drive is in good condition.

IS THERE ANY OTHER WAY TO ELIMINATE A FILE?

Macbook Pro 13, Mac OS X (10.6.6)

Posted on Feb 1, 2011 4:13 PM

Reply
Question marked as Best reply

Posted on Feb 1, 2011 4:19 PM

Does the file actually contain the '/' character? If so, that's likely what is causing the problem. That's a special character on Unix-based systems.

Try this, assuming you're using an admin account: put it in the trash, then open the Terminal and paste in this command, then hit return:


sudo rm -rf ~/.Trash/*


Be sure to copy and paste, not re-type... that is an extremely dangerous command, and a typo could destroy you. Note that you'll be prompted for your account password, and won't see anything when you type it.

If that doesn't fix it, let us know.
69 replies

Feb 1, 2011 7:03 PM in response to stenya

Okay, this one's out there. I mean seriously out there. But it's worth a try. Go to System Preferences -> Sharing and select File Sharing. Click the Options button and turn on FTP sharing. Now, get an FTP client if you don't have one already... Transmit, Fetch, Cyberduck, Interarchy, etc. (Technically, the Finder can connect to FTP servers, but we want to use something else.)

Using your FTP client, connect to ftp://localhost/, and give your account username and password. Make sure the client is showing hidden files, and navigate into the trash and then into folder 'a'. Then try to delete the file from there.

If nothing else works, try repairing the hard drive using Disk Utility. I dunno if that would make any difference, but it might.

Feb 1, 2011 7:13 PM in response to thomas_r.

You are tricky.

FTP ON, Desktop added, Transmit run.
And then:

Server said: a: Directory not empty.
Error -126: remote rmdir failed


I've turned on show hidden files, but nothing.
Tried from a terminal windows, but nothing.
File is not visible.

Disk Utility says ALL OK. I boot from original DVD and said that too.
I'm out of ideas...

Feb 1, 2011 7:18 PM in response to stenya

Man, that's a stubborn booger. Well, as much as I hate to give up on it, I'm completely tapped out of ideas. I'll keep thinking on it, but looks like that file has moved in to stay. You may have to erase and reinstall to get rid of the darned thing. Fortunately, most backup software won't back up the trash, so you won't have to worry about it contaminating a backup!

If I think of anything else, I'll let you know.

Feb 1, 2011 7:24 PM in response to thomas_r.

Big Thank You!
During the holidays I've spent 1.5 days with that continously.
I was screaming ****.

The file stayed, it cause nothing, just the Trash icon is always full.
System works normal, this forum was my last idea.

Appreciate your help... G

+I hope an Apple HFS FileSystem Engineer will see this thread.+

Feb 1, 2011 7:25 PM in response to stenya

Might be easier to just delete the trash directory all together. First get out of your trash directory:

cd ~/


Then copy and paste:

rm -R ~/.Trash


followed by

killall Finder


exit to end terminal and quit, see if this was the fix.

If it complains that you don't have permission to delete that, then that's probably the problem. You can then add "sudo " to the beginning of that command

sudo rm -R ~/.Trash


at which point you'll get a password prompt and it should delete it no matter what.

Once you've removed the .Trash folder, it should re-create automatically if you either log out and back in, or use the force quit dialogue to re-launch Finder as stated above. You could also use

mkdir ~/.Trash/


to manually recreate it if it doesn't get created automatically.

In either case, I'd also open Disk Utility and run "Repair Permissions"--it may not help, but if the trash is screwed up something else might be, and it certainly won't hurt anything.

Feb 1, 2011 7:44 PM in response to leroydouglas

for sure, the terminal window was:

stenyamac:~ stenya$ cd ~/
stenyamac:~ stenya$ rm -R ~/.Trash
rm: /Users/stenya/.Trash/a/Thumbs.db:encryptable: No such file or directory
rm: /Users/stenya/.Trash/a: Directory not empty
rm: /Users/stenya/.Trash: Directory not empty
stenyamac:~ stenya$ killall Finder
stenyamac:~ stenya$ sudo rm -R ~/.Trash
Password:
rm: /Users/stenya/.Trash/a/Thumbs.db:encryptable: No such file or directory
rm: /Users/stenya/.Trash/a: Directory not empty
rm: /Users/stenya/.Trash: Directory not empty
stenyamac:~ stenya$

Feb 1, 2011 9:21 PM in response to thomas_r.

Please pardon the intrusion…

Hi, Thomas!

Congratulations on advancing to Level 4!

At the Water Cooler in the Level 4 Lounge, we are throwing virtual confetti in celebration of your attainment of Level 4-dom. Would you care to join us at the Water Cooler?

At the top of the _Feedback about Discussions forum_ you will find the Lounge link available to you. It should work for you within the next 24 hours if all goes as it should.

Hope to see you there soon! User uploaded file

Impossible to delete a file

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