How to renew Let's Encrypt SSL Certificate

Please fill out the fields below so we can help you better. Note: you must provide your domain name to get help. Domain names for issued certificates are all made public in Certificate Transparency logs (e.g. https://crt.sh/?q=example.com), so withholding your domain name here does not increase secrecy, but only makes it harder for us to provide help.

My domain is: www.vilaverdeagroecologico.com

I ran this command: sudo apt-get update
sudo apt-get install software-properties-common
sudo add-apt-repository universe
sudo add-apt-repository ppa:certbot/certbot
sudo apt-get update

in all well-succeeded

After that

Install Certbot

sudo apt-get install certbot python-certbot-apache

so far all right!

Run this command to get a certificate and have Certbot edit your Apache configuration automatically to serve it, turning on HTTPS access in a single step.

sudo certbot --apache

Below, i fought the first problem…

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, u
sing 127.0.0.1. Set the ‘ServerName’ directive globally 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

So I’ve tried

$ sudo killall httpd

httpd: no process found

After that

$ sudo apachectl start

AH00558: apache2: Could not reliably determine the server’s fully qualified domain name, u
sing 127.0.0.1. Set the ‘ServerName’ directive globally 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
Action ‘start’ failed.
The Apache error log may have more information.

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.

It produced this output:

My web server is (include version): apache

The operating system my web server runs on is (include version): Apache on Ubuntu 16.04 (xenial)

My hosting provider, if applicable, is: AWS

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): Yes

The version of my client is (e.g. output of certbot --version or certbot-auto --version if you’re using Certbot): Yes

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.

sudo certbot --apache2
usage:
certbot [SUBCOMMAND] [options] [-d DOMAIN] [-d DOMAIN] …

Certbot can obtain and install HTTPS/TLS/SSL certificates. By default,
it will attempt to use a webserver both for obtaining and installing the
certificate.

So, till now my mind is up to blow

What’s my next steps?

Best regards!

1 Like

Please show output of:
sudo netstat -pant | grep -i listen

1 Like

This happens when something else is listening on port 80. Run @rg305’s command to see what.


I suspect you may be running a bitnami image (check with ls /opt), in that case, you need to revert the changes you made (sudo apt-get install ppa-purge && sudo ppa-purge ppa:certbot/certbot && sudo apt-mark auto software-properties-common certbot python-certbot-apache ppa-purge && sudo apt-get autoremove && sudo add-apt-repository -r universe && sudo apt-get update) and then follow their documentation: Auto-configure a Let’s Encrypt certificate

1 Like

Hi,

This path went to nowhere.

This path has gone nowhere. But, as 9peppe said, the certificate was generated by the bitnami image.
So, I followed these steps and did exactly bitnami instructions, but despite having problems, because the directory installed first was different, so I changed the path through Editor VI, redid the commands and everything went well.

Thank you very much

2 Likes

HI,

I did it according to the instructions and finally I left the following script for automatic renewal.
sudo cat renovacertificado.sh

Remembering that I’m in Brazil

Thanks for all.

1 Like

I am not clear on what’s in renovacertificado.sh

The long command I wrote only needs to be run once.

1 Like

This is the final command i wrote to renew automatic certificate

1 Like

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