0

I did something stupid today without thinking. I have a headless home server running Ubuntu Server LTS 18.04.

I also have apache running, and several websites that I access only inside my home network, such as a wiki were I keep all my documentation.

I thought I was logged into a VM of Ubuntu and ran the pi hole installation script. When I was done, I realized I was on the wrong server and that I had installed it on my home server.

So let's assume my home server has the IP 192.168.1.7.

When I pointed to that IP I saw the pi hole logo and a link to the admin panel.

When I tried to load 192.168.1.7/wiki - which was how I accessed my wiki page I again saw the pi hole logo and a link to the admin panel.

I then decided to uninstall pi hole.

Now when I try to load 192.168.1.7/wiki I see:

404 Not found

I tried to restart apache2 /etc/init.d/apache2 restart and see this error message:

[....] Restarting apache2 (via systemctl): apache2.serviceJob for apache2.service failed because the control process exited with error code.
See "systemctl status apache2.service" and "journalctl -xe" for details.
 failed!

If I try to check the status of apache sudo systemctl status apache2.service I see:

● apache2.service - The Apache HTTP Server
   Loaded: loaded (/lib/systemd/system/apache2.service; enabled; vendor preset: enabled)
  Drop-In: /lib/systemd/system/apache2.service.d
           └─apache2-systemd.conf
   Active: failed (Result: exit-code) since Fri 2020-01-10 12:09:51 CET; 1min 50s ago
  Process: 1881 ExecStart=/usr/sbin/apachectl start (code=exited, status=1/FAILURE)

Jan 10 12:09:51 server apachectl[1881]: (98)Address already in use: AH00072: make_sock: could not bind to address [::]:80
Jan 10 12:09:51 server apachectl[1881]: (98)Address already in use: AH00072: make_sock: could not bind to address 0.0.0.0:80
Jan 10 12:09:51 server apachectl[1881]: no listening sockets available, shutting down
Jan 10 12:09:51 server apachectl[1881]: AH00015: Unable to open logs
Jan 10 12:09:51 server apachectl[1881]: Action 'start' failed.
Jan 10 12:09:51 server apachectl[1881]: The Apache error log may have more information.
Jan 10 12:09:51 server systemd[1]: apache2.service: Control process exited, code=exited status=1
Jan 10 12:09:51 server systemd[1]: apache2.service: Failed with result 'exit-code'.
Jan 10 12:09:51 server systemd[1]: Failed to start The Apache HTTP Server.

/var/log/apache2/error.log is currently empty.

Stumped at what to do to get the web server back up and running.

  • 1
    maybee the pihole process still hanging? post the output of ps -ef | grep pihole and netstat -tulpan | grep 80 – lese Jan 10 at 11:27
  • Thank you, you put me on the right track, I checked which service was listening on port 80 and it was lighttpd. Uninstalled it and tried getting apache to start worked! Feel free to post as a solution and I will mark as solved. – BrokenCode Jan 10 at 11:29

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.