0

I am facing a weird problem. I have a domain which is pointed to a server where my site is hosted, now the DNS of the domain was mistakenly changed to something else and it started pointing to somewhere else, but I was still able to see, login and edit that website but when someone tried to access it from some other country it started giving him error

What could be the possible that I was still able to see all this even though DNS was changed??

HBruijn
  • 72,524
  • 21
  • 127
  • 192
user131451
  • 1
  • 1
  • 2

2 Answers2

1

The are multiple reasons this could happen.

  • DNS TTL (Time To Live): The DNS is cached because the time since you last requested the DNS for a domain has not expired... it may have expired for someone else before you since not every user on the planet synchronizes their clocks to all start their 86400 seconds (if that's what your TTL is set to) on exactly the same second.
  • Browser Cache: Google Chrome, for example, has built-in DNS caching. I have personally had the TTL expire and even manually set a different IP for a domain in my hosts file only to find a it was the browser caching DNS. Seem to hang onto the original IP when a users has a tab open with that particular domain open, but this is just my personal experience and didn't do testing to prove that theory.
  • Windows hosts file or *nix equivalent: You can also manually choose what IP you want a domain name to point to in your hosts file (it's different for Linux/Unix/Mac). This is nice if you're wanting to develop a website on the same domain name but are not ready for everyone else to see it yet. Just point your domain to your localhost or your new web hosting company and secretly develop the whole website even using the domain name locally. No one else will see this but of course it's not password protected so it's remotely possible someone could possibly find it. Then when ready to go live, update DNS at your registrar to point to the new web hosting IP address and remove your hosts entry.

Here's a simple guide on how make a DNS change safely.

god_is_love
  • 143
  • 1
  • 6
0

What could be the possible that I was still able to see all this even though DNS was changed??

  • Caching, DNS records are cached for the duration of their Time To Live (TTL). If your local cache had not timed out then it would not have seen the change.

  • A local entry in your hosts file. The hosts file is generally consulted before the DNS.

The TCP/IP Guide is an excellent resource for DNS.

user9517
  • 114,104
  • 20
  • 206
  • 289