Sunday, February 4, 2018
Cant Empty Trash Error Code 8003
Cant Empty Trash Error Code 8003
Several times now Ive installed Box.coms BoxSync app only to find out after its installed that I cannot empty the trash. I use Box.com a lot for clients and turns out theyre using it more and more but Box.coms installer needs some work and Ive emailed them a few times to let them know with not results.
What happens is you install the app, toss the installer into the trash and hit Empty Trash or your favorite key combo (mine is COMMAND + SHIFT + OPTION +DELETE) and the Mac yells at you about how it cant do that and tosses up an error code of -8003.
Rebooting then emptying the trash doesnt help.
Holding down option when you empty trash (see key combo above) doesnt work.
Trying to securely empty trash doesnt work.
What Ive had to do a handful of times now on different Macs with different versions of the OS installed to delete BoxSync (this applies to anything that refuses to be deleted) is this:
1. Launch the Terminal
2. Type EXACTLY and without quotes "cd .Trash" hit return.
3. Type EXACTLY and without quotes "ls -al" hit return and see all the stuff thats in the trash.
4. After you confirm what you want to delete is in the trash type EXACTLY and without quotes "rm " thats lower case rm and a space(bar), then type the first letter, paying attention to capitalization of the file and tap TAB to auto complete it. This is for FILES not folders or packages!
5. Hit return and it should be gone.
If its a package like Box Sync Installer is then step 4 is slightly different. Type EXACTLY and without quotes "rm -rf " thats lower case rm a space(bar) a dash and lower case rf then another space(bar). Then type a capital B and tap TAB to auto complete it. It should look like this:
rm - rf Box Sync Installer.app/
Hit return and it should be gone. Finally.
TECHNICAL STUFF:
If you really want to find the offending file and dont have a ton of stuff in the trash you can move items back where they were, meaning back on the same volume, drive, folder or whatever, just not in the Trash. I put stuff from one drive into a new temp folder I name "TRASH THIS!" so theyre not loose all over the place on that drive.
Then put them in the trash and delete them one by one. Eventually youll hit a folder or file that wont delete. Recently I had a file that was actually a package that wouldnt delete and tossed up the -8003 error.
Heres what I did once I found the file that refused to be deleted.
- Launch the Terminal
- Type "cd" space-bar then drag the folder that has that file into the terminal, itll fill out the path then hit Return.
- Type "ls -al" to list the files. (If you want to get fancy type "ls -FaGlh" for a nicer looking file list in the Terminal)
- Type this EXACTLY, "rm" space-bar, then the first letter of the file that wont delete, then the Tab key. Hitting the Tab key will fill out the rest of the file name saving you from typing or worse, mistyping it.
EXAMPLE:
If the file is called roughcut.mov type "rm" hit the spacebar and type "r" then Tab key. The Terminal will show something like:
rm folder/roughcut.mov
Hit Return and it should delete the file.
If its a folder, from inside the folder that folder is in (see "cd" above) its in, add a -rvf to the command. This will show you all the things its deleting.
-r will delete folders and their contents
-v shows you all the stuff its deleting
-f tells the rm command to ignore files that arent really there
If you want to confirm every file before its deleted I think you can add an "i" to the string of switches like "-rvfi"
Careful with all this, using the rm command can seriously ruin your day if youre not careful. To read more about rm type this into the Terminal and hit enter:
man rm