I have a domain phreak.co.uk which I migrated to Cloudflare a while ago. Just found that certbot didn't auto renew it because I'd made a mistake in the zone file import with CF. So I fixed that and ran:
In the future, use certbot renew to renew existing certificates.
Also, use certbot certificates to see an overview of the certificates currently known to Certbot.
Also also, please update your Certbot version. I'm guessing you're running an ancient version, as it was more common to have these -000x lineages with old versions of Certbot. More recent versions have better certificate detection code to try to prevent these things.
No, it's almost never necessary or useful to use --force-renewal. Including in your case.
Thanks - so (and assuming from now on certbot renew will only use the -0001 version) the only thing I can do is change the apache config to have the -0001 cert?
What do I do with the original one now, delete it?
BTW I think I'm stuck with the version of certbot I have with the Ubuntu snap.
Not necessarily. I suspect there is a difference in hostnames included in the two certificates, which was the reason why Certbot made the -0001 version in the first place. I would recommend to check certbot certificates to notice these differences and determine with which certificate you want to continue.
Certbot installed using snap should automatically update. Can you provide the version by running certbot --version?
Also, please post the output of certbot certificates so we can also look at your Certbot certificates.
You probably are, 3.0.1 is the latest version of Certbot. So it surprises me it would generate that new -0001 lineage Not sure why it did
Do you want to keep using the certificate with the name www.phreak.co.uk, which seems to also include mta-sts.phreak.co.uk and phreak.co.uk?
If so, you should simply be able to run certbot renew, the recommended renewal command. If the certificate named www.phreak.co.uk indeed renews properly and you have not started using the certificate www.phreak.co.uk-0001, you could simply delete the latter.
You mean when you connect to your website from the global internet (i.e., not from within your own network)?
Cloudflare, for proxied sites, manages and issues their own certificates from a range of CAs. This could be Let's Encrypt, or in your case, Google Trust Services.
You need to pay Cloudflare lots of money if you wish to install your own certificate on their edge servers, but why would you?
Or, if you mean, why doesn't Cloudflare internally (from Cloudflare to your server) doesn't pick up your renewed certificate: depending on how you issued and installed the certificate the first place (did you also use certonly without an installer?), you simply might need to reload your Apache. Usually, if one did not use an installer (e.g. using --apache), one uses --deploy-hook with the appropriate reload command. You can add one using certbot reconfigure to any existing certificate. See User Guide — Certbot 3.0.1 documentation for more information.