Installing new domains on a virtual server

Hi, on my virtual server I already had Let’s Encrypt handling the certificate for two of my vhosts. Now, I was adding two new domains to the same hosting account, but got some problemas after calling “certbot --apache” as I did at the first time.

When I ran the command I was presented with a correct list of my currente domains. Then, by choosing the numbers, I selected all the ones I wanted (including the previous ones). After that, it all seemed to be ok, but when I try to access the new ones on my browser (like this one: I get a “ERR_CERT_COMMON_NAME_INVALID” - it seems the certificate in use is still the old one since is is still only valid for the original domains (I checked it).

By calling “certbot certificates” on my server, I can see thath the new and the old certificates are, indeed, still up and running - ther were put on two different directories under the “live” folder of /etc/letsencrypt, so I assumed I have a misconfiguration of my apache server.

How can I tell apache to use the correct certificate? I’m unable to find where I set this configuration…

My domain is:
I ran this command: sudo certbot --apache
My web server is (include version): apache
The operating system my web server runs on is (include version): ubuntu 16.04
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 location of the Apache configuration file. On most systems if you installed Apache with a package manager, or it came preinstalled, the Apache configuration file is located in one of these locations: /etc/apache2/httpd.conf. /etc/apache2/apache2.conf.

You could also use apachectl -S to check all vHosts currently loaded (and overview)..

Thank you

Hi @lucasj

you have one new certificate

with 3 domains and 3 www-subdomains:

But you don't use this certificate, shows the older certificate with


So change your vHosts to use the new certificate.

I think the OP is asking how to edit the vHost (& where is the vHost).....

Yes, that’s the exact problem I noticed… I just don’t kno how to change my vhosts to point to this new certificate on my apache/ubuntu 16.04 setup…

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