Error when creating new certificates using Cloudflare DNS

Hi,
I have this error when I try to update a certificate, even though there isn't a TXT record on Cloudflare that starts with _acme-challenge. Can you help me?
Thanks


My domain is: maicol07.it

I ran this command:

 sudo certbot certonly --cert-name maicol07.it-0001 -d maicol07.it,amministrazione.battistini-impianti.it,battistini-impianti.it,account.maicol0
7.it,blog.maicol07.it,community.maicol07.it,docs.maicol07.it,flarum.maicol07.it,ha.maicol07.it,lv.maicol07.it,packages.maicol07.it,pm.maicol07.it,share
.maicol07.it,statamic.blog.maicol07.it,tracker.maicol07.it,srv.maicol07.it --dns-cloudflare --dns-cloudflare-credentials ~/.secrets/certbot/cloudflare.ini

It produced this output:

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

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
You are updating certificate maicol07.it-0001 to include new domain(s):
+ account.maicol07.it
+ srv.maicol07.it

You are also removing previously included domain(s):
- bd.account.maicol07.it
- translate.maicol07.it

Did you intend to make this change?
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
(U)pdate certificate/(C)ancel: u
Renewing an existing certificate for maicol07.it and 15 more domains
Encountered CloudFlareAPIError adding TXT record: 81057 Record already exists.
Error communicating with the Cloudflare API: Record already exists.
Ask for help or search for solutions at https://community.letsencrypt.org. See the logfile /var/log/letsencrypt/letsencrypt.log or re-run Certbot with -v for more details.

My web server is (include version): OpenLiteSpeed 1.7.20

The operating system my web server runs on is (include version): Ubuntu 20.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 version of my client is (e.g. output of certbot --version or certbot-auto --version if you're using Certbot): 1.18.0

I've tried running two commands without the last added domain and it worked. I've done the same thing adding the one I removed earlier and it worked... Didn't know then what caused the error...

I'm glad to see you got it to work.

This really should just never happen, but I suspect there are a couple of uncommon circumstances where it might. I opened a bug to track this (dns-cloudflare should guard against creating duplicate TXT records · Issue #8994 · certbot/certbot · GitHub), in case it ever bothers more people.

Since, you are authenticating via DNS-01:

You might be a good candidate for using a wildcard cert.
One wildcard cert entry could cover all these thirteen names:

account.maicol07.it | blog.maicol07.it | community.maicol07.it
docs.maicol07.it | flarum.maicol07.it | ha.maicol07.it | lv.maicol07.it
packages.maicol07.it | pm.maicol07.it | share.maicol07.it
statamic.blog.maicol07.it | tracker.maicol07.it | srv.maicol07.it

[which would also speed up the renewal process by twelve TXT records]

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