[launchd-dev] Starting launch agents

Jeremy Reichman jaharmi at jaharmi.com
Thu Oct 4 05:59:27 PDT 2007


I'm also having a problem with a LaunchAgent in the local domain.

I'm trying to install it to /Library/LaunchAgents via a package installer on
Mac OS X 10.4.10 (PowerPC on my test system). It installs and appears loaded
via Lingon, but even a logout and login does not cause it to run.

I've also tried to load and start it at the command line via launchctl, and
the specified script does not run ... at least not in a reasonable amount of
time (30 sec). I don't know if this is because I've specified LowPriorityIO
or not, but toggling that setting on/off hasn't seemed to make a difference
yet. I'm just copying one file from /Library to ~/Library.

The script itself runs without error if I execute it directly without the
LaunchAgent. However, I'd like to be able to execute it for each user -- as
the user -- as they log in, and I don't want to set up and use a LoginHook
instead.

I also want the installer to make sure the LaunchAgent is set up and
running, and preferably run the job once for that current user. While I can
do that with a postinstall script in the package installer that calls the
LaunchAgent's target script, I'd really like to make sure that the LA is
ready to go.

I feel like I'm missing something.


-- 
Jeremy




More information about the launchd-dev mailing list