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

I can not delete an email I get a message218130.emlx” couldn’t be copied because you don’t have permission to access “Messages”

I can not delete an email I get a message218130.emlx” couldn’t be copied because you don’t have permission to access “Messages”

MacBook Pro, OS X Mountain Lion (10.8.2)

Posted on Oct 16, 2012 3:48 PM

Reply
4 replies

Nov 14, 2012 7:57 AM in response to Ali-TEC

Actually, the Finder solution did not work for me, but here's what did:


Quit Mail (for safety's sake).


Open Terminal (it's in Utilities folder usually, but since I updated to ML it's in a folder called Other for some reason)


Once Terminal is open, you'll want to login as ROOT. You do this as follows:


Type


sudo -i


Then hit Enter/Return. You'll be promoted for your system password. Hopefully you'll remember it. Enter your password then hit Enter/Return.


You'll then be at what's known as a root prompt.


At this point BE VERY CAREFUL. You have the ability at this point to completely destroy your machine beyond repair. Only type what I list below:


To find the folder that contains the email message you'll need to type the following:


find . -name "218130.emlx"

Hit Enter/Return


This will take a minute or two but what should appear in the list of other items that appear is something along the lines of the following (it won't be exactly this but will look LIKE this) I've replaced some personally identifying info:


./Users/yourname/Library/Mail/V2/POP-youremailaddress@yourmailserver/INBOX.mbox/ 0355DF0D-5E99-4798-B79E-48D71E68AF34/Data/3/2/Messages/23219.emlx


This line describes the location of the offending email. You know what to put yourself into this directory:


cd /Users/yourname/Library/Mail/V2/POP-youremailaddress@yourmailserver/INBOX.mbox/0 355DF0D-5E99-4798-B79E-48D71E68AF34/Data/3/2/Messages/

Hit Enter/Return


Notice, I left of the name of the actual email address. You'll need to be sure you type the location EXACTLY or this won't work. You want to be in the Messages folder. You'll know you're there because your Terminal prompt will look something like this:


Your Name - iMac:Messages


Then just to be sure you're in the right place, type


ls


Hit Enter/Return


You should then see something like this:


iMac:Messages root# ls

23013.emlx 23096.emlx 23100.emlx 23156.emlx 23210.emlx 23213.emlx 218130.emlx


You'll see the offending message. Now, you delete ONLY this message. Type:


rm -f 218130.emlx


That's RM at the start above. You'll need to type it in lower case. Be sure that's all you type.


Hit Enter/Return


You'll should be disappointed at the results because it will look like nothing happened. You can hit ls and Enter/Return one more time and the offending file should be gone.


EXIT TERMINAL. DO NOT TYPE ANYTHING ELSE. DO NOT "POKE AROUND". THIS IS NOT THE PLACE TO EXPLORE. SERIOUS SYSTEM DAMAGE CAN BE CAUSED FROM HERE. EXIT TERMINAL NOW.


Now re-open Mail - the message will still appear to be in there, but magically, you can delete it. you can also delete it from your Trash for good measure.

Feb 28, 2015 3:31 PM in response to tjcornetto

My answer is a bit late, but someone might benefit.

Deleting files with Terminal was a good lesson. Each time I deleted an offending file, the next time I deleted a file in Mail I received the error with a different filename.

In my case what I think happened was that I deleted an entire Archive, because I do not understand why I had thousands of eMails in Archives which I never put there. I know it's off topic, but may be someone knows why this is, and how it can be prevented.

I remembered a neat app called EasyFind by DEVONtechnologies. I have V 3.9 and it still works with Yosemite.

I copied the offending file name and had EasyFind find it. I turned on find hidden files, but may be these files are not hidden. I then right-clicked the search result and let the program show me the file(s) in Finder (yes, sometimes there were several of the same name.)

Since I wanted to Trash these files anyway, I just deleted all files in Messages folders. The irritating error messages:

"The message “________” could not be moved to the mailbox “Trash — On My Mac”

“1423152.emlx” couldn’t be copied to “Messages” because an item with the same name already exists."

have stopped for now. I think that when I deleted an Archive, Mail started using the same numbers again.

I can not delete an email I get a message218130.emlx” couldn’t be copied because you don’t have permission to access “Messages”

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