Question

subdomains not working through web browsers

After going through the tutorial to set up the nginx server on my droplet configured with untubu, my root domain is successfully displaying the sample message set up in the tutorial. The issue is that I also went to set up a subdomain, but when I attempt to navigate there, the browser just spins until the connection timed out. To make things more confusing for me, I am able to successfully get the contents of the subdomain via curl request.

I have been spinning my wheels on this for a bit and everything I have tried so far has not worked. Any help would be appreciated!

troubleshooting steps taken:

  • Double checked service and config files against the tutorial’s.
  • checked the dns propagation for the sub domain through the dig command, Microsoft edge dns lookup and a few webservices. all are pointing to the right place. *nginx is not throwing off any errors in the logs *flushed the dns cache of my machine to ensure a fresh look up. *A record is correctly set up *nameservers have fully moved over to the digital ocean ones. *Probably a few more items I can’t remember as I have been at this for quite a bit.

Submit an answer


This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Sign In or Sign Up to Answer

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

alexdo
Site Moderator
Site Moderator badge
January 9, 2023

Hello @robertszigeti

I would also assume that this is a temporal DNS issue due to the recent changes that you’ve made.

As already mentioned you can clear your browser’s cache and also attempt a DNS cache flush on your computer in order to speed up the process and have the subdomain loading without issues.

Regards

Bobby Iliev
Site Moderator
Site Moderator badge
January 8, 2023

Hi there,

In addition to what has already been mentioned, what I could suggest is trying the following:

  • From your laptop open a terminal and ping the domain name to verify that the IP address matches your Droplet’s IP. If this is not the case it might be indeed a case of DNS propagation.
  • Try clearing the cache of your browser
  • Check your Nginx error log for some more information on what might be going on in case that it is a configuration problem: tail -100 /var/log/nginx/error.log

Let me know how it goes!

Best,

Bobby

KFSys
Site Moderator
Site Moderator badge
January 8, 2023

Hi @robertszigeti,

This sounds like DNS propagation to me. Please bear in mind that DNS propagation can take up to 24 hours and while it’s usually faster, in some cases it does take so much time.

Additionally, check your DNS records in case you don’t have a duplicate record for your Subdomain pointing it to different places, which might cause a conflict.

Let me know how it goes! Regards, KFSys

Try DigitalOcean for free

Click below to sign up and get $200 of credit to try our products over 60 days!

Sign up