Common Certbot Commands

Certbot is a simple way to manage your letsencrypt certificates on a webserver.

This is a list of common certbot commands that we use regularily

List the Certificates installed on a server

sudo certbot certificates

Renew Certificates

Renew all certificates

sudo certbot renew

Force Renew a certificate


certbot certonly --force-renew -d example.com

Delete a Certificate

sudo certbot delete --cert-name example.com

Install a New Certificate

To install a Let’s Encrypt SSL certificate on your domain, execute the following command (make sure you replace ‘yourdomain.com’ with your actual domain name):

certbot --apache -d yourdomain.com

or

certbot --apache -d yourdomain.com -d www.yourdomain.com

Note: for nginx server replace --apache with --nginx


Automatic renewal You can also create a cron job in order to set up an automatic SSL renewal. To do this first run:

crontab -e and then add the following:

0 0 1 /usr/bin/letsencrypt renew >> /var/log/letsencrypt-renew.log

Save the file and close it. Restart the cron service so the changes can take effect:

service cron restart

That’s it. You can now open https://yourdomain.com in your browser and verify whether the Let’s Encrypt SSL certificate has been installed properly.

Of course, you don’t have to install Let’s Encrypt SSL Certificate using Certbot if you use one of our Linux Server Support Services in which case you can simply ask our expert Linux admins to install Let’s Encrypt using Certbot for you. They are available 24×7 and will take care of your request immediately.

Clustered Networks

Located in Edmonton, AB Canada, Clustered Networks was Incorporated in 2001 and has offered Network / Internet and IT Consulting services for over 20 years. We offer personalized service! Call Us Today! - Click Here for our Contact Info

Posted in Linux Network Admin Tips, Network Security Tips, Tech How To on Mar 05, 2021