Certbot - Subdomain and domain.tld pointing to different servers - challenges not passing

Please fill out the fields below so we can help you better.

My domain is: thekosmix.com

I ran this command: sudo certbot --apache -d www.thekosmix.com

It produced this output: Failed to connect to 52.77.98.146:443 for tls-sni-01

My web server is (include version): Server version: Apache/2.4.7 (Ubuntu)

The operating system my web server runs on is (include version): Ubuntu 14.04.1 LTS (GNU/Linux 3.13.0-44-generic x86_64)

My hosting provider, if applicable, is: AWS

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

I used the above command and it gave me the above error. My domain was resolving to this IP previously, but now it has been changed to 35.154.107.12. What can I do to install the https certificate?
PS: I was able to install SSL certificate for my 2 other domains on the same host, but getting problem with this domain.

Hi @thekosmix,

It looks like you forgot to change the DNS record for www.thekosmix.com, which is a different record from thekosmix.com. thekosmix.com points at 35.154.107.12, but www.thekosmix.com points at 52.77.98.146. If you change both, it should work for you.

hey, thanks a ton. I’ve configured it now :slight_smile:

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