DNS server - an easy explanation of how it works. Continue to acquaint you with Internet technologies

in #technology8 years ago

The domain name is made of at least two parts (markers) separated by a point. The numbering of markers starts from right to left. Let’s have a look at a specific example. In the address, hosting.site-5.com domain with suffix com is the first level. All subsequent markers are subdomains - hosting is a subdomain of site-5 domain, and site-5 is a subdomain of com domain.

Conventionally, such a separation can be made up to 127 levels. Any marker can consist of (maximum) of 63 characters, but the length of a domain name can not be more than 254 characters, including points. However, reality and theory, as you know – are different things, so the domain registrars often set their own limits.

DNS servers are located in a specific order, which organizes the hierarchical DNS system. Each domain or subdomain is supported by several authorized DNS servers containing all the necessary information about it. It should be noted that there is the identity of domains and DNS servers’ subordination.

The DNS system works as follows:

The user writes hosting.site-5.com in the web-browser. To send data via TCP / IP stack protocols need to know the IP-address of the specified server, but it usually has got only DNS server address information (typically your ISP provides the address of one main and one backup DNS-server). As a result, a request about the IP-address about the hosting.site-5.com is addressed to the specified DNS server.

It requests information from the central server, for example, 195.58.2.4. The server responds that it has no information about the desired address; however, it knows that the domain zone .com engages the server 241.47.214.2 (this is the so-called authoritative server). In this case, the DNS server requests information from 241.47.214.2.

The answer could be: «site-5.com is served by server 223.157.105.342». The third server returns the IP-address of the site to the browser (very often recursive approach is replaced by requests to the server buffer. If the authoritative server has recently received a request on hosting.site-5.com IP address, then instead of requesting to the next DNS server, it will give the result from the buffer.

To reflex on the required information DNS protocol applies UDP- or TCP-port 53. Typically, requests and information are sent in the form of UDP-datagram. A TCP is used for AXFR-requests or responses weighing more than 512 bytes.

It is important to remember that the IP-address is not a host name or vice versa. One computer may have a large number of websites, and this suggests the possibility of a host with a specific IP-address to own a whole list of names. Similarly, one same name can be correlated with different hosts. Thus the load regulation is achieved.

In order to increase the stability of the system a certain number of servers, which contain the same information are used. In the world, there are 13 of these servers. Each is related to some territory. Data about them is available on any operating system because these servers do not modify the original address. These servers are called the root because they maintain the whole Internet.

Now let's talk about the reverse DNS-request.

In addition to the conversion of symbol names DNS performs the reverse operation of the IP-addresses .

There is known a domain name in-addr.arpa, which data is used for the reconstruction of IP-addresses into the name that consists of characters. Here's an example: to find out the name of a known address (let’s say, 12.13.14.15) it is permissible to make a request in the following form: 15.14.13.12.in-addr.arpa. The result would be given a symbolic name. How can we explain this? Bits in the IP-address that are located at the root stand at the beginning and in the DNS-names – at the end.

As for the DNS records - there a number of categories:

  • Address record (A record) is used to link IP address and host.

  • Canonical name record (CNAME) - tool forwarding data to an alternate name.

  • Mail exchange (MX) refers to the mail exchange server of the presented domain.

  • PTR (pointer, or pointer record) connects its host name with the set (canonical) name.
    NS (name server) calls DNS-server of a submitted domain name.

  • SOA (start of authority record) - a record that refers to the server which contains standard information about the submitted domain.

Talking about domain names it is worth mentioning that they may consist of a small configuration of ASCII symbols. This makes it possible to set the address of the domain, regardless of the language which the user is speaking. So these names are international. ICANN ratified IDNA system based on Punycode. It is able to convert any phrase in Unicode into the symbol set that can be used to work correctly with DNS.


In conclusion I want to tell you how to find out who owns a domain or the IP-address it is sufficient to use the possibility of a network protocol whois. The original idea was to not allow system administrators find the IP-addresses and other data of other administrators. Now a domain name is recognized unregistered on a certain name if it is impossible to find public information about it in this service.

Follow me, to be the first to learn about my publications devoted to popular science and educational topics

With Love,
Kate

Image credit: 1, 2, 3, 4, 5, 6, 7

Sort:  

Great informative post, thank you so much. Namaste :)

Great job!!! Thanks to share your knowledge!

Interesting... I will have to read this several times. I am not a computer expert in the least as most of my time has been spent in athletics but I am trying to learn more about all of this... thanks for explaining some hard to understand topics!

It's really interesting to learn how things work, especially if these are things that you indirectly use every day.
Thanks for your feedback and stay tuned

As a developer, this is something I love to read.
Yes, maybe I'm crazy :D

lol, why do you think you're crazy?) It's fascinating to read something new and to keep learning

I mean it may be quite boring for people not loving technology and the web, but it's damn interesting to me :)

okay, got it. I'm glad you liked reading my article

Following you, love your detailed and well documented posts :)

I set DNS servers up for clients and your post is spot on.
Nice job!

thanks your shares ,这篇文章讲解的很透彻。

Great post, as usual! ^^

Coin Marketplace

STEEM 0.17
TRX 0.15
JST 0.029
BTC 61825.46
ETH 2454.71
USDT 1.00
SBD 2.60