Lets Encrypt error with ubuntu 16.04

July 15, 2017 137 views
Apache Ubuntu 16.04

Hello, I'm newbie and I'm trying to use letsencrypt on my site following this tutorial
https://www.digitalocean.com/community/tutorials/how-to-secure-apache-with-let-s-encrypt-on-ubuntu-16-04 but it gives the following error below. Can someone help me....

Error while running apache2ctl graceful.
httpd not running, trying to start
Action 'graceful' failed.
The Apache error log may have more information.

AH00112: Warning: DocumentRoot [/var/lib/letsencrypt/tlssni01page/] does not exist
AH00112: Warning: DocumentRoot [/var/lib/letsencrypt/tls
sni01page/] does not exist
AH00558: apache2: Could not reliably determine the server's fully qualified doma in name, using 127.0.1.1. Set the 'ServerName' directive globally to suppress th is message
(98)Address already in use: AH00072: makesock: could not bind to address [::]:8 0
(98)Address already in use: AH00072: make
sock: could not bind to address 0.0.0. 0:80
no listening sockets available, shutting down
AH00015: Unable to open logs

Cleaning up challenges
Error while running apache2ctl graceful.
httpd not running, trying to start
Action 'graceful' failed.
The Apache error log may have more information.

AH00558: apache2: Could not reliably determine the server's fully qualified doma in name, using 127.0.1.1. Set the 'ServerName' directive globally to suppress th is message
(98)Address already in use: AH00072: makesock: could not bind to address [::]:8 0
(98)Address already in use: AH00072: make
sock: could not bind to address 0.0.0. 0:80
no listening sockets available, shutting down
AH00015: Unable to open logs

Encountered exception during recovery
Error while running apache2ctl graceful.
httpd not running, trying to start
Action 'graceful' failed.
The Apache error log may have more information.

AH00558: apache2: Could not reliably determine the server's fully qualified doma in name, using 127.0.1.1. Set the 'ServerName' directive globally to suppress th is message
(98)Address already in use: AH00072: makesock: could not bind to address [::]:8 0
(98)Address already in use: AH00072: make
sock: could not bind to address 0.0.0. 0:80
no listening sockets available, shutting down
AH00015: Unable to open logs
Traceback (most recent call last):
File "/usr/lib/python2.7/dist-packages/certbot/errorhandler.py", line 99, in _callregistered
self.funcs-1
File "/usr/lib/python2.7/dist-packages/certbot/authhandler.py", line 284, in _cleanupchallenges
self.auth.cleanup(achalls)
File "/usr/lib/python2.7/dist-packages/certbotapache/configurator.py", line 1 908, in cleanup
self.restart()
File "/usr/lib/python2.7/dist-packages/certbot
apache/configurator.py", line 1 797, in restart
self.reload()
File "/usr/lib/python2.7/dist-packages/certbot
apache/configurator.py", line 1 808, in _reload
raise errors.MisconfigurationError(str(err))
MisconfigurationError: Error while running apache2ctl graceful.
httpd not running, trying to start
Action 'graceful' failed.
The Apache error log may have more information.

AH00558: apache2: Could not reliably determine the server's fully qualified doma in name, using 127.0.1.1. Set the 'ServerName' directive globally to suppress th is message
(98)Address already in use: AH00072: makesock: could not bind to address [::]:8 0
(98)Address already in use: AH00072: make
sock: could not bind to address 0.0.0. 0:80
no listening sockets available, shutting down
AH00015: Unable to open logs

1 Answer
hansen July 15, 2017
Accepted Answer

Hi @erikolombardi

Does it give the error, when you're trying to run this command?

sudo certbot --apache -d yourdomain.com

Have you setup Apache already or are you trying to install Let's Encrypt on a new installation?

Can you also run this command to list the services listening on the ports:

sudo lsof -iTCP -sTCP:LISTEN -P
  • Hi

    Yes, the error happens when I use this command. It's a new droplet, and I used Serverpilot to install wordpress

    When I use this command you asked for this appears:

    First Header | Second Header
    -COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME
    sshd 1511 root 3u IPv4 51844 0t0 TCP *:22 (LISTEN)
    sshd 1511 root 4u IPv6 51846 0t0 TCP *:22 (LISTEN)
    master 14965 root 12u IPv4 41238 0t0 TCP localhost:25 (LISTEN)
    mysqld 16532 mysql 29u IPv4 44699 0t0 TCP localhost:3306 (LISTEN)
    httpd 17885 root 3u IPv4 47007 0t0 TCP localhost:81 (LISTEN)
    nginx 18035 root 17u IPv4 53343 0t0 TCP *:80 (LISTEN)
    nginx 18035 root 18u IPv6 53344 0t0 TCP *:80 (LISTEN)
    httpd 19072 www-data 3u IPv4 47007 0t0 TCP localhost:81 (LISTEN)
    httpd 19073 www-data 3u IPv4 47007 0t0 TCP localhost:81 (LISTEN)
    httpd 19074 www-data 3u IPv4 47007 0t0 TCP localhost:81 (LISTEN)
    nginx 19160 www-data 17u IPv4 53343 0t0 TCP *:80 (LISTEN)
    nginx 19160 www-data 18u IPv6 53344 0t0 TCP *:80 (LISTEN)
    nginx 19161 www-data 17u IPv4 53343 0t0 TCP *:80 (LISTEN)
    nginx 19161 www-data 18u IPv6 53344 0t0 TCP *:80 (LISTEN)
    nginx 19162 www-data 17u IPv4 53343 0t0 TCP *:80 (LISTEN)
    nginx 19162 www-data 18u IPv6 53344 0t0 TCP *:80 (LISTEN)
    nginx 19163 www-data 17u IPv4 53343 0t0 TCP *:80 (LISTEN)
    nginx 19163 www-data 18u IPv6 53344 0t0 TCP *:80 (LISTEN)
    httpd 19200 www-data 3u IPv4 47007 0t0 TCP localhost:81 (LISTEN)

Have another answer? Share your knowledge.