homepage Welcome to WebmasterWorld Guest from 54.145.183.126
register, free tools, login, search, pro membership, help, library, announcements, recent posts, open posts,
Become a Pro Member

Home / Forums Index / WebmasterWorld / Domain Names
Forum Library, Charter, Moderators: buckworks & webwork

Domain Names Forum

    
browsers and DNS
lucy24

WebmasterWorld Senior Member lucy24 us a WebmasterWorld Top Contributor of All Time Top Contributors Of The Month



 
Msg#: 4596902 posted 1:23 am on Jul 27, 2013 (gmt 0)

Today's strictly mechanical question:

Before a browser can do anything else, it has to hit up the DNS to translate the requested hostname into a numerical address.

How does it find the DNS in the first place? Is this something that is built into the browser? Or is there an uber-DNS where the browser goes to get a current list of places to try?

Next question: Once the browser has a list, how does it decide what order to check? Is it hard-coded somewhere, or does the browser "learn" based on success rates of earlier queries?

 

Hoople

10+ Year Member



 
Msg#: 4596902 posted 3:31 am on Jul 27, 2013 (gmt 0)

The browser passes the DNS request to the operating system. The OS then looks in it's configuration for a DNS setting. It then sends the request to the first server if there is more than one.

The 'finding' of the DNS can come from one of three ways: 1) At startup when the machine asks the 'network' what it's IP is the response contains a DNS setting of one or more servers. 2) Someone manually set the DNS servers in the operating systems configuration. 3) Rarest is no DNS or IP is initially set and the OS then assumes an IP address and 'Broadcast' requests a DNS lookup.

Order to check is an OS behavior. The DNS spec call for moving to the second (and any beyond) only when the first DNS server does not respond AT ALL. Some supposed references state the move occurs when the first server responds with a 'no record' response. Not real bad but definitely different! There are a few OS' out there that do this....

Above is all very high level with no 'fine point' specifics. Ask more specifics and we can give more....I'm not a DNS guru but I have been involved in DNS since before it existed.

lucy24

WebmasterWorld Senior Member lucy24 us a WebmasterWorld Top Contributor of All Time Top Contributors Of The Month



 
Msg#: 4596902 posted 4:51 am on Jul 27, 2013 (gmt 0)

Uh-oh, I expressed that question in a completely wrong way.

I don't mean when you're running a server. I mean when you're using a browser and the browser needs to go find example.com.

Hoople

10+ Year Member



 
Msg#: 4596902 posted 5:50 am on Jul 27, 2013 (gmt 0)

I mean when you're using a browser and the browser needs to go find example.com.


Yes, got that point. The above was written based on your question where the browser is on a user PC and not a server.

lucy24

WebmasterWorld Senior Member lucy24 us a WebmasterWorld Top Contributor of All Time Top Contributors Of The Month



 
Msg#: 4596902 posted 7:02 am on Jul 27, 2013 (gmt 0)

It then sends the request to the first server if there is more than one.

You gotta dumb this down more. What server where? :(

gpmgroup

WebmasterWorld Senior Member 10+ Year Member



 
Msg#: 4596902 posted 10:14 am on Jul 27, 2013 (gmt 0)

The browser asks your machine/device if it knows the IP address of the website you are looking for. If it does, it returns the IP address to your browser, if it doesn’t it asks the machine your machine/device is connected to. (That may be another machine in your office/home or it may be a machine at your Internet Service Provider (ISP)

The connected machine then repeats the question, if it knows the answer it returns the answer, if not it asks the machine it in turn is connected to.

This process is repeated right back to the “root servers” which return an authoritative answer for each of the TLDs (.com’s .info’s etc.). The root server would then send the asking machine to VeriSign’s servers for a .com or Afilias’s severs for .info domain.

Each of those companies maintain an authoritative list of IP addresses for all their customers’ second level domains. (yourdomain.com, mydomain.com, webmasterworld.com etc.)

If the owner of the second level domain you are looking for has configured third level (‘sub’) domains on his domain (www.yourdomain.com, ftp.yourdomain.com, sales.yourdomain.com) the IP of those addresses will be returned by a DNS server maintained by the second level domain owner.


Once a machine in the chain has done a look up it hangs on to the answer for a while in case it's asked again, that way it knows the answer without having to ask again which means it can return the answer quicker. The only problem is site some owners may change/reconfigure IP addresses of their domains so it can only risk hanging on to the answer for a little while.

gpmgroup

WebmasterWorld Senior Member 10+ Year Member



 
Msg#: 4596902 posted 12:38 pm on Jul 27, 2013 (gmt 0)


Probably would have been better to say

Each of those companies maintain an authoritative list of DNS addresses for all their customers’ second level domains. (yourdomain.com, mydomain.com, webmasterworld.com etc.)

rather than

Each of those companies maintain an authoritative list of IP addresses for all their customers’ second level domains. (yourdomain.com, mydomain.com, webmasterworld.com etc.)

lucy24

WebmasterWorld Senior Member lucy24 us a WebmasterWorld Top Contributor of All Time Top Contributors Of The Month



 
Msg#: 4596902 posted 8:39 pm on Jul 27, 2013 (gmt 0)

Ah. Mystery solved. So the browser doesn't personally do the rounds of every DNS under the sun; it just asks verisign. It seemed like an awful amount of work to do in under a second (the short but visible time it takes for your browser to put up the "Sorry, can't find any such domain" message). Although I get the impression that all those separate domain-name lookups are the main reason heavily hotlinked pages take so infernally long to load up.

Global Options:
 top home search open messages active posts  
 

Home / Forums Index / WebmasterWorld / Domain Names
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Home ¦ Free Tools ¦ Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About ¦ Library ¦ Newsletter
WebmasterWorld is a Developer Shed Community owned by Jim Boykin.
© Webmaster World 1996-2014 all rights reserved