Certbot mistakes my ip and localhost (and more errors)

My domain is: calmera.es

I ran this command: sudo certbot --apache certonly

It produced this output:

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 domain name, using 127.0.0.1. Set the ‘ServerName’ directive globall y to suppress this message
(98)Address already in use: AH00072: make_sock: could not bind to address [::]:80
(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 domain name, using 127.0.0.1. Set the ‘ServerName’ directive globall y to suppress this message
(98)Address already in use: AH00072: make_sock: could not bind to address [::]:80
(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 domain name, using 127.0.0.1. Set the ‘ServerName’ directive globall y to suppress this message
(98)Address already in use: AH00072: make_sock: could not bind to address [::]:80
(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/python3/dist-packages/certbot_apache/configurator.py”, line 1998, in _reload
util.run_script(self.constant(“restart_cmd”))
File “/usr/lib/python3/dist-packages/certbot/util.py”, line 85, in run_script
raise errors.SubprocessError(msg)
certbot.errors.SubprocessError: 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 domain name, using 127.0.0.1. Set the ‘ServerName’ directive globall y to suppress this message
(98)Address already in use: AH00072: make_sock: could not bind to address [::]:80
(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

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File “/usr/lib/python3/dist-packages/certbot/auth_handler.py”, line 124, in _solve_challenges
resp = self.auth.perform(all_achalls)
File “/usr/lib/python3/dist-packages/certbot_apache/configurator.py”, line 2084, in perform
self.restart()
File “/usr/lib/python3/dist-packages/certbot_apache/configurator.py”, line 1989, in restart
self._reload()
File “/usr/lib/python3/dist-packages/certbot_apache/configurator.py”, line 2000, in _reload
raise errors.MisconfigurationError(str(err))
certbot.errors.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 domain name, using 127.0.0.1. Set the ‘ServerName’ directive globall y to suppress this message
(98)Address already in use: AH00072: make_sock: could not bind to address [::]:80
(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

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File “/usr/lib/python3/dist-packages/certbot_apache/configurator.py”, line 1998, in _reload
util.run_script(self.constant(“restart_cmd”))
File “/usr/lib/python3/dist-packages/certbot/util.py”, line 85, in run_script
raise errors.SubprocessError(msg)
certbot.errors.SubprocessError: 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 domain name, using 127.0.0.1. Set the ‘ServerName’ directive globall y to suppress this message
(98)Address already in use: AH00072: make_sock: could not bind to address [::]:80
(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

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File “/usr/lib/python3/dist-packages/certbot/error_handler.py”, line 100, in _call_registered
self.funcs-1
File “/usr/lib/python3/dist-packages/certbot/auth_handler.py”, line 303, in _cleanup_challenges
self.auth.cleanup(achalls)
File “/usr/lib/python3/dist-packages/certbot_apache/configurator.py”, line 2109, in cleanup
self.restart()
File “/usr/lib/python3/dist-packages/certbot_apache/configurator.py”, line 1989, in restart
self._reload()
File “/usr/lib/python3/dist-packages/certbot_apache/configurator.py”, line 2000, in _reload
raise errors.MisconfigurationError(str(err))
certbot.errors.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 domain name, using 127.0.0.1. Set the ‘ServerName’ directive globall y to suppress this message
(98)Address already in use: AH00072: make_sock: could not bind to address [::]:80
(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

My web server is (include version): Ubuntu 16.04 LTS

I can login to a root shell on my machine (yes or no, or I don’t know): Yes

I’m using a control panel to manage my site (no, or provide the name and version of the control panel): No

Can you stop Apache and then run:

sudo ss -tlnp
sudo grep -Rei Listen /etc/apache2/conf*

Thanks in advance. I did that, and this is the output:
ubuntu@servidor-1:~$ sudo ss -tlnp
State Recv-Q Send-Q Local Address:Port Peer Address:Port
LISTEN 0 80 127.0.0.1:3306 : users:((“mysqld”,pid=22492,fd=38))
LISTEN 0 128 :22 : users:((“sshd”,pid=7133,fd=3))
LISTEN 0 128 :::80 :::
users:(("/opt/lampp/bin/",pid=31637,fd=4),("/opt/lampp/bin/",pid=31625,fd=4),("/ opt/lampp/bin/",pid=31587,fd=4),("/opt/lampp/bin/",pid=31558,fd=4),("/opt/lampp/ bin/",pid=31557,fd=4),("/opt/lampp/bin/",pid=31490,fd=4),("/opt/lampp/bin/",pid= 31469,fd=4),("/opt/lampp/bin/",pid=31419,fd=4),("/opt/lampp/bin/",pid=31312,fd=4 ),("/opt/lampp/bin/",pid=31183,fd=4),("/opt/lampp/bin/",pid=12849,fd=4),("/opt/l ampp/bin/",pid=2285,fd=4))
LISTEN 0 5 :::21 :::* users:((“proftpd”,pid=2338,fd=0))
LISTEN 0 128 :::22 :::* users:((“sshd”,pid=7133,fd=4))
LISTEN 0 128 :::443 :::* users:(("/opt/lampp/bin/",pid=31637,fd=6),("/opt/lampp/bin/",pid=31625,fd=6),("/ opt/lampp/bin/",pid=31587,fd=6),("/opt/lampp/bin/",pid=31558,fd=6),("/opt/lampp/ bin/",pid=31557,fd=6),("/opt/lampp/bin/",pid=31490,fd=6),("/opt/lampp/bin/",pid= 31469,fd=6),("/opt/lampp/bin/",pid=31419,fd=6),("/opt/lampp/bin/",pid=31312,fd=6 ),("/opt/lampp/bin/",pid=31183,fd=6),("/opt/lampp/bin/",pid=12849,fd=6),("/opt/l ampp/bin/",pid=2285,fd=6))

And then:
ubuntu@servidor-1:~$ sudo grep -Rei Listen /etc/apache2/conf*
grep: Listen: No such file or directory
/etc/apache2/conf-available/charset.conf:# Read the documentation before enablin g AddDefaultCharset.
/etc/apache2/conf-available/charset.conf:# In general, it is only a good idea if you know that all your files
/etc/apache2/conf-available/charset.conf:# have this encoding. It will override any encoding given in the files
/etc/apache2/conf-available/charset.conf:# in meta http-equiv or xml encoding ta gs.
/etc/apache2/conf-available/charset.conf:# vim: syntax=apache ts=4 sw=4 sts=4 sr noet
/etc/apache2/conf-available/security.conf:# Disable access to the entire file sy stem except for the directories that
/etc/apache2/conf-available/security.conf:# are explicitly allowed later.
/etc/apache2/conf-available/security.conf:# This currently breaks the configurat ions that come with some web application
/etc/apache2/conf-available/security.conf:# Debian packages.
/etc/apache2/conf-available/security.conf:#
/etc/apache2/conf-available/security.conf:# AllowOverride None
/etc/apache2/conf-available/security.conf:# Require all denied
/etc/apache2/conf-available/security.conf:#
/etc/apache2/conf-available/security.conf:# Changing the following options will not really affect the security of the
/etc/apache2/conf-available/security.conf:# server, but might make attacks sligh tly more difficult in some cases.
/etc/apache2/conf-available/security.conf:# This directive configures what you r eturn as the Server HTTP response
/etc/apache2/conf-available/security.conf:# Header. The default is ‘Full’ which sends information about the OS-Type
/etc/apache2/conf-available/security.conf:# and compiled in modules.
/etc/apache2/conf-available/security.conf:# Set to one of: Full | OS | Minimal | Minor | Major | Prod
/etc/apache2/conf-available/security.conf:# where Full conveys the most informat ion, and Prod the least.
/etc/apache2/conf-available/security.conf:#ServerTokens Minimal
/etc/apache2/conf-available/security.conf:# Optionally add a line containing the server version and virtual host
/etc/apache2/conf-available/security.conf:# name to server-generated pages (inte rnal error documents, FTP directory
/etc/apache2/conf-available/security.conf:# listings, mod_status and mod_info ou tput etc., but not CGI generated
/etc/apache2/conf-available/security.conf:# Set to “EMail” to also include a mai lto: link to the ServerAdmin.
/etc/apache2/conf-available/security.conf:# Set to one of: On | Off | EMail
/etc/apache2/conf-available/security.conf:#ServerSignature Off
/etc/apache2/conf-available/security.conf:ServerSignature On
/etc/apache2/conf-available/security.conf:# Set to “extended” to also reflect th e request body (only for testing and
/etc/apache2/conf-available/security.conf:# diagnostic purposes).
/etc/apache2/conf-available/security.conf:# Forbid access to version control dir ectories
/etc/apache2/conf-available/security.conf:# If you use version control systems i n your document root, you should
/etc/apache2/conf-available/security.conf:# probably deny access to their direct ories. For example, for subversion:
/etc/apache2/conf-available/security.conf:#<DirectoryMatch “/.svn”>
/etc/apache2/conf-available/security.conf:# Require all denied
/etc/apache2/conf-available/security.conf:#
/etc/apache2/conf-available/security.conf:# Setting this header will prevent MSI E from interpreting files as something
/etc/apache2/conf-available/security.conf:# else than declared by the content ty pe in the HTTP headers.
/etc/apache2/conf-available/security.conf:# Requires mod_headers to be enabled.
/etc/apache2/conf-available/security.conf:#Header set X-Content-Type-Options: “n osniff”
/etc/apache2/conf-available/security.conf:# Setting this header will prevent oth er sites from embedding pages from this
/etc/apache2/conf-available/security.conf:# site as frames. This defends against clickjacking attacks.
/etc/apache2/conf-available/security.conf:# Requires mod_headers to be enabled.
/etc/apache2/conf-available/security.conf:#Header set X-Frame-Options: “sameorig in”
/etc/apache2/conf-available/security.conf:# vim: syntax=apache ts=4 sw=4 sts=4 s r noet
/etc/apache2/conf-available/localized-error-pages.conf:# Customizable error resp onses come in three flavors:
/etc/apache2/conf-available/localized-error-pages.conf:# 1) plain text
/etc/apache2/conf-available/localized-error-pages.conf:# 2) local redirects
/etc/apache2/conf-available/localized-error-pages.conf:# 3) external redirects
/etc/apache2/conf-available/localized-error-pages.conf:#ErrorDocument 404 /missi ng.html
/etc/apache2/conf-available/localized-error-pages.conf:#ErrorDocument 404 “/cgi- bin/missing_handler.pl”
/etc/apache2/conf-available/localized-error-pages.conf:#ErrorDocument 402 http:/ /www.example.com/subscription_info.html
/etc/apache2/conf-available/localized-error-pages.conf:# Putting this all togeth er, we can internationalize error responses.
/etc/apache2/conf-available/localized-error-pages.conf:# We use Alias to redirec t any /error/HTTP_.html.var response to
/etc/apache2/conf-available/localized-error-pages.conf:# our collection of by-er ror message multi-language collections. We use
/etc/apache2/conf-available/localized-error-pages.conf:# includes to substitute the appropriate text.
/etc/apache2/conf-available/localized-error-pages.conf:# You can modify the mess ages’ appearance without changing any of the
/etc/apache2/conf-available/localized-error-pages.conf:# default HTTP_.ht ml.var files by adding the line:
/etc/apache2/conf-available/localized-error-pages.conf:#Alias /error/include/ “/ your/include/path/”
/etc/apache2/conf-available/localized-error-pages.conf:# which allows you to cre ate your own set of files by starting with the
/etc/apache2/conf-available/localized-error-pages.conf:# /usr/share/apache2/erro r/include/ files and copying them to /your/include/path/,
/etc/apache2/conf-available/localized-error-pages.conf:# even on a per-VirtualHo st basis. If you include the Alias in the global server
/etc/apache2/conf-available/localized-error-pages.conf:# context, is has to come before the ‘Alias /error/ …’ line.
/etc/apache2/conf-available/localized-error-pages.conf:# The default include fil es will display your Apache version number and your
/etc/apache2/conf-available/localized-error-pages.conf:# ServerAdmin email addre ss regardless of the setting of ServerSignature.
/etc/apache2/conf-available/localized-error-pages.conf:# WARNING: The configurat ion below will NOT work out of the box if you have a
/etc/apache2/conf-available/localized-error-pages.conf:# SetHan dler directive in a context somewhere. Adding
/etc/apache2/conf-available/localized-error-pages.conf:# the fo llowing three lines AFTER the context should
/etc/apache2/conf-available/localized-error-pages.conf:# make i t work in most cases:
/etc/apache2/conf-available/localized-error-pages.conf:# <Locat ion /error/>
/etc/apache2/conf-available/localized-error-pages.conf:# </Loca tion>
/etc/apache2/conf-available/localized-error-pages.conf:# The internationalized e rror documents require mod_alias, mod_include
/etc/apache2/conf-available/localized-error-pages.conf:# and mod_negotiation. T o activate them, uncomment the following 37 lines.
/etc/apache2/conf-available/localized-error-pages.conf:#
/etc/apache2/conf-available/localized-error-pages.conf:#
/etc/apache2/conf-available/localized-error-pages.conf:#
/etc/apache2/conf-available/localized-error-pages.conf:# A lias /error/ “/usr/share/apache2/error/”
/etc/apache2/conf-available/localized-error-pages.conf:# < Directory “/usr/share/apache2/error”>
/etc/apache2/conf-available/localized-error-pages.conf:# O ptions IncludesNoExec
/etc/apache2/conf-available/localized-error-pages.conf:# A ddOutputFilter Includes html
/etc/apache2/conf-available/localized-error-pages.conf:# L anguagePriority en cs de es fr it nl sv pt-br ro
/etc/apache2/conf-available/localized-error-pages.conf:# F orceLanguagePriority Prefer Fallback
/etc/apache2/conf-available/localized-error-pages.conf:# < /Directory>
/etc/apache2/conf-available/localized-error-pages.conf:# vim: syntax=apache ts=4 sw=4 sts=4 sr noet
/etc/apache2/conf-available/other-vhosts-access-log.conf:# Define an access log for VirtualHosts that don’t define their own logfile
/etc/apache2/conf-available/other-vhosts-access-log.conf:CustomLog ${APACHE_LOG_ DIR}/other_vhosts_access.log vhost_combined
/etc/apache2/conf-available/other-vhosts-access-log.conf:# vim: syntax=apache ts =4 sw=4 sts=4 sr noet
/etc/apache2/conf-available/serve-cgi-bin.conf:
/etc/apache2/conf-available/serve-cgi-bin.conf:
/etc/apache2/conf-available/serve-cgi-bin.conf: Define ENABLE_USR_LIB_CG I_BIN
/etc/apache2/conf-available/serve-cgi-bin.conf:
/etc/apache2/conf-available/serve-cgi-bin.conf: Define ENABLE_USR_LIB_CG I_BIN
/etc/apache2/conf-available/serve-cgi-bin.conf:
/etc/apache2/conf-available/serve-cgi-bin.conf: ScriptAlias /cgi-bin/ /u sr/lib/cgi-bin/
/etc/apache2/conf-available/serve-cgi-bin.conf: <Directory “/usr/lib/cgi -bin”>
/etc/apache2/conf-available/serve-cgi-bin.conf: AllowOverride No ne
/etc/apache2/conf-available/serve-cgi-bin.conf: Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch
/etc/apache2/conf-available/serve-cgi-bin.conf: Require all gran ted
/etc/apache2/conf-available/serve-cgi-bin.conf:
/etc/apache2/conf-available/serve-cgi-bin.conf:
/etc/apache2/conf-available/serve-cgi-bin.conf:# vim: syntax=apache ts=4 sw=4 st s=4 sr noet

and continues:
/etc/apache2/conf-enabled/charset.conf:# Read the documentation before enabling AddDefaultCharset.
/etc/apache2/conf-enabled/charset.conf:# In general, it is only a good idea if y ou know that all your files
/etc/apache2/conf-enabled/charset.conf:# have this encoding. It will override an y encoding given in the files
/etc/apache2/conf-enabled/charset.conf:# in meta http-equiv or xml encoding tags .
/etc/apache2/conf-enabled/charset.conf:# vim: syntax=apache ts=4 sw=4 sts=4 sr n oet
/etc/apache2/conf-enabled/security.conf:# Disable access to the entire file syst em except for the directories that
/etc/apache2/conf-enabled/security.conf:# are explicitly allowed later.
/etc/apache2/conf-enabled/security.conf:# This currently breaks the configuratio ns that come with some web application
/etc/apache2/conf-enabled/security.conf:# Debian packages.
/etc/apache2/conf-enabled/security.conf:#
/etc/apache2/conf-enabled/security.conf:# AllowOverride None
/etc/apache2/conf-enabled/security.conf:# Require all denied
/etc/apache2/conf-enabled/security.conf:#
/etc/apache2/conf-enabled/security.conf:# Changing the following options will no t really affect the security of the
/etc/apache2/conf-enabled/security.conf:# server, but might make attacks slightl y more difficult in some cases.
/etc/apache2/conf-enabled/security.conf:# This directive configures what you ret urn as the Server HTTP response
/etc/apache2/conf-enabled/security.conf:# Header. The default is ‘Full’ which se nds information about the OS-Type
/etc/apache2/conf-enabled/security.conf:# and compiled in modules.
/etc/apache2/conf-enabled/security.conf:# Set to one of: Full | OS | Minimal | Minor | Major | Prod
/etc/apache2/conf-enabled/security.conf:# where Full conveys the most informatio n, and Prod the least.
/etc/apache2/conf-enabled/security.conf:#ServerTokens Minimal
/etc/apache2/conf-enabled/security.conf:# Optionally add a line containing the s erver version and virtual host
/etc/apache2/conf-enabled/security.conf:# name to server-generated pages (intern al error documents, FTP directory
/etc/apache2/conf-enabled/security.conf:# listings, mod_status and mod_info outp ut etc., but not CGI generated
/etc/apache2/conf-enabled/security.conf:# Set to “EMail” to also include a mailt o: link to the ServerAdmin.
/etc/apache2/conf-enabled/security.conf:# Set to one of: On | Off | EMail
/etc/apache2/conf-enabled/security.conf:#ServerSignature Off
/etc/apache2/conf-enabled/security.conf:ServerSignature On
/etc/apache2/conf-enabled/security.conf:# Set to “extended” to also reflect the request body (only for testing and
/etc/apache2/conf-enabled/security.conf:# diagnostic purposes).
/etc/apache2/conf-enabled/security.conf:# Forbid access to version control direc tories
/etc/apache2/conf-enabled/security.conf:# If you use version control systems in your document root, you should
/etc/apache2/conf-enabled/security.conf:# probably deny access to their director ies. For example, for subversion:
/etc/apache2/conf-enabled/security.conf:#<DirectoryMatch “/.svn”>
/etc/apache2/conf-enabled/security.conf:# Require all denied
/etc/apache2/conf-enabled/security.conf:#
/etc/apache2/conf-enabled/security.conf:# Setting this header will prevent MSIE from interpreting files as something
/etc/apache2/conf-enabled/security.conf:# else than declared by the content type in the HTTP headers.
/etc/apache2/conf-enabled/security.conf:# Requires mod_headers to be enabled.
/etc/apache2/conf-enabled/security.conf:#Header set X-Content-Type-Options: “nos niff”
/etc/apache2/conf-enabled/security.conf:# Setting this header will prevent other sites from embedding pages from this
/etc/apache2/conf-enabled/security.conf:# site as frames. This defends against c lickjacking attacks.
/etc/apache2/conf-enabled/security.conf:# Requires mod_headers to be enabled.
/etc/apache2/conf-enabled/security.conf:#Header set X-Frame-Options: "sameorigin "
/etc/apache2/conf-enabled/security.conf:# vim: syntax=apache ts=4 sw=4 sts=4 sr noet
/etc/apache2/conf-enabled/localized-error-pages.conf:# Customizable error respon ses come in three flavors:
/etc/apache2/conf-enabled/localized-error-pages.conf:# 1) plain text
/etc/apache2/conf-enabled/localized-error-pages.conf:# 2) local redirects
/etc/apache2/conf-enabled/localized-error-pages.conf:# 3) external redirects
/etc/apache2/conf-enabled/localized-error-pages.conf:#ErrorDocument 404 /missing .html
/etc/apache2/conf-enabled/localized-error-pages.conf:#ErrorDocument 404 “/cgi-bi n/missing_handler.pl”
/etc/apache2/conf-enabled/localized-error-pages.conf:#ErrorDocument 402 http://w ww.example.com/subscription_info.html
/etc/apache2/conf-enabled/localized-error-pages.conf:# Putting this all together , we can internationalize error responses.
/etc/apache2/conf-enabled/localized-error-pages.conf:# We use Alias to redirect any /error/HTTP_.html.var response to
/etc/apache2/conf-enabled/localized-error-pages.conf:# our collection of by-erro r message multi-language collections. We use
/etc/apache2/conf-enabled/localized-error-pages.conf:# includes to substitute th e appropriate text.
/etc/apache2/conf-enabled/localized-error-pages.conf:# You can modify the messag es’ appearance without changing any of the
/etc/apache2/conf-enabled/localized-error-pages.conf:# default HTTP_.html .var files by adding the line:
/etc/apache2/conf-enabled/localized-error-pages.conf:#Alias /error/include/ “/yo ur/include/path/”
/etc/apache2/conf-enabled/localized-error-pages.conf:# which allows you to creat e your own set of files by starting with the
/etc/apache2/conf-enabled/localized-error-pages.conf:# /usr/share/apache2/error/ include/ files and copying them to /your/include/path/,
/etc/apache2/conf-enabled/localized-error-pages.conf:# even on a per-VirtualHost basis. If you include the Alias in the global server
/etc/apache2/conf-enabled/localized-error-pages.conf:# context, is has to come _ before_ the ‘Alias /error/ …’ line.
/etc/apache2/conf-enabled/localized-error-pages.conf:# The default include files will display your Apache version number and your
/etc/apache2/conf-enabled/localized-error-pages.conf:# ServerAdmin email address regardless of the setting of ServerSignature.
/etc/apache2/conf-enabled/localized-error-pages.conf:# WARNING: The configuratio n below will NOT work out of the box if you have a
/etc/apache2/conf-enabled/localized-error-pages.conf:# SetHandler dir ective in a context somewhere. Adding
/etc/apache2/conf-enabled/localized-error-pages.conf:# the following three lines AFTER the context should
/etc/apache2/conf-enabled/localized-error-pages.conf:# make it work i n most cases:
/etc/apache2/conf-enabled/localized-error-pages.conf:# <Location /err or/>
/etc/apache2/conf-enabled/localized-error-pages.conf:#
/etc/apache2/conf-enabled/localized-error-pages.conf:# The internationalized err or documents require mod_alias, mod_include
/etc/apache2/conf-enabled/localized-error-pages.conf:# and mod_negotiation. To activate them, uncomment the following 37 lines.
/etc/apache2/conf-enabled/localized-error-pages.conf:#
/etc/apache2/conf-enabled/localized-error-pages.conf:#
/etc/apache2/conf-enabled/localized-error-pages.conf:#
/etc/apache2/conf-enabled/localized-error-pages.conf:# Alias /e rror/ “/usr/share/apache2/error/”
/etc/apache2/conf-enabled/localized-error-pages.conf:# <Directo ry “/usr/share/apache2/error”>
/etc/apache2/conf-enabled/localized-error-pages.conf:# O ptions IncludesNoExec
/etc/apache2/conf-enabled/localized-error-pages.conf:# A ddOutputFilter Includes html
/etc/apache2/conf-enabled/localized-error-pages.conf:# L anguagePriority en cs de es fr it nl sv pt-br ro
/etc/apache2/conf-enabled/localized-error-pages.conf:# F orceLanguagePriority Prefer Fallback
/etc/apache2/conf-enabled/localized-error-pages.conf:# </Direct ory>
/etc/apache2/conf-enabled/localized-error-pages.conf:# vim: syntax=apache ts=4 s w=4 sts=4 sr noet
/etc/apache2/conf-enabled/other-vhosts-access-log.conf:# Define an access log fo r VirtualHosts that don’t define their own logfile
/etc/apache2/conf-enabled/other-vhosts-access-log.conf:CustomLog ${APACHE_LOG_DI R}/other_vhosts_access.log vhost_combined
/etc/apache2/conf-enabled/other-vhosts-access-log.conf:# vim: syntax=apache ts=4 sw=4 sts=4 sr noet
/etc/apache2/conf-enabled/serve-cgi-bin.conf:
/etc/apache2/conf-enabled/serve-cgi-bin.conf:
/etc/apache2/conf-enabled/serve-cgi-bin.conf: Define ENABLE_USR_LIB_CG I_BIN
/etc/apache2/conf-enabled/serve-cgi-bin.conf:
/etc/apache2/conf-enabled/serve-cgi-bin.conf: Define ENABLE_USR_LIB_CG I_BIN
/etc/apache2/conf-enabled/serve-cgi-bin.conf:
/etc/apache2/conf-enabled/serve-cgi-bin.conf: ScriptAlias /cgi-bin/ /u sr/lib/cgi-bin/
/etc/apache2/conf-enabled/serve-cgi-bin.conf: <Directory “/usr/lib/cgi -bin”>
/etc/apache2/conf-enabled/serve-cgi-bin.conf: AllowOverride No ne
/etc/apache2/conf-enabled/serve-cgi-bin.conf: Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch
/etc/apache2/conf-enabled/serve-cgi-bin.conf: Require all gran ted
/etc/apache2/conf-enabled/serve-cgi-bin.conf:
/etc/apache2/conf-enabled/serve-cgi-bin.conf:
/etc/apache2/conf-enabled/serve-cgi-bin.conf:# vim: syntax=apache ts=4 sw=4 sts= 4 sr noet

That’s all

So you’re using XAMPP or similar?

If this is not a totally standard Apache installation on Ubuntu, you may need to pass some arguments to Certbot to allow it to understand your environment.

You can see these at

certbot --help apache

Yes. Ok, I guess that’s the problem.

Thanks,

I don’t understand:
“/opt/lampp/bin/”

I’d like to see output from:
netstat -napt | grep LISTEN

and the result of (without --apache):
sudo certbot certonly

In my server, I have a very personalized XAMPP installed in Ubuntu (I didn’t know, that was my fault). So I had running at the same time 2 Apache services (one in /apache and another in /opt/lampp).

I finally solved the issue by getting and installing the certificates and the key manually, and reconfiguring virtualhosts in the Apache service that I was actually using.

Thanks a lot

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.