Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

What is DNS?

2025-02-23 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >

Share

Shulou(Shulou.com)06/01 Report--

This article introduces the knowledge of "what is DNS". In the operation of actual cases, many people will encounter such a dilemma. Then let the editor lead you to learn how to deal with these situations. I hope you can read it carefully and be able to achieve something!

Concept

DNS, full name Domain Name System, that is, domain name system, to be clear, it is not DNF Dungeon & Fighter.

How did DNS come from? we know that the resources of a server can be accessed through IP, but the IP address is difficult to remember and not easy to read, so with the existence of DNS, DNS resolves the domain name and establishes a connection with the actual remote server host.

That is, when we visit www.baidu.com, we parse the actual IP address through the DNS server to connect and return it to the client.

Analytical process

Windows and linux can query the domain name resolution result by using the command nslookup, as shown in the following figure.

You can also view the parsing process in more detail through the dig command in linux, as shown in the figure.

Local mapping

We can modify the relationship between host custom configuration domain name and IP in the operating system, that is, we can allow any domain name to access any IP address.

Windows: C:\ windows\ System32\ drivers\ etc\ hosts

Linux: / etc/hosts

For example, we often map localhost to 127.0.0.1, and we can map baidu.com to xx.xx.xx.xx. If our local mapping relationship is unknowingly modified, it will lead to serious security problems, if the taobao.com is mapped to the IP of hackers or attackers, then our information and property security will not be guaranteed. The hosts file in the early windows can be modified at will, but after win7, this file is set to read-only to avoid malicious modification. Of course, if our computer is equipped with antivirus and protection software, we can also prevent this file from being maliciously modified.

Domain name resolution method

Finally, I will talk about several methods of domain name resolution, which are generally not used by domain name managers.

A record

IP address resolution means that a domain name can be bound to an IP address. Only one IP address can be bound to a domain name, but an IP address can be bound to multiple domain names.

AAAA record

That is, IPV6 address resolution.

CNAME record

Alias resolution, for example, we can resolve wx.qq.com to www.weixin.com,weixin.qq.com or www.weixin.com,www.weixin.com, which is the actual IP address bound to the A record. In general, large websites use this parsing method, and the advantage of this is that no matter how the ip address of www.weixin.com is changed, it will not affect the resolution of wx.qq.com and weixin.qq.com.

MX record

Mail Exchange parsing, mail server address, that is, the route of xx@baidu.com will be sent to the binding record server of the MX record.

NS record

Specifies that the DNS server address is resolved, that is, the DNS server with which IP address this domain name is resolved.

TXT record

Set the description for the domain name, and you can see the description of the domain name when you parse it with the command.

When setting domain name resolution, there is also a TTL value, that is, the time it takes for the DNS server to cache the domain name resolution result, after which it will be re-resolved, otherwise the cached resolution result will be returned. This is generally set to 1 hour, that is, 3600 seconds.

Let's take a look at the screenshot of adding resolution to Aliyun's domain name.

That's all for "what DNS is". Thank you for your reading. If you want to know more about the industry, you can follow the website, the editor will output more high-quality practical articles for you!

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Internet Technology

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report