How do I stop Apache from starting up automatically?

I'm running Mac OS X Lion 10.7.2 and Web Sharing is turned off in System Prefs.

I don't think this is specifically related to Lion.

Basically, I'm a frontend developer and there are always backend developers messing around in my terminal trying to make my life easier, but not explaining exactly what they're doing. So I suspect someone put something somewhere to explicitly command my Mac to start Apache automatically on startup. Here's all I know:

ps aux | grep apache

shows that Apache is running

launchctl list

doesn't show Apache afaik, but if it did I wouldn't know what it would be called anyway

sudo apachectl stop

returns launchctl: Error unloading: org.apache.httpd

sudo apachectl -k stop

returns httpd (no pid file) not running

Any advice would be appreciated. Thank you.


Solution 1:

Are you sure that it is apache you are seeing running. When you do the

ps aux|grep apache

You will see one process ( the shell process that is looking for the string apache)

A running apache server is not called apache it is called httpd, and you will see multiple instances of this (one parent daemon which in turn spawns workers). The apachectl is reporting correctly that it is not running

Solution 2:

Apache is part of the Mac OS is is always running (if you have set on websharing). That is, if you've not installed the specific software "Apache". But it's included in Mac OS and runs by default.

So is it causing any performance issues or is your work suffering from it? If not, let it be. It doesn't do any harm. If it does, try looking for a solution in this previous topic.