Apache won't start (was: Hi, I need some help)
Ryan Schmidt
ryandesign at macports.org
Wed Jul 28 09:18:06 PDT 2010
On Jul 28, 2010, at 11:13, Ali A Samii wrote:
> OK, prior to the total reinstall I did, apache was running, as was mysql
>
> when I do a ps auxw | grep
> and query for httpd - no process running now
> and query for mysql - no process running now
>
> It appears that nothing is running.
>
> I just issued "sudo touch /opt/local/apache2/conf/httpd.conf" command
why?
> I followed it by "sudo /opt/local/apache2/bin/apachectl start"
> I didn't get an error message nor any feedback whatsoever.
I think that's normal.
> However, I decided to try to get to localhost, and for some reason, something changed because I got there.
>
> So, I issued a " ps auxw | grep httpd": and it seems I now have 11 httpd start processes!
>
> _www 1510 0.0 0.0 2451584 1548 ?? S 6:07PM 0:00.00 /opt/local/apache2/bin/httpd -k start
> _www 1509 0.0 0.0 2451584 1564 ?? S 6:07PM 0:00.00 /opt/local/apache2/bin/httpd -k start
> _www 1508 0.0 0.0 2451584 1544 ?? S 6:07PM 0:00.00 /opt/local/apache2/bin/httpd -k start
> _www 1507 0.0 0.1 2451584 1636 ?? S 6:07PM 0:00.01 /opt/local/apache2/bin/httpd -k start
> root 1506 0.0 0.2 2451584 5316 ?? Ss 6:07PM 0:00.09 /opt/local/apache2/bin/httpd -k start
> ali 1550 0.0 0.0 2425568 204 s000 U+ 6:09PM 0:00.00 grep httpd
> _www 1521 0.0 0.0 2451584 620 ?? S 6:07PM 0:00.00 /opt/local/apache2/bin/httpd -k start
> _www 1520 0.0 0.0 2451584 620 ?? S 6:07PM 0:00.00 /opt/local/apache2/bin/httpd -k start
> _www 1519 0.0 0.0 2451584 620 ?? S 6:07PM 0:00.00 /opt/local/apache2/bin/httpd -k start
> _www 1518 0.0 0.0 2451584 620 ?? S 6:07PM 0:00.00 /opt/local/apache2/bin/httpd -k start
> _www 1517 0.0 0.0 2451584 620 ?? S 6:07PM 0:00.00 /opt/local/apache2/bin/httpd -k start
> _www 1516 0.0 0.0 2451584 620 ?? S 6:07PM 0:00.00 /opt/local/apache2/bin/httpd -k start
Ok good. Note that you've just started the server, not scheduled it to start at system startup. So if you restart your computer, the server will not start again.
If you want the server to start at system startup, use the launchd plist MacPorts has installed for you. The simple way to do that is to first stop Apache again, then run "sudo port load apache2". If you ever want to undo that, then you run "sudo port unload apache2". You can also use any 3rd-party launchd plist manager. Lingon used to be a good one, but is no longer being developed; not sure if there's a current alternative.
> But still no mysql.
Ok, so what's going on there? Logs? Messages?
More information about the macports-users
mailing list