Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!

Repair broken junk filters in Apps
I noticed that lately, my junk mail filtering in Mail app was no longer working -- at least not very well, and perhaps not at all. By "not working," I mean that mail which was obviously junk was not getting moved to my junk mail folder automatically. I had to drag it over by hand.

I thought maybe the spammers were getting smarter (but really, who could believe that?). The weird thing was, it was happening on both of my Macs. After perhaps a week or so of this behavior, one machine wouldn't even allow me to drag junk mail over to the junk mail folder by hand. The Mail app would just crash!

I first tried repairing permissions. That didn't help. So I went to the ~/Library/Mail folder and saw this file called LSMMap2, which I knew had something to do with junk mail. I tried to open it up using SubEthaEdit. What do you know. It crashed as well! Something was obviously not right with this file.

Here's what worked for me:
  1. Make sure Mail is not running.
  2. Rename LSMMap2 to LSMMap2.old.
  3. Restart Mail and it will create a new copy of LSMMap2. In my case, it was was quite a bit larger than the old one. I'm not sure why.
  4. Once you're satisfied that all is well, go ahead and erase the LSMMap2.old file created in step two.
I did the same thing on my other Mac, on which Mail had not (yet) begun crashing, and it is also now correctly processing junk mail again.
  • Currently 3.40 / 5
  You rated: 4 / 5 (5 votes cast)

Repair broken junk filters in | 9 comments | Create New Account
Click here to return to the 'Repair broken junk filters in' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
Repair broken junk filters in
Authored by: kal on Dec 14, '03 08:55:06AM

Does this procedure trash what Mail.App junkf ilters have "learned"?

[ Reply to This | # ]
Repair broken junk filters in
Authored by: ahbe on Dec 14, '03 02:03:20PM

That was my question as well. Does anyone know what's in this little file causing problems?

[ Reply to This | # ]
Repair broken junk filters in
Authored by: cudaboy_71 on Dec 14, '03 05:22:17PM

yes. the LSMMap2 file is the 'brains' of the junk filtering system. i back up this file regularly as a "LSMMap2.old" file in case something like this happens (it has twice already...once in jaguar and once in panther). the first time it happened i was able to use the 'LSMMap2' file from another computer, which saved some training time.

this isnt so much a hint on rescuing your junk filters as it is just a longhand 'reset' procedure. (you can accomplish the same thing by clicking the 'reset' button in the junk filter prefs)

if it aint broke, break it!

[ Reply to This | # ]
Repair broken junk filters in
Authored by: yellow on Dec 15, '03 09:29:02AM

Reset didn't work for me, sadly. I just removed the bayesian database and opened mail again. But I never thought of it as being hint-worthy :)

[ Reply to This | # ]
Repair broken junk filters in
Authored by: swimp on Dec 17, '03 04:30:18PM

thanks a _bunch_! I've been so annoyed with and actually considered switching just because of this (my spam problem is pretty big). But now I can stay with Apple Mail - so thanks! :)

[ Reply to This | # ]
Repair broken junk filters in
Authored by: pepito on Dec 15, '03 11:05:03AM
Thanks! This worked great

For a couple of weeks now, every time I would "Mark as Junk" would crash.

[ Reply to This | # ]
Repair broken junk filters in
Authored by: dlandrith on Feb 11, '04 12:13:22AM

This works to repair the broken junk mail filters, but the real problem is that the latest version of is itself junk: In order to keep my junk mail filters working, I am forced to reset the junk mail filters at least twice a week. Who's the idiot that missed this bug?

Since it took Apple more than two years to create an operating system that could gracefully disconnect from a Network when the connection was lost, and it took Next/Apple more than a decade to create a Mail program that could actually handle mailboxes with 1,000 plus messages in a timely manner, I hold little hope that Jobs & Co. can actually deliver a solution that "just works" for this one.

[ Reply to This | # ]
Repair broken junk filters in
Authored by: Fleemo Williams on Apr 05, '04 01:04:46PM

This tip was a GODSEND! I've been wresting with a sudden innundation of junk mail for weeks now. Tried everything, including deleting my preferences file, which caused me to lose several week's worth of mail. A nightmare. Yesterday, I was buried under 300+ junk e-mails and was just about to huck Mail for good when I found this tip. Worked perfectly! A thousand thank yous for freeing me from junk mail once again!

[ Reply to This | # ]
Repair broken junk filters in
Authored by: bkemper on May 17, '04 02:58:20PM

I had the same problem, and your fixed worked! Until next time I started Mail again, after the weekend. Then I guess the file got corrupted again, because I had hundreds of spam messages waiting for me, with none marked as spam or moved to the spam folder. Please help! I cannot spend time every day retraining this thing. Spam filtering was a major consideration in choosing Mail over Entourage, and now it doesn't work at all!

[ Reply to This | # ]