« Compiling WebAuth for Leopard's Apache2 | Main | Autoset SSH GSSAPIDelegateCredentials on MacOS X »

an effective way to restart syslogd

I've been busy modifying the syslogd.conf file on various servers to additionally send entries to a central syslog server. Getting syslogd to restart properly after modifying the conf file proved to be more problematic than it should be.

You'd think you'd be able to use a kill -HUP, but that's not appropriate here. You'd think you'd be able to issue a launchctl stop command, but that doesn't do it either. If you just kill it, even with a -9 flag, you'll see launchd just happily pops up a new one. That was my case, but the new syslogd wasn't actually logging.

Instead, what worked for me was to issue this command.

root# launchctl unload /System/Library/LaunchDaemons/com.apple.syslogd.plist; sleep 1; launchctl load /System/Library/LaunchDaemons/com.apple.syslogd.plist  

TrackBack

TrackBack URL for this entry:
http://www.stanford.edu/group/macosxsig/cgi-bin/mt/mt-tb.cgi/19

Comments (1)

Anonymous:

Thanks!
My syslogd started using >99% proc and this worked for restarting it.

Post a comment

(If you haven't left a comment here before, you may need to be approved by the site owner before your comment will appear. Until then, it won't appear on the entry. Thanks for waiting.)


About

This page contains a single entry from the blog posted on March 4, 2008 6:24 PM.

The previous post in this blog was Compiling WebAuth for Leopard's Apache2.

The next post in this blog is Autoset SSH GSSAPIDelegateCredentials on MacOS X.

Many more can be found on the main index page or by looking through the archives.

Creative Commons License
This weblog is licensed under a Creative Commons License.