Q: Runaway processes burning CPU & hammering disk
I've filed an official bug report with Apple in mid-April and they requested a sysdiagnose dump, but since then I haven't heard a peep from them and this problem is persistent and very annoying, so I'm turning to the community for help.
These four processes have been driving me insane for a couple of months, UserEventAgent, launchd, cfprefsd, mds_stores, all running under root. In that order combined, they use over 230% CPU on my quad-core i7 Mac mini. They always appear together.
Worse, cfprefsd is hammering my disk hundreds of times a second creating a temporary file and then renaming it to /private/var/root/Library/Preferences/com.apple.xpc.activity2.plist. I'm talking about writing many GB an hour. The file always contains the same contents. Needless to say, the fan is running full blast and the whole system slows down. This occurs within minutes of rebooting and will sometimes clear on its own after a few hours, and sometimes I just have to reboot. Then it will go away for a day or two before rearing its ugly head again. Wash, rinse, repeat.
None of the suggested voodoo I've seen in my searches such as turning off Bluetooth, disabling Safari extensions, rebooting in recovery mode and resetting ACLs, has helped. That includes the advice here: Re: cfprefsd using > 90% of CPU.
I even tried disabling /System/Library/UserEventPlugins/com.apple.cts.plugin that someone suggested. It appeared to work, but it disables Time Machine so that "solution" is unacceptable.
From logs at the time the event started, it seemed related to the Messages app.
2016-04-14 8:12:56.111 PM com.apple.spotlight.IndexAgent[14767]: [com.apple.corespotlight.log] Not allowed to pass in bundle ID
2016-04-14 8:12:56.111 PM soagent[656]: Can't allocate SOHelper <SOMessageHelper: 0x7ffb81f23490> inside com.apple.soagent
2016-04-14 8:12:56.111 PM IMDPersistenceAgent[679]: [com.apple.corespotlight.log.index] Finished "index items"(62) with error:Error Domain=CSIndexErrorDomain Code=-1003 "(null)"
2016-04-14 8:12:56.111 PM IMDPersistenceAgent[679]: [Warning] IMDChatAddMessageToSpotlight: indexing searchable items failed with error Error Domain=CSIndexErrorDomain Code=-1003 "(null)"
2016-04-14 8:12:56.111 PM IMDPersistenceAgent[679]: [Warning] IMDChatAddMessageToSpotlight: indexing searchable items failed with error Error Domain=CSIndexErrorDomain Code=-1003 "(null)"
2016-04-14 8:12:56.113 PM com.apple.spotlight.IndexAgent[14767]: [com.apple.corespotlight.log] Not allowed to pass in bundle ID
2016-04-14 8:12:56.113 PM IMDPersistenceAgent[679]: [com.apple.corespotlight.log.index] Finished "index items"(64) with error:Error Domain=CSIndexErrorDomain Code=-1003 "(null)"
2016-04-14 8:12:56.113 PM IMDPersistenceAgent[679]: [Warning] IMDChatAddMessageToSpotlight: deleting message for searchable items failed with error Error Domain=CSIndexErrorDomain Code=-1003 "(null)"
2016-04-14 8:12:56.113 PM IMDPersistenceAgent[679]: [Warning] IMDChatAddMessageToSpotlight: deleting message for searchable items failed with error Error Domain=CSIndexErrorDomain Code=-1003 "(null)"
2016-04-14 8:13:03.890 PM com.apple.CDScheduler[63]: *** LOG MESSAGE QUOTA EXCEEDED - SOME MESSAGES FROM THIS PROCESS HAVE BEEN DISCARDED ***
Clearing out the ~/Library/Messages folder and rebooting seemed to help, but that is temporary at best because, even without the Messages app running, the incoming messages still recreate the database there. I'm currently running without Messages launched and yet I'm in the middle of an event as I write this. Is it related? Who knows? Even if I could totally disable Messages, I don't want to.
Today, nothing I try seems to help. There you have it gurus. What can I try now?
Mac mini, OS X Mavericks (10.9.4), 2.6 GHz i7, 16 GB RAM; 1 TB Fusion
Posted on May 23, 2016 2:28 PM
Please back up all data before proceeding.
Triple-click anywhere in the line below on this page to select it:
/var/root
Right-click or control-click the highlighted line and select
Services ▹ Reveal in Finder (or just Reveal)
from the contextual menu.* A folder should open with an item selected. Move the selected item to the Trash. You may be prompted for your administrator login password. Restart the computer and empty the Trash.
*If you don't see the contextual menu item, copy the selected text to the Clipboard by pressing the key combination command-C. In the Finder, select
Go ▹ Go to Folder...
from the menu bar and paste into the box that opens by pressing command-V. You may not see what you pasted because a line break is included. Press return.
Posted on May 28, 2016 1:27 PM