Connection refused after apache update

apache-2.2connection

After I updated my apache, none of my virtual hosts are accessible anymore, the server responds "Connection refused". No errors are in the logs and I have no idea what is causing this. My virtual host is something like this:

 <VirtualHost 173.XXX.XXX.XXX:80>
      ....
      ServerName hostname.com
      ....
 </VirtualHost>
 <VirtualHost 173.XXX.XXX.XXX:443>
      ....
      ServerName hostname.com
      ....
 </VirtualHost>

Any ideas of how to debug?

Best Answer

"Connection refused" would mean that apache is not listening on port 80; run this command to make sure" lsof -i:80, if you found no output then start apache and try again

Update: after seeing some output of different commands; it turned out that libapache2-mod-php5 is not installed according to dpkg -l | grep apache2 it was flagged as 'rc' (removed, but configuration files remaining). Since the debug information was showing loading mod_php5 then the absence of this package is what causing apache not to start