Macports, Apache PATH evn?

Ryan Schmidt ryandesign at macports.org
Sat May 15 15:13:39 PDT 2010


On May 15, 2010, at 15:35, Scott Haneda wrote:

> What does port load/unload do in this regard?

sudo port load apache2

is exactly equivalent to running

sudo launchctl load -w /Library/LaunchDaemons/org.macports.apache2.plist

See

http://trac.macports.org/browser/tags/release_1_8_2/base/src/port1.0/portload.tcl#L60

Similarly for unload.


> Aren't there also port start/stop commands as well?

No.

$ port stop
Unrecognized action "stop"
$ port start
Unrecognized action "start"

And there is no equivalent for restart or graceful.

The purpose of launchd is to notice when programs exit unexpectedly and to then relaunch them. Using apachectl to stop or restart apache2 amounts to it unexpectedly quitting in the eyes of launchd, which would cause launchd to try to launch it again. This is why I don't recommend using apachectl if you're using launchd. Apache's graceful restart feature is very nice, but I don't know what happens when you try to use that when you're already using launchd.




More information about the macports-users mailing list