Languages

Archived - Mac OS X Server v10.5, 10.6: Enabling Directory Service debug logging

When troubleshooting Directory Service issues, it is often helpful to obtain "debug" logs to determine the source of the issue and any underlying issues produced by client requests to the DirectoryService process.

Starting with Mac OS X v10.5, a flag is included to set the Directory Service Debug Logging Priority Level to include more data including the actual LDAP queries being made by DirectoryService.  This setting is specific to Mac OS X v10.5 and later and will not work on previous versions.

This article has been archived and is no longer updated by Apple.

Note: In OS X Lion and Lion Server, DirectoryService is replaced by opendirectoryd. See this article for opendirectoryd logging instructions.

To set the Directory Service Debug Log Level to a higher level, open Terminal and execute the following command:

sudo defaults write /Library/Preferences/DirectoryService/DirectoryServiceDebug "Debug Logging Priority Level" -integer 7


To enable Directory Service logging manually (after log in), open Terminal and execute the following command:

sudo killall -USR1 DirectoryService
 

To enable Directory Service logging at restart, open Terminal and run the following command, followed by a restart of the machine:

sudo touch /Library/Preferences/DirectoryService/.DSLogDebugAtStart

 
To disable Directory Service logging, open Terminal and execute the following command:

sudo killall -USR1 DirectoryService

Note: If you enabled Directory Service logging on restart, delete the .DSLogDebugAtStart file from /Library/Preferences/DirectoryService so that Directory Service Debug Logging remains off should the machine be restarted.

The logs are saved to /Library/Logs/DirectoryService.

Additional Information

This logging is very verbose and should be disabled once troubleshooting is complete.

Last Modified: Mar 19, 2014
Helpful?
Yes
No
  • Last Modified: Mar 19, 2014
  • Article: HT3186
  • Views:

    null

Additional Product Support Information

Start a Discussion
in Apple Support Communities
See all questions on this article See all questions I have asked