# Solved: Apache2 on Mac OS X 10.6 does not seem to be working



## andynic (May 25, 2007)

When I put the following URL into Safari
http://localhost/dev/gfrm.cgi?init
or
http://10.0.0.150/dev/gfrm.cgi?init

Safari returns the message:
Safari cant open the page http://localhost/dev/gfrm.cgi?init because Safari cant connect to the server localhost. (or 10.0.0.150)

(10.0.0.150 is the address showing in system preferences --> Sharing when "Web sharing" is checked
gfrm.cgi is a perl cgi script that ran perfectly in an apache2 installation on Windows XP).

Any ideas of what I need to do to get apache running on Mac OS X 10.6 (Snow Leopard)?

Thanks for your help
Andnic


----------



## andynic (May 25, 2007)

Problem solved:
I stopped the service via system preferences --> sharing; and unchecked "web sharing".

Then via a terminal window used:
sudo apachectl -k start

The above command said there was an error at a sepcific line number in httpd.conf which is located in /private/etc/apache2

I commented out the offending line and the server started using
sudo apachectl -k start.
Andynic


----------

