Welcome to the MacNN Forums.

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

You are here: MacNN Forums > Software - Troubleshooting and Discussion > macOS > The story of the un-trash-able file.

The story of the un-trash-able file.
Thread Tools
Alf4051
Fresh-Faced Recruit
Join Date: Dec 2002
Status: Offline
Reply With Quote
Oct 14, 2003, 01:09 PM
 
I don't know if this is the correct place for this, but I have a little problem.

I somehow managed to come across a file that can't be thrown away or deleted. If I do try to throw it away, it says the file is

"being used by another task right now(Other tasks include moving, copying, or emptying the trash)"

I've since renamed the file "trashdoc" for comedic effect, so I have no idea what kind of file it actually is. Any help would be cool.

I realize this isn't a major issue since it's all of 500 KB big...but it still would be nice to fix.

EDIT: I'm running 10.2.5
     
Uncle Skeleton
Addicted to MacNN
Join Date: Nov 2002
Location: Rockville, MD
Status: Offline
Reply With Quote
Oct 14, 2003, 01:10 PM
 
try restarting the computer?
     
Alf4051  (op)
Fresh-Faced Recruit
Join Date: Dec 2002
Status: Offline
Reply With Quote
Oct 14, 2003, 01:12 PM
 
Originally posted by Uncle Skeleton:
try restarting the computer?
I've had the file for months now...I've tried restarting...shutting down...quitting all progams.

It's a tough little bugger.
     
SSharon
Professional Poster
Join Date: Jan 2003
Location: Teaneck, NJ
Status: Offline
Reply With Quote
Oct 14, 2003, 01:17 PM
 
Its not the best advice but I've given it here before with some success:

Open Stuffit or some compression utility.
Make sure the preferences are set to delete original after compression.
Compress the file.
Delete the newly made archive.

it doesn't explain anything, its not elegant, but for people that just can't stand useless icons on their desktop . . . it works.
     
Alf4051  (op)
Fresh-Faced Recruit
Join Date: Dec 2002
Status: Offline
Reply With Quote
Oct 14, 2003, 01:24 PM
 
Originally posted by SSharon:
Its not the best advice but I've given it here before with some success:

Open Stuffit or some compression utility.
Make sure the preferences are set to delete original after compression.
Compress the file.
Delete the newly made archive.

it doesn't explain anything, its not elegant, but for people that just can't stand useless icons on their desktop . . . it works.
Haha...awesome! It worked. Thanks a ton!
     
anthology123
Mac Enthusiast
Join Date: Nov 2000
Location: Palo Alto, CA USA
Status: Offline
Reply With Quote
Oct 14, 2003, 01:32 PM
 
A simpler solution would be to download the free program Cocktail. It has the ability to delete any file that won't delete. I think it uses super root user delete to override everything. Get cocktail from versiontracker.
     
SSharon
Professional Poster
Join Date: Jan 2003
Location: Teaneck, NJ
Status: Offline
Reply With Quote
Oct 14, 2003, 01:36 PM
 
Cocktail eh? I've seen it mentioned in other posts I may just add it to my huge collection of shareware/freeware apps on my computer. And recommend it as an alternative to my previous method.
     
iDriveX
Mac Elite
Join Date: Nov 2001
Location: SoCal
Status: Offline
Reply With Quote
Oct 14, 2003, 02:07 PM
 
An even quicker solution would involve opening terminal and typing in the following:

"sudo rm -r"

and then type a space and then drag the file INTO the terminal window. Let go of the file and the path will automatically be written into the terminal for you. Then hit enter. It might give you some crap about not abusing admin privledges or something and then it'll ask for your password. Give it the password and hit enter. FILE DELETED!

Version 4.0 - Now Powered By iWeb
     
cougar337
Junior Member
Join Date: Apr 2003
Status: Offline
Reply With Quote
Oct 30, 2003, 02:57 PM
 
Originally posted by iDriveX:
An even quicker solution would involve opening terminal and typing in the following:

"sudo rm -r"

and then type a space and then drag the file INTO the terminal window. Let go of the file and the path will automatically be written into the terminal for you. Then hit enter. It might give you some crap about not abusing admin privledges or something and then it'll ask for your password. Give it the password and hit enter. FILE DELETED!
Woah!!! this worked for me. I had two stubborn files and it cleaned them no problem.

I do have Coctail but I couldnt figure out where in the program I could delete stubborn files...anyone have any suggestions? this is all great info. a bump for the people that are
     
SSharon
Professional Poster
Join Date: Jan 2003
Location: Teaneck, NJ
Status: Offline
Reply With Quote
Nov 20, 2003, 01:54 AM
 
I managed to help someone with this problem earlier and now I am having problems of my own.

So there is this file in a folder and I can't delete either.

