How to correctly add daemon in MacOS 10.6.6 via launchd?

Posted by Eye of Hell on Server Fault See other posts from Server Fault or by Eye of Hell
Published on 2011-03-11T12:14:28Z Indexed on 2011/03/18 0:11 UTC
Read the original article Hit count: 545

Filed under:
|
|

Hello.

I have a very simple task to accomplish: to start tomcat application server on latest MacOS as a daemon. I have performed following steps:

  1. Installed Tomcat in /Library/Tomcat/Home
  2. Validated that it runs fine by executed /Library/Tomcat/Home/bin/startup.sh
  3. Added org.apache.tomcat.plist file to /Library/LaunchDaemons as found on internet (http://blog.i18n.ro/complete-guide-for-installing-hudson-ci-on-os-x-10-6/)
  4. Instructed MacOS to load a daemon description via sudo launchctl load org.apache.tomcat.plist. It succeeded (issuing this command second time outputs "already loaded").
  5. Instructed MacOS to start a daeon via sudo launchctl start org.apache.tomcat.plist

At this point MacOS shows an error "launchctl start error: No such process". I have checked the logfile for launchd - it have no record for this error. Google says nothing. And from error text i can't figure out what is the "process" and why it is "wrong" :(. Any hints what i'm doing wrong?

© Server Fault or respective owner

Related posts about macosx

Related posts about tomcat