On Aug 1, 2009, at 11:38 PM, Björn Giesler wrote:
Hi,
I've recently migrated to a new MacBook Pro, and since that migration, found that Bonjour no longer worked, and indeed that all applications that used Bonjour just hang. I've traced this to what looks like a problem in the interaction of mDNSResponder and launchd; the log messages I get are lots of
com.apple.launchd[1] (com.apple.mDNSResponder[2551]): Policy denied Mach service lookup: com.apple.distributed_notifications.2
etc.etc. with different services.
I don't yet quite understand how launchd and launched processes interact. Why is launchd responsible for service lookups for other applications? Where are policies stored? etc. The manpage says nothing about this.
I've tried looking for the above message in the launchd code and found it in launchd_core_logic.c in the SULeopard branch, which introduces the mspolicy_* functions, but I'm afraid I can't make much sense of it. I'll try to compile my own launchd and step through it, but it would be nice if somebody could push me in the right direction. (Is there even some documentation on this?) As a Unix rc guy, launchd is a twisty maze of passages, all alike...
mDNSResponder has a policy set on it saying that is is allowed to look up only a certain set of MachService names. "com.apple.distributed_notifications.2" is not in that list, so we log a warning about it. There's probably a framework behind the scenes that mDNSResponder uses that is looking up that service. It's basically a harmless error (I don't believe distributed notifications are essential to mDNSResponder's function), but feel free to file a bug against mDNSResponder. -- Damien Sorresso BSD Engineering Apple Inc.