I tried my method from above.
I tried every unix command I could think of.
I tried cocktail.

They all failed.

The file is an mpg file in a folder in the trash. I can't take them out of the trash. I can't modify the permissions on them. I can rename the folder but not the file. Also, disk utility is telling me that I have an invalid file count and therefore cannot repair my drive. The file count is off by two and my guess is that these are those two files.

So please, if anyone can help please respond with some new way of deleting the undeletable file.

(Dual G4 MDD, 10.3)
     
dagaz
Junior Member
Join Date: Nov 2003
Location: Australia
Status: Offline
Reply With Quote
Nov 20, 2003, 02:34 AM
 
For a folder you have to add the "r" command (recursive) to the "rm" command (remove). So, for example, if the folder you wish to delete is in your trash you would type "sudo rm -rf ~/.Trash/*" (where "*" will remove anything in your trash).
Not compatible with Windows
     
SSharon
Professional Poster
Join Date: Jan 2003
Location: Teaneck, NJ
Status: Offline
Reply With Quote
Nov 20, 2003, 02:39 AM
 
thank you. I tried that, and it asked for my password but didn't do anything, I have also tried rm with the force command and a bunch of others. Also ran disk utility again and it said my drive checks out ok, this just gets odder.
     
dagaz
Junior Member
Join Date: Nov 2003
Location: Australia
Status: Offline
Reply With Quote
Nov 20, 2003, 02:46 AM
 
I have also tried rm with the force command
I'm not sure if this is what you did or not, but you'll notice in my post above I used the flag "-rf" which is both recursive and forced. If that doesn't do it repair permissions and try again.
Not compatible with Windows
     
SSharon
Professional Poster
Join Date: Jan 2003
Location: Teaneck, NJ
Status: Offline
Reply With Quote
Nov 20, 2003, 02:48 AM
 
I did exactly what you did and earlier tried it with just the -r modifier. Permissions repaired on all drives (with an OS).

hmmmm
     
dagaz
Junior Member
Join Date: Nov 2003
Location: Australia
Status: Offline
Reply With Quote
Nov 20, 2003, 05:00 AM
 
Can you do a "ls -al ~/.Trash/" and paste the results back into here?

Or you may just want to check out this link and work it out for yourself.
Not compatible with Windows
     
SSharon
Professional Poster
Join Date: Jan 2003
Location: Teaneck, NJ
Status: Offline
Reply With Quote
Nov 20, 2003, 05:04 AM
 
ssharon:~ stephen$ ls -al ~/.Trash/
total 0
drwx------ 2 stephen stephen 68 20 Nov 04:02 .
drwxr-xr-x 22 stephen stephen 748 20 Nov 02:01 ..
ssharon:~ stephen$

but when I open the trash folder I still see a folder called junk and a file (39mb, even though other apps say its 0) in there.
     
dagaz
Junior Member
Join Date: Nov 2003
Location: Australia
Status: Offline
Reply With Quote
Nov 20, 2003, 05:56 AM
 
ssharon:~ stephen$ ls -al ~/.Trash/
total 0
drwx------ 2 stephen stephen 68 20 Nov 04:02 .
drwxr-xr-x 22 stephen stephen 748 20 Nov 02:01 ..
ssharon:~ stephen$
Then the folder (and file) are gone. Maybe the GUI just hasn't caught up yet - are you running any system hacks or themes? Try logging out and back in again.
Not compatible with Windows
     
SSharon
Professional Poster
Join Date: Jan 2003
Location: Teaneck, NJ
Status: Offline
Reply With Quote
Nov 20, 2003, 10:07 AM
 
well I have been switching back and forth between users all day and its just those 2 files that remain. Everything else I put in there gets detleted normally. I logged out and back in and they are still there.
     
neilw
Mac Enthusiast
Join Date: Jun 2000
Location: New Jersey, USA
Status: Offline
Reply With Quote
Nov 20, 2003, 03:21 PM
 
Have you tried a proper disk repair tool, like DiskWarrior? Might be worth a shot.
     
dagaz
Junior Member
Join Date: Nov 2003
Location: Australia
Status: Offline
Reply With Quote
Nov 20, 2003, 04:21 PM
 
I logged out and back in and they are still there
This is very wierd that Unix doesn't see the files but the GUI does, normally its the other way around and I've never heard of this before. Perhaps a complete restart is in order, while you're at it maybe you should try booting into single user mode and running fsck.
Not compatible with Windows
     
   
 
Forum Links
Forum Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Top
Privacy Policy
All times are GMT -4. The time now is 07:47 AM.
All contents of these forums © 1995-2017 MacNN. All rights reserved.
Branding + Design: www.gesamtbild.com
vBulletin v.3.8.8 © 2000-2017, Jelsoft Enterprises Ltd.,