BigBlueButton: LetsEncrypt Zertifikat erneuern

Ich habe ein kleines aber kritisches Problem, was in zwei Tagen den BigBlueButton Server lahm legt.

Ich habe BBB mit dem offiziellen Installer Skript installiert und ein Zertifikat über LetsEncrypt bezogen. Siehe hier: BBB und LetsEncrypt. Das Ganze läuft auch schon seit 88 Tagen wunderbar. Jetzt wird aber das Zertifikat ablaufen denn der cronjob mit

/usr/bin/certbot renew 

versagt mit der Fehlermeldung:

Saving debug log to /var/log/letsencrypt/letsencrypt.log

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Processing /etc/letsencrypt/renewal/konferenz.lernplattform-nordeifel.de.conf
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Cert is due for renewal, auto-renewing...
Plugins selected: Authenticator webroot, Installer None
Starting new HTTPS connection (1): acme-v02.api.letsencrypt.org
Renewing an existing certificate
Performing the following challenges:
http-01 challenge for konferenz.lernplattform-nordeifel.de
Waiting for verification...
Cleaning up challenges
Attempting to renew cert (konferenz.lernplattform-nordeifel.de) from /etc/letsencrypt/renewal/konferenz.lernplattform-nordeifel.de.conf produced an unexpected error: Failed authorization procedure. konferenz.lernplattform-nordeifel.de (http-01): urn:ietf:params:acme:error:unauthorized :: The client lacks sufficient authorization :: Invalid response from http://konferenz.lernplattform-nordeifel.de/.well-known/acme-challenge/174t9-3o-yz9_WBhhkjsvL29etjukOxkmNY3Yhq6DD8 [93.90.195.83]: "<html>\r\n<head><title>404 Not Found</title></head>\r\n<body bgcolor=\"white\">\r\n<center><h1>404 Not Found</h1></center>\r\n<hr><center>". Skipping.
All renewal attempts failed. The following certs could not be renewed:
  /etc/letsencrypt/live/konferenz.lernplattform-nordeifel.de/fullchain.pem (failure)

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

All renewal attempts failed. The following certs could not be renewed:
  /etc/letsencrypt/live/konferenz.lernplattform-nordeifel.de/fullchain.pem (failure)
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
1 renew failure(s), 0 parse failure(s)

IMPORTANT NOTES:
 - The following errors were reported by the server:

   Domain: konferenz.lernplattform-nordeifel.de
   Type:   unauthorized
   Detail: Invalid response from
   http://konferenz.lernplattform-nordeifel.de/.well-known/acme-challenge/174t9-3o-yz9_WBhhkjsvL29etjukOxkmNY3Yhq6DD8
   [93.90.195.83]: "<html>\r\n<head><title>404 Not
   Found</title></head>\r\n<body bgcolor=\"white\">\r\n<center><h1>404
   Not Found</h1></center>\r\n<hr><center>"

   To fix these errors, please make sure that your domain name was
   entered correctly and the DNS A/AAAA record(s) for that domain
   contain(s) the right IP address.

Was kann ich tun?

Der Web-Server auf dem BBB-Server nimmt die Antwort von letsencrypt nicht entgegen. Mit

certbot renew --standalone

sollte es klappen. Die Option --standalone macht temporär einen Web-Server auf, der auf Port 80 lauscht.

Am besten testest Du erstmal mit

certbot renew --standalone --dry-run

bevor Du das echte Zertifikat erneuerst.

1 „Gefällt mir“

Ich denke schon, dass der Webserver läuft, denn

http://konferenz.lernplattform-nordeifel.de/

liefert eine Testseite des nginx

und, wenn ich

sudo certbot renew --standalone --dry-run

starte, erhalte ich die Fehlermeldung:

Saving debug log to /var/log/letsencrypt/letsencrypt.log

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Processing /etc/letsencrypt/renewal/konferenz.lernplattform-nordeifel.de.conf
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Cert is due for renewal, auto-renewing...
Plugins selected: Authenticator standalone, Installer None
Starting new HTTPS connection (1): acme-staging-v02.api.letsencrypt.org
Renewing an existing certificate
Performing the following challenges:
http-01 challenge for konferenz.lernplattform-nordeifel.de
Cleaning up challenges
Attempting to renew cert (konferenz.lernplattform-nordeifel.de) from /etc/letsencrypt/renewal/konferenz.lernplattform-nordeifel.de.conf produced an unexpected error: Problem binding to port 80: Could not bind to IPv4 or IPv6.. Skipping.
All renewal attempts failed. The following certs could not be renewed:
  /etc/letsencrypt/live/konferenz.lernplattform-nordeifel.de/fullchain.pem (failure)

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
** DRY RUN: simulating 'certbot renew' close to cert expiry
**          (The test certificates below have not been saved.)

All renewal attempts failed. The following certs could not be renewed:
  /etc/letsencrypt/live/konferenz.lernplattform-nordeifel.de/fullchain.pem (failure)
