Macos – How to get rid of com.apple.launchd.peruser errors in the log

launchdmacosmigration-assistant

I'm getting repeated errors in my console log that look (basically) like this:

10-09-29 10:06:08 AM com.apple.launchd[1] (com.apple.launchd.peruser.501[51581]) getpwuid("501") failed
10-09-29 10:06:08 AM com.apple.launchd[1] (com.apple.launchd.peruser.501[51581]) Exited with exit code: 1

This machine was set up using the migration assistant, from a machine where my UID was 501, but here it's 505. I have the same username and group set, of course, but…

So, where is this peruser launchd tool configured, so that I can disable the daemons that are causing this error message?

Best Answer

I can answer your last question, but it will take more work to solve the problem.

The peruser indicates a launchd daemon started by a userland process. The numeric suffix is the UID. In this case, an application attempted load a launchd job as user 501. That failed, since there appears to be no user 501 on your system.

Have you installed software recently? User management utilities changed in Leopard, so an installer intended for an older version (Tiger?) may not work properly in 10.5,6.

Start by taking a look at ~/Library/LaunchAgents, /Library/LauchAgents, and /Library/LaunchDaemons. There may be a job that's UID 501.

If not, you could do a (brute-force) search for an application/file owned by 501 -

$ sudo find /Applications -user 501 | less

If anything turns up, that will point to the culprit.

Related Question