[SOLVED] Error add txt for domain failed: exit code 1

Aug 29, 2018
4
2
8
28
Hi, I hope everything is okay.

I have recently upgraded my PVE to 6.2-4 to use DNS based challenge but can't get it to work.

I've tried filling almost every combination of fields, even filing them all doesn't work.

"Either provide global account key and email, or CF API token and Account ID."

CF_Email= xxxxxxxxxx
CF_Key= xxxxxxxxxxx
CF_Zone_ID= xxxxxxxxx

It doesn't work.

CF_Account_ID= xxxxxx
CF_Token= xxxxxx
CF_Zone_ID= xxxxxxxxx

It doesn't work.

CF_Account_ID= xxxxxx
CF_Email= xxxxxxxxxx
CF_Key= xxxxxxxxxxx
CF_Token= xxxxxxx
CF_Zone_ID= xxxxxxxxx

It doesn't work.

I have a pfSense doing the same thing and its working, so I guess it's not on the Cloudflare side.



Can't figure why, journalctl -xe only gives me the same PvE output shows: exit code 1.

I've also tried to run the command manually, but it doesn't return anything.

I've tried both live and stage lets encrypt as well.



Loading ACME account details
Placing ACME order
Order URL: https://acme-staging-v02.api.letsencrypt.org/acme/order/136xxx13/92xxx379

Getting authorization details from 'https://acme-staging-v02.api.letsencrypt.org/acme/authz-v3/563xxx69'
The validation for pve01.mydomain.com.br is pending!
[Wed May 13 12:23:55 -03 2020] Error
[Wed May 13 12:23:55 -03 2020] Error add txt for domain:_acme-challenge.pve01.mydomain.com.br

TASK ERROR: command 'setpriv --reuid nobody --regid nogroup --clear-groups --reset-env -- /bin/bash /usr/share/proxmox-acme/proxmox-acme setup cf pve01.mydomain.com.br' failed: exit code 1
 
It's an upstream problem with acme.sh and Cloudflare (https://github.com/acmesh-official/acme.sh/issues/2888). It has been fixed in the latest version of the dns_cf.sh file.

I replaced the one here /usr/share/proxmox-acme/dnsapi/, and now it works for me.

It's a quick fix, until Proxmox updates their libproxmox-acme-perl package with the latest dns files.

Total life savior!

Work like a charm!

Problem solved. Maybe I will open an issue on PVE to remember to update this script or do you think it's unnecessary?

Bash:
cd /usr/share/proxmox-acme/dnsapi/
mv dns_cf.sh dns_cf.sh.bkp
wget https://raw.githubusercontent.com/acmesh-official/acme.sh/master/dnsapi/dns_cf.sh
 
  • Like
Reactions: rtfm98 and Janko
Hi,
I just encountered a similar problem with dns_loopia.sh from acme.sh/dnsapi which was updated in the last 6 months or so after an API change at Loopia. What do we have to do to get Proxmox to do a refresh from upstream?
please open a bug report: https://bugzilla.proxmox.com/ Like that, all developers should see the issue. Forum posts are rather easily missed.

EDIT: FYI, libproxmox-acme-perl=1.4.3 is now available on the pvetest repository. It contains an update to acme.sh v3.0.5. To get it you can:
1. Configure the test repostiory (can also be done via UI).
2. Run apt update && apt install libproxmox-acme-perl
3. Remove/disable the test repository again.
4. Run apt update again.
 
Last edited:

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!