How To Fix ‘Caught exception in method AmazonAI_Cloudformation::get_dv_dns_info in class AmazonAI_Cloudformation:’

Table of Contents

Did you encounter this annoying error while setting up your new website? This error is seen in the AWSforWordpress plugin setup.

AWS has a good development team on its side. And they did a very good job in developing plugins that help WordPress users to move to Amazon and use its features.

If you don’t know about Amazon Lightsail, it’s a virtual private server offered by Amazon at affordable prices. Their prices start very small from $3.50 per month with 1 static IP, 512MB memory, and 1 core processor.


Being a vivid user of Amazon’s EC2 servers for years now, I was a little hesitant to use this new service from the AWS team. I was sure that they will do it well but still, I was not sure of how good their documentations are for this new service.

Finally last month I gave Lightsail a chance as this product got pretty matured and I gave a brief look into their documentation before jumping in.

Started with the smallest virtual server of 512MB RAM for a small site of mine where we do a lot of SEO tests before implementing any new strategy for our UnderWP’s digital marketing clients.

The whole setup went pretty smooth about which I might write up soon in another post. But there was this one point where I got stuck with a nasty error.

The Problem

I found this error when creating a new CloudFront distribution for the website on Amazon Lightsail.


The DNS was being handled by Cloudflare. Unfortunately, AWS documentation does not cover how to handle the DNS when managed by Cloudflare.

They are more in favor of their own DNS management module, Amazon Route 53. It is a wonderful tool to handle all your DNS queries. But personally, I am more in favor of Cloudflare when it comes to DNS.

After going through their documentation for over 2 days here: no help was found.

To solve this error, I found the problem was not in the plugin. Because I also read through their plugin which is open source and available on Github for everyone to read:

This is when I realize that maybe the problem was in Cloudflare.

The Solution

This error can be solved like this. Go to your Cloudflare account and into the DNS management of the you are configuring.

When you are adding the CNAME values provided by the AWSforWordPress plugin. Make sure to switch off the Proxy status option in your Cloudflare dashboard.


Once this was done, click on the Check status of Cloudfront certificate button on your WordPress dashboard. After a few seconds, you will see that the plugin was successfully able to verify the certificate and goes to the next step of CloudFront Distribution Deployment.

Final Words

This post is to address this error for anyone who faces this error when handling Amazon Lightsail services. If only this error would have been covered in their documentation, I wouldn’t have had to write about it.

Overall setting up the Lightsail server for a website has been made an effortless work compared to setting up on EC2 servers by the AWS team. Only this small issue happened when trying to get their additional Cloudfron services to activate on the new website. Hopefully, this will also be addressed and patched up by their team in the future.

Let me know in the comments if this has helped you.

Share This Article:
Related Articles:
Find The Cheapest Domain Registration For Your Next Domain

Domain registrars are organizations that administer and register domain names for international websites. The value of choosing the right domain cannot be overstated, as it can deceive a consumer in a variety of ways. You may also use it to register and buy a domain name. Many of these registrars

Read More »
restore wordpress backup
How To Restore WordPress From Backup

The internet is full of hackers and vulnerabilities. Creating backups and restoring the WordPress website is an important step that every webmaster should follow. There might be situations when you need to restore your WordPress website with the backups you created the last time. We wrote this guide as a

Read More »
Subscribe to our newsletter
Chat With Our SEO community members On discord

5 Responses

  1. Setting up cloudfront is always a pain on WordPress due to the lack of good plugins. But with this plugin from AWS itself, it has become easy.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses User Verification plugin to reduce spam. See how your comment data is processed.

This site uses Akismet to reduce spam. Learn how your comment data is processed.

%d bloggers like this: