Just about a month ago I wrote about a problem I had with the mds process on OS X. That’s the process that indexes your HDD for spotlight.
Mine was running wild then and I found a way to fix it. Now, after the last system update, this was happening again. I tried to apply the same fix – only to see, that the update didn’t change anything about my settings there.
I disabled all aspects of spotlight, one item at a time (disallowing it to search Applications, Contacts, … until I was down to „Messages“). Didn’t help. Rebooting did – for a few minutes. Oddly enough, this didn’t happen on my second machine which runs (almost) the exact same software.
So I figured that something on my HDD (which is actually an SSD) must undergo constant changes so that spotlight would have to index it over and over again. While thinking about that, mds stopped and went down to a CPU usage of 0,0%.
I waited about an hour and it was up to 104,7% again (plus 63% for mdworker). By then I already had found the solution and had only waited for mds running wild again so I could verify my theory…
I’m a long time customer at Backblaze – an online backup service provider. The backblaze application constantly watches over changes on my system and, if it found any, encypts the newly added/created files and uploads them to a backblaze server. The tempory data needed to do this is being stored in USER/Library/backblaze. After adding this folder in the „Privacy“ tab of spotlight’s settings in System Preferences, mds IMMEDIATELY went to to 3,4%, then 2,0% and finally to 0,3% CPU usage.
I don’t know why this started happening just now. I don’t know wether this is happening only on one of machines. But I’m 99,9% sure that this did the trick.
So if you’re using backblaze on a Mac with spotlight and experience mds/mdworker running wild from time to time or even regularly – you might want to give my solution a shot.