Apple Event: May 7th at 7 am PT

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

no entry for mailbox id X in the cache; this should never happen

I'm getting a lot of this in my logs... Any ideas how to fix it?

Feb 2 12:48:05 ssh-4 Mail[282]: no entry for mailbox id 36 in the cache; this should never happen
Feb 2 12:48:05: --- last message repeated 9 times ---
Feb 2 12:48:05 ssh-4 Mail[282]: no entry for mailbox id 51 in the cache; this should never happen
Feb 2 12:48:05: --- last message repeated 1 time ---
Feb 2 12:48:05 ssh-4 Mail[282]: no entry for mailbox id 28 in the cache; this should never happen
Feb 2 12:48:05: --- last message repeated 7 times ---
Feb 2 12:48:05 ssh-4 Mail[282]: no entry for mailbox id 22 in the cache; this should never happen
Feb 2 12:48:05: --- last message repeated 2 times ---
Feb 2 12:48:05 ssh-4 Mail[282]: no entry for mailbox id 28 in the cache; this should never happen
Feb 2 12:48:06: --- last message repeated 50 times ---
Feb 2 12:48:06 ssh-4 Mail[282]: no entry for mailbox id 52 in the cache; this should never happen
Feb 2 12:48:06: --- last message repeated 1 time ---
Feb 2 12:48:06 ssh-4 Mail[282]: no entry for mailbox id 33 in the cache; this should never happen
Feb 2 12:48:06: --- last message repeated 1 time ---
Feb 2 12:48:06 ssh-4 Mail[282]: no entry for mailbox id 40 in the cache; this should never happen
Feb 2 12:48:06: --- last message repeated 3 times ---
Feb 2 12:48:06 ssh-4 Mail[282]: no entry for mailbox id 46 in the cache; this should never happen
Feb 2 12:48:06: --- last message repeated 5 times ---
Feb 2 12:48:06 ssh-4 Mail[282]: no entry for mailbox id 33 in the cache; this should never happen
Feb 2 12:48:06: --- last message repeated 2 times ---
Feb 2 12:48:06 ssh-4 Mail[282]: no entry for mailbox id 28 in the cache; this should never happen
Feb 2 12:48:06: --- last message repeated 2 times ---
Feb 2 12:48:06 ssh-4 Mail[282]: no entry for mailbox id 33 in the cache; this should never happen
Feb 2 12:48:06: --- last message repeated 2 times ---
Feb 2 12:48:06 ssh-4 Mail[282]: no entry for mailbox id 28 in the cache; this should never happen
Feb 2 12:48:06: --- last message repeated 6 times ---
Feb 2 12:48:06 ssh-4 Mail[282]: no entry for mailbox id 33 in the cache; this should never happen
Feb 2 12:48:07: --- last message repeated 3 times ---
Feb 2 12:48:07 ssh-4 Mail[282]: no entry for mailbox id 28 in the cache; this should never happen
Feb 2 12:48:07: --- last message repeated 2 times ---
Feb 2 12:48:07 ssh-4 Mail[282]: no entry for mailbox id 47 in the cache; this should never happen
Feb 2 12:48:12: --- last message repeated 2 times ---
Feb 2 12:48:12 ssh-4 Mail[282]: no entry for mailbox id 26 in the cache; this should never happen
Feb 2 12:48:15: --- last message repeated 5 times ---
Feb 2 12:48:15 ssh-4 Mail[282]: no entry for mailbox id 32 in the cache; this should never happen
Feb 2 12:48:15 ssh-4 Mail[282]: no entry for mailbox id 33 in the cache; this should never happen
Feb 2 12:48:15 ssh-4 Mail[282]: no entry for mailbox id 32 in the cache; this should never happen
Feb 2 12:48:15 ssh-4 Mail[282]: no entry for mailbox id 33 in the cache; this should never happen
Feb 2 12:48:15 ssh-4 Mail[282]: no entry for mailbox id 32 in the cache; this should never happen
Feb 2 12:48:16 ssh-4 Mail[282]: no entry for mailbox id 28 in the cache; this should never happen
Feb 2 12:48:46: --- last message repeated 2 times ---

