[MacPorts] howto/MAMP modified

Daniel J. Luke dluke at geeklair.net
Fri Nov 19 07:16:11 PST 2010


On Nov 19, 2010, at 8:02 AM, Jeremy Lavergne wrote:
> 
>> +However, the purpose of launchd is to notice processes that stop without its knowledge, and to restart them. So if you use apachectl -k restart, launchd may notice apache "crashing" and restart it itself, confusing apachectl. Instead, you may want to use launchctl to unload apache2, then load it again. This will result in a short interruption of service.
>> +
>> +This is done by using 
>> +
>> +{{{
>> +sudo launchctl unload -w /Library/LaunchDaemons/org.macports.apache2.plist
>> +}}}
>> +
>> +to stop apache and then using
>> +
>> +{{{
>> +sudo launchctl load -w /Library/LaunchDaemons/org.macports.apache2.plist
>> +}}}
>> +
>> +to start it again.
>> +
> 
> Would port load and port unload suffice?

I think so.

You can also just 'stop' apache with apachectl and launchd will restart it...

--
Daniel J. Luke                                                                   
+========================================================+                        
| *---------------- dluke at geeklair.net ----------------* |                          
| *-------------- http://www.geeklair.net -------------* |                          
+========================================================+                        
|   Opinions expressed are mine and do not necessarily   |                          
|          reflect the opinions of my employer.          |                          
+========================================================+





More information about the macports-dev mailing list