1

For the longest time I was a MAMP user, until yesterday, something went terribly wrong and MAMP would no longer start mysql. Long story short I decided to ditch MAMP and just setup my own AMP server, so I found a good tutorial and set one up. All was working well until I went to create a virtual host. One step of the directions had me editing the /etc/apache2/httpd.conf file. I somehow managed to delete much of that file and saved it - UGGG! Since then I have been unable to resolve http://localhost.

I was able to locate the contents of the httpd.conf file on another mac and replaced the contents and saved, then restarted apache, and still I am unable to resolve http://localhost. I get the error: Oops! Google Chrome could not connect to localhost.

In Terminal I am able to ping localhost and I get the result 64 bytes from 127.0.0.1: icmp_seq=0 ttl=64 time=0.044 ms

I am completely at a loss here, as far as I can tell I have reset everything back to the way it should be. Here is what I am checking:

/etc/hosts /etc/apache2/httpd.conf

I have restarted apache, and my computer a number of times to no avail.

And both files, as far as I can tell are set as they would be from a fresh install.

Can anyone offer some advice here? Is there a way that I can further trouble shoot this issue? A log that I can look at? I really need to get this local environment back up and running and would prefer to not need to reinstall my entire OS. Any direction is greatly appreciated!

2
  • ping will always resolve localhost, it's unrelated. The problem seems to be solely with Apache, OS X has nothing to do with it. Just re-install the Apache bundle to the same destination (uninstall it beforehand, if possible, or at least stop the server). Since you say you did a fresh install of the server not so long ago, re-installing it in the same location shouldn't make much difference, except positive one. Mar 2, 2013 at 20:53
  • Does your hosts file contain the usual 127.0.0.1 localhost entry? Mar 2, 2013 at 20:59

0

You must log in to answer this question.

Browse other questions tagged .