1

I've tried other solutions I've found on StackExchange for this same problem, but must have a unique situation that is still causing problems. I have a hosts file setup as follows:

127.0.0.1               localhost.localdomain localhost     host.ciaciagi.com
255.255.255.255         broadcasthost
::1                     localhost.localdomain localhost     host.ciaciagi.com
fe80::1%lo0             localhost

I have httpd.conf setup and the line for LoadModule unique_id_module libexec/apache2/mod_unique_id.so commented out (as others have suggested).

I can ping 127.0.0.1 and get this:

$ ping 127.0.0.1
PING 127.0.0.1 (127.0.0.1): 56 data bytes
64 bytes from 127.0.0.1: icmp_seq=0 ttl=64 time=0.082 ms

I've run

$ sudo apachectl configtest
Syntax OK

I checked for a corrupt virtual hosts file. Everything was fine.

Restarting apache shows nothing significant (nothing at all):

$ sudo apachectl restart
$ 

Opening a browser and attempting to connect to http://localhost/ (I've tried 3 browsers and their private/incognito windows), I still get "Unable to connect" or its equivalent for the browser.

Any ideas?

  • Is the web server running at all? – nohillside Jan 2 '17 at 19:45
  • How can I tell if it's not running? Restarting shows nothing. The commands for apachectl never return anything to me. @patrix – ChiCgi Jan 2 '17 at 22:04
  • @ChiCgi Check if apache is running: ps aux | grep "httpd". Pinging 127.0.0.1 is unrewarding. You have to ping localhost or ping host.ciaciagi.com! – klanomath Jan 2 '17 at 22:36
3

People [including me] have had success by swapping

::1 localhost

to

::1 127.0.0.1

though that's in a non-domain setup

worth a shot?

1

I've found that Apache wasn't loading in my ssl configurations in a way that functioned just fine on El Capitan. After removing the SSL configuration, everything worked just fine. I still don't know why my configtest passed with no problems. The error in the logs was:

(48)Address already in use: AH00072: make_sock: could not bind to address 0.0.0.0:443
[Mon Jan 02 09:57:46.057772 2017] [mpm_prefork:alert] [pid 452] no listening sockets available, shutting down
[Mon Jan 02 09:57:46.057779 2017] [:emerg] [pid 452] AH00019: Unable to open logs, exiting

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .