Cloud DNS: Route 53 - "Failed to save DNS options : DNS zone not found!"

SYSTEM INFORMATION
OS type and version Ubuntu 20.04.6 LTS
Virtualmin version 7.7

I created a virtual server for my domain (Let’s call it domain.com), and when I go to “Virtualmin->Server Config->DNS Options” and try to publish spf records and what not, I get

Failed to save DNS options : DNS zone not found!

When I go to “DNS Records” I get:

An error occurred (NoSuchHostedZone) when calling the ListResourceRecordSets operation: No hosted zone found with ID: Failed to create records

I’m using Cloud DNS → Route 53. It’s configured properly, other domains are working properly - I can view and publish new DNS records to these domains just fine. The records for domain.com exist in Route 53. I DID manually create a few records (Such as the hostname, which I’ll call sub.domain.com).

I just deleted the zone in Route 53 and recreated the virtual server and get this message while it’s creating:

Adding new DNS zone using Amazon Route 53 …
… done, but some records were not created :

Then I try the DNS Options and DNS Records again and get the same errors.

@Jamie, do you have a clue what could be causing it?

Did you perhaps change your AWS account or default region between when you created that zone and now?

Nope I didn’t change the default region or AWS account, I even tried recreating the virtual server in Virtualmin and it gives me the error “… done, but some records were not created”

Are there logs somewhere I can send to you? Or just look at myself to try to get more a more detailed error message. The creation of the zone in Route 53 is a bit odd and I’d hope aws-cli would give more information (If that’s where the issue is at least)

Sorry for so many replies, but I’ve made progress by going into /etc/webmin/virtual-server and looking at the ‘domains=’ IDs, then taking that ID and opening up /etc/webmin/virtual-server/domains/############ for that domain and changing “dns_cloud_id=but some records were not created :” to “dns_cloud_id=AWSROUTE53HOSTEDZONEID” and now it works.

This seems like a bug, I’d be happy to provide log files and whatnot to figure out why this is happening.

Hmm, seems like the domain wasn’t created properly and so the dns_cloud_id wasn’t saved.

How did you create this domain exactly? Via the Virtualmin UI, command line API, or something else?

Also, if you create a new test domain where DNS is hosted on Route53, does it work OK?

I created it via the Virtualmin UI, and yeah I’ve created domains after the problem one and they all work fine. If it matters, the tld is “.space”.

If it matters - I use “sub.domain.space” as my hostname which I set before I created the domain.

I don’t think the TLD is the cause of the issue. More likely the creation of the domain partially failed, but it’s hard to say for sure unless you saved the output shown in the UI when you created it.

When I get a chance after work I’ll delete and re-create it. I’ve deleted and re-created it several times so far and every time I get that issue/error, so it should pop up again. What exactly do you need? Just the output the Virtualmin UI shows when creating a virtual server?

Yes, that would be really useful!

Sorry I forgot yesterday! Here’s the Virtualmin web output when creating the virtual server… It’s not super detailed but:

Creating administration group domainspace …
… done

Creating administration user domainspace …
… done

Creating aliases for administration user …
… done

Adding administration user to groups …
… done

Creating home directory …
… done

Creating mailbox for administration user …
… done

Adding new DNS zone using Amazon Route 53 …
… done, but some records were not created :

Adding to email domains list …
… done

Adding default mail aliases …
… done

Adding new virtual website …
… done

Starting FCGIwrap server …
… done

Adding webserver user www-data to server’s group …
… done

Performing other Apache configuration …
… done

Creating SSL certificate and private key …
… done

Adding new SSL virtual website …
… done

Setting up log file rotation …
… done

Creating MariaDB login …
… done

Creating MariaDB database domainspace …
… done

Setting up spam filtering …
… done

Setting up virus filtering …
… done

Creating Webmin user …
… done

Saving server details …
… done

Applying web server configuration …
… done

Re-loading Webmin …
… done

Re-starting Usermin …
… done

Restarting mail server …
… done

Updating Webmin user …
… done

Requesting a certificate for domain.space from Let’s Encrypt …
… request failed : Web-based validation failed :

Saving debug log to /var/log/letsencrypt/letsencrypt.log
Plugins selected: Authenticator webroot, Installer None
Renewing an existing certificate
Reusing existing private key from /etc/letsencrypt/live/domain.space/privkey.pem.
An unexpected error occurred:
Certification Authority Authorization (CAA) records forbid the CA from issuing a certificate :: Error finalizing order :: While processing CAA for domain.space: DNS problem: SERVFAIL looking up CAA for domain.space - the domain’s nameservers may be malfunctioning
Please see the logfiles in /var/log/letsencrypt for more details.

DNS-based validation failed :

Saving debug log to /var/log/letsencrypt/letsencrypt.log
Plugins selected: Authenticator manual, Installer None
Renewing an existing certificate
Reusing existing private key from /etc/letsencrypt/live/domain.space/privkey.pem.
An unexpected error occurred:
Certification Authority Authorization (CAA) records forbid the CA from issuing a certificate :: Error finalizing order :: While processing CAA for domain.space: DNS problem: SERVFAIL looking up CAA for domain.space - the domain’s nameservers may be malfunctioning
Please see the logfiles in /var/log/letsencrypt for more details.

Creating initial website index page …
… done

Re-loading Webmin …
… done

Ok, thanks - that was useful! I see the bug, and it will be fixed in the next Virtualmin release.

1 Like

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