My domain is: *.eumnestes.org
I ran this command: sudo certbot renew
It produced this output:
$ sudo certbot renew
Saving debug log to /var/log/letsencrypt/letsencrypt.log
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Processing /etc/letsencrypt/renewal/eumnestes.org.conf
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Cert is due for renewal, auto-renewing...
ssl_module is statically linked but --apache-bin is missing; not disabling session tickets.
Plugins selected: Authenticator apache, Installer apache
Renewing an existing certificate for eumnestes.org and 4 more domains
Performing the following challenges:
http-01 challenge for wordhoard.eumnestes.org
http-01 challenge for www.eumnestes.org
http-01 challenge for annocast.eumnestes.org
http-01 challenge for annolex.eumnestes.org
http-01 challenge for eumnestes.org
Cleaning up challenges
Failed to renew certificate eumnestes.org with error: Unable to find a virtual host listening on port 80 which is currently needed for Certbot to prove to the CA that you control your domain. Please add a virtual host for port 80.
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
All renewals failed. The following certificates could not be renewed:
/etc/letsencrypt/live/eumnestes.org/fullchain.pem (failure)
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
1 renew failure(s), 0 parse failure(s)
My web server is (include version):
$ httpd -v
Server version: Apache/2.4.46 (Unix)
Server built: Feb 28 2021 04:17:49
Note that this is the Apple-supplied Apache, not Homebrew, etc.
The operating system my web server runs on is (include version):
$ sw_vers
ProductName: macOS
ProductVersion: 11.3.1
BuildVersion: 20E241
$ uname -m
arm64
My hosting provider, if applicable, is: none
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
The version of my client is (e.g. output of certbot --version
or certbot-auto --version
if you're using Certbot):
$ certbot --version
certbot 1.14.0
Contrary to what certbot thinks, there are virtual hosts listening on port 80:
$ sudo apachectl -S
VirtualHost configuration:
*:80 is a NameVirtualHost
default server annocast.eumnestes.org (/private/etc/apache2/extra/httpd-vhosts.conf:25)
port 80 namevhost annocast.eumnestes.org (/private/etc/apache2/extra/httpd-vhosts.conf:25)
port 80 namevhost annolex.eumnestes.org (/private/etc/apache2/extra/httpd-vhosts.conf:44)
port 80 namevhost wordhoard.eumnestes.org (/private/etc/apache2/extra/httpd-vhosts.conf:75)
port 80 namevhost www.eumnestes.org (/private/etc/apache2/extra/httpd-vhosts.conf:89)
alias eumnestes.org
wild alias *.eumnestes.org
*:443 is a NameVirtualHost
default server wordhoard.eumnestes.org (/private/etc/apache2/extra/httpd-vhosts-le-ssl.conf:3)
port 443 namevhost wordhoard.eumnestes.org (/private/etc/apache2/extra/httpd-vhosts-le-ssl.conf:3)
port 443 namevhost www.eumnestes.org (/private/etc/apache2/extra/httpd-vhosts-le-ssl.conf:21)
alias eumnestes.org
alias www.eumnestes.org
ServerRoot: "/usr"
Main DocumentRoot: "/Library/WebServer/Documents"
Main ErrorLog: "/private/var/log/apache2/error_log"
Mutex authdigest-opaque: using_defaults
Mutex proxy-balancer-shm: using_defaults
Mutex rewrite-map: using_defaults
Mutex ssl-stapling-refresh: using_defaults
Mutex authdigest-client: using_defaults
Mutex ssl-stapling: using_defaults
Mutex proxy: using_defaults
Mutex ssl-cache: using_defaults
Mutex default: dir="/private/var/run/" mechanism=default
Mutex mpm-accept: using_defaults
PidFile: "/private/var/run/httpd.pid"
Define: DUMP_VHOSTS
Define: DUMP_RUN_CFG
User: name="_www" id=70
Group: name="_www" id=70
The Apache access log shows that nothing gets as far as requesting a file from .well-known/acme-challenge (but it's got plenty of other successful requests in it). The web sites are working fine, and everything checks out at letsdebug.net, but I just can't renew the cert.
The problem started when I migrated this set-up from an Intel Mac running Mojave to an M1 Mac running Big Sur. Everything under /etc/letsencrypt and the Apache configuration came over without any problems and, as I mentioned, are working fine except for the certificate renewal. I keep thinking I must've mangled something in the migration but I don't know what.
I put a debug statement in _relevant_vhosts in certbot/certbot-apache/certbot_apache/_internal/http_01.py and determined that the following line:
for vhost in self.configurator.vhosts:
does not find anything in self.configurator.vhosts so the loop never iterates, but I have not yet figured out where or how that list of vhosts should be getting populated.
Sorry to go on, but I thought I should get everything on the table. The warning "ssl_module is statically linked" some lines up from the error in the renewal does not seem right to me. As far as I can see, it is actually a dynamic library:
$ ls -l /usr/libexec/apache2/mod_ssl.so
-rwxr-xr-x 1 root wheel 728080 Jan 1 2020 /usr/libexec/apache2/mod_ssl.so
$ grep mod_ssl.so /etc/apache2/httpd.conf
LoadModule ssl_module libexec/apache2/mod_ssl.so
So there may be something about rooting around in the binary for the OpenSSL version that does not work with ARM binaries. Or not -- just a guess, and this warning may or may not have anything to do with the failure to locate any virtual hosts.
Thanks for reading this far, if you have :-).