Mac Pro, MacBook Pro, X Serve, Intel iMac, Mac OS X (10.5.6)

Posted on Feb 2, 2009 12:19 PM

Reply
16 replies

Feb 2, 2009 1:42 PM in response to ssh Mac

Try creating a New User Account, and as that New User try setting up your Gmail account (or any or all of your IMAP accounts). See the following if not familiar with adding a new user account:

http://docs.info.apple.com/article.html?path=Mac/10.5/en/8235.html

The reason for doing this is to test the Mail app itself, and not to permanently switch to a new user account. Tell me if the behavior continues in that New User Account?

Ernie

Feb 3, 2009 8:52 AM in response to ssh Mac

I have seem a similar note in my system.log file. It seems to occur sporadically during the following operations:

* upon launch
* when checking for new mail
* when quitting the program

The note always comes after all activity in the "activity" window has completed. I tried this in with a new user account, and it didn't produce the error at any of the above times. In case its relevant, I'm using Mail Version 3.5 (930.3).

Feb 22, 2009 4:32 PM in response to ssh Mac

I have determined exactly what this is.

In the folder:
/Library/Mail/AccountTypes/com.apple.builtin.mailaccounts/

There is a list of different mail account types in a file called "MailAccounts.plist". When the Console gives you an error message, it will specifically state ..."mailbox id ## in the cache", which corresponds to an entry in this file.

This plist file must be modified. I have not tried flat out deleting the file, but if you can get the developer tools, you can easily delete the offending entries.

To delete the bad entries:

NOTE: If you have to delete multiple entries, delete the ones with the largest index (i.e. "id 999999") FIRST.

1. Open MailAccounts.plist in the Property List Editor
2. Under the root triangle, click the "Multiple" triangle (this shows you the actual entries)
3. Starting with the highest mailbox number, delete each entry "Item #" by highlighting the node and pressing the "Delete Item" button on the toolbar.
4. Repeat until all your console errors are accounted for.
5. Save the file: File >> Save

You can exit the Property List Editor. Open Mail and wait a few seconds, then check the console for error messages. If there are no more error messages, you're set! Otherwise go back and try deleting the offending item(s) again.

Time Machine is your friend if you don't get it right the first time.

HTH

Apr 16, 2009 2:10 PM in response to ssh Mac

I am receiving these same messages:

Mail\[28580\] no entry for mailbox id 1579 in the cache; this should never happen

multiple times each time I start up or quit Mail. The instructions in the "solution" above seem flawed. The file identified is not a list of mailboxes, but a list of information about popular ISPs -- in particular, their POP and SMTP host names, and their support URLs -- used to fill in these values automatically at new account definition time. Modifying this plist won't address mailbox problems.

I have a feeling that this message indicates an inconsistency in the SQL database used to hold mail messages, in that there are some number of messages marked as belonging to mailbox ID N, but N doesn't correspond to any existing mailbox. I don't know of any tool that would find and fix these consistency problems, but I suspect I desperately need one at this point.

Apr 28, 2009 10:00 AM in response to ssh Mac

I had this problem too. To solve it, I looked for a way to rebuild the entire Mail database, and that seems to have fixed it (so that the "no entry for mailbox id X" messages no longer appear on startup/shutdown of Mail).

To rebuild Mail's database, I followed the instructions at <http://www.tuaw.com/2006/04/12/mail-slowing-you-down-rebuild-its-database/> for getting rid of the Envelope Index file (which I moved to my desktop, to be safe). When I re-launched Mail, it offered to re-import all of my mail, which I allowed. A reported 130,690 messages took about 40 minutes to import, so be prepared.

Since the import finished, Mail seems fine, and the "no entry for mailbox" messages have stopped.

Note: Your mileage may vary, back up your data first, etc.

Hope this helps,
Mike

no entry for mailbox id X in the cache; this should never happen

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