** DRY RUN: simulating 'certbot renew' close to cert expiry
**          (The test certificates above have not been saved.)
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
1 renew failure(s), 0 parse failure(s)

IMPORTANT NOTES:
 - Your account credentials have been saved in your Certbot
   configuration directory at /etc/letsencrypt. You should make a
   secure backup of this folder now. This configuration directory will
   also contain certificates and private keys obtained by Certbot so
   making regular backups of this folder is ideal.

Ich habe nun mal nginx gestoppt und dann das

sudo certbot renew --standalone --dry-run

gestartet und es läuft ohne Fehler:

Saving debug log to /var/log/letsencrypt/letsencrypt.log

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Processing /etc/letsencrypt/renewal/konferenz.lernplattform-nordeifel.de.conf
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Cert is due for renewal, auto-renewing...
Plugins selected: Authenticator standalone, Installer None
Starting new HTTPS connection (1): acme-staging-v02.api.letsencrypt.org
Renewing an existing certificate
Performing the following challenges:
http-01 challenge for konferenz.lernplattform-nordeifel.de
Waiting for verification...
Cleaning up challenges

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
new certificate deployed without reload, fullchain is
/etc/letsencrypt/live/konferenz.lernplattform-nordeifel.de/fullchain.pem
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
** DRY RUN: simulating 'certbot renew' close to cert expiry
**          (The test certificates below have not been saved.)

Congratulations, all renewals succeeded. The following certs have been renewed:
  /etc/letsencrypt/live/konferenz.lernplattform-nordeifel.de/fullchain.pem (success)
** DRY RUN: simulating 'certbot renew' close to cert expiry
**          (The test certificates above have not been saved.)
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

Ermutigt davon versuche ich das Ganze ohne dryrun

sudo certbot renew --standalone

Und erhalte den nächsten Fehler:

Saving debug log to /var/log/letsencrypt/letsencrypt.log

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Processing /etc/letsencrypt/renewal/konferenz.lernplattform-nordeifel.de.conf
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Cert is due for renewal, auto-renewing...
Plugins selected: Authenticator standalone, Installer None
Starting new HTTPS connection (1): acme-v02.api.letsencrypt.org
Renewing an existing certificate
Performing the following challenges:
http-01 challenge for konferenz.lernplattform-nordeifel.de
Waiting for verification...
Cleaning up challenges
Attempting to renew cert (konferenz.lernplattform-nordeifel.de) from /etc/letsencrypt/renewal/konferenz.lernplattform-nordeifel.de.conf produced an unexpected error: urn:ietf:params:acme:error:serverInternal :: The server experienced an internal error :: Failed to retrieve order for ID 4616574406. Skipping.
All renewal attempts failed. The following certs could not be renewed:
  /etc/letsencrypt/live/konferenz.lernplattform-nordeifel.de/fullchain.pem (failure)

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

All renewal attempts failed. The following certs could not be renewed:
  /etc/letsencrypt/live/konferenz.lernplattform-nordeifel.de/fullchain.pem (failure)
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
1 renew failure(s), 0 parse failure(s)

Wenn Dein nginx auch auf Port 80 (und nicht nur auf Port 443) lauscht, was offensichtlich der Fall ist, dann musst Du den vorher natürlich stoppen, genau so, wie Du es gemacht hast.

Den Fall, dass der Dry-Run durchläuft und der rechte Run nicht, hatte ich noch nie. Und das bei einer ganzen Reihe von verschiedenen Domains. Woher der interne Server-Fehler rührt, erschließt sich mir daher leider nicht.

Es könnte allenfalls sein, dass Du es kürzlich schon zu oft ohne --dry-run probiert hast. Bei letsencrypt ist nur eine bestimmte Anfragerate zulässig. Bei fehlgeschlagener Validierung sind dies 5 Fehler pro Account pro Hostname pro Stunde (siehe https://letsencrypt.org/de/docs/rate-limits/).

Die Standalonevariante hat jetzt scheinbar funktioniert. Ich habe in der Domainverwaltung den AAAA Record eliminiert.

Dennoch seltsam, dass ich diesen Umweg gehen muss… Mit dem Workaround kann ich leben, ich bastel mir ein Script, dass den nginx stoppt, den certbot startet und anschließend den nginx wieder startet.

Vielen Dank für den Input.

Auf meinem BBB-Server habe ich es auch nur in der Standalone-Variante hinbekommen. Ich habe mich auch gegen weitere Recherchen und für den Workaround entschieden.

1 „Gefällt mir“

Hallo Heiko,

ich mache das über diese Webseite

https://www.sslforfree.com/

händisch.

Gruß

Alois

Das sieht gut aus, da sich aber bei mir die BBB installation wie ein Eiertanz aufgeführt hat, bin ich froh, dass es mit LetsEncrypt läuft :slight_smile: