教学之友,学习之友。

站长教学网

当前位置: 站长教学网 > 服务器 > DNS服务器 >

dns是什么 dns中文的意思 What is DNS?

时间:2012-03-21 15:26来源:未知 作者:ken 点击:

问:什么是“DNS”?其中文为何?

答:DNS,简单地说,就是Domain Name System,翻成中文就是“域名系统”。

问:DNS有什么用途?

答:在一个TCP/IP架构的网络(例如Internet)环境中,DNS是一个非常重要而且常用的系统。主要的功能就是将人易于记忆的Domain Name与人不容易记忆的IP Address作转换。而上面执行DNS服务的这台网络主机,就可以称之为DNS Server。基本上,通常我们都认为DNS只是将Domain Name转换成IP Address,然后再使用所查到的IP Address去连接(俗称“正向解析”)。事实上,将IP Address转换成Domain Name的功能也是相当常使用到的,当login到一台Unix工作站时,工作站就会去做反查,找出你是从哪个地方连线进来的(俗称“逆向解析”)。

问:DNS是怎么运作的?

答:DNS是使用层的方式来运作的。例如:哈工大紫丁香站的Domain Name为bbs.hit.edu.cn,这个Domain Name当然不是凭空而来的,是从.edu.cn所分配下来的。.edu.cn又是从.cn授予(delegation)的。.cn是从哪里来的呢?答案是从“.”,也就是所谓的“根域”(root domain)来的。根领域已经是Domain Name的最上层。而“.”这层是由InterNIC(Internet Network Information Center,互联网信息中心)所管理。全世界的Domain Name就是这样,一层一层的授予下来。

问:当我查一个Domain Name时,DNS是怎么查出它的IP的呢?

答:举个例子,假设今天我们查的Domain Name(作一个dns query)为bbs.hit.edu.cn时,DNS Server会这么处理:

(1) 你所用的电脑(可能是PC,也可能是工作站)送出一个问题给这台电脑所设定的DNS Server,提问:bbs.hit.edu.cn的IP是什么?

(2) 这台DNS会先看看是不是在它的cache中,如果是,就丢出答案。如果不是,就从最上头查起。在DNS Server上面一定有设定“.”要跟谁问。所以,这个时候它就往“.”层的任何一台DNS(目前“.”有13台)问:.cn要问谁?

(3) “.”层的DNS会回答.cn要向谁查(同时你用的DNS会cache起来这个答案)。

(4) 接下来你所用的DNS就会向.cn这层的DNS问:.edu.cn要问谁?

(5) .cn的这层就会回答.edu.cn要向谁查(同时你用的DNS也把这答案cache起来)。

(6)直到bbs.hit.edu.cn回答:bbs.hit.edu.cn的IP是202.118.224.2(又cache起来)。

经过了这么多的过程,终于得到了这个IP,接下来才能作进一步的连线。要注意的是,在每一层都会问一个问题,并且把答案记下来(cache起),而且还会忘掉(看该层的设定是要cache多久)。

问:DNS要怎么设置?

答:如果,只是要使用DNS,那只要在TCP/IP的网络属性中设置即可。设置的方法跟使用的操作系统有关。例如:Windows 9x在“控制面板”→“网络”→“TCP/IP”→“属性”中,找到DNS的部分再来设置。Unix在/etc/resolv.conf这个文件中设置(如果,要架设一台DNS Server,就不是在这里讨论的了)。

问:哪一台 DNS 资料最新?

答:如果你知道DNS是利用阶层架构运作的,那就应该知道,离你最近的DNS,就是最好的。

 

What is DNS?

Domain Name System (DNS) is a database system that translates a computer's fully qualified domain name into an IP address.

Networked computers use IP addresses to locate and connect to each other, but IP addresses can be difficult for people to remember. For example, on the web, it's much easier to remember the domain name www.amazon.com than it is to remember its corresponding IP address (207.171.166.48). DNS allows you to connect to another networked computer or remote service by using its user-friendly domain name rather than its numerical IP address. Conversely, Reverse DNS (rDNS) translates an IP address into a domain name.

Each organization that maintains a computer network will have at least one server handling DNS queries. That server, called a name server, will hold a list of all the IP addresses within its network, plus a cache of IP addresses for recently accessed computers outside the network. Each computer on each network needs to know the location of only one name server. When your computer requests an IP address, one of three things happens, depending on whether or not the requested IP address is within your local network:

  • If the requested IP address is registered locally (i.e., it's within your organization's network), you'll receive a response directly from one of the local name servers listed in your workstation configuration. In this case, there usually is little or no wait for a response.

     
  • If the requested IP address is not registered locally (i.e., outside your organization's network), but someone within your organization has recently requested the same IP address, then the local name server will retrieve the IP address from its cache. Again, there should be little or no wait for a response.

     
  • If the requested IP address is not registered locally, and you are the first person to request information about this system in a certain period of time (ranging from 12 hours to one week), then the local name server will perform a search on behalf of your workstation. This search may involve querying two or more other name servers at potentially very remote locations. These queries can take anywhere from a second or two up to a minute (depending on how well connected you are to the remote network and how many intermediate name servers must be contacted). Sometimes, due to the lightweight protocol used for DNS, you may not receive a response. In these cases, your workstation or client software may continue to repeat the query until a response is received, or you may receive an error message.

When you use an application such as telnet to connect to another computer, you most likely type in the domain name rather than the IP address of that computer. The telnet application takes the domain name and uses one of the above methods to retrieve its corresponding IP address from the name server. A good analogy is to think of DNS as an electronic telephone book for a computer network. If you know the name of the computer in question, the name server will look up its IP address.

(责任编辑:ken)
TAG标签: dns dns的功能 dns设置
顶一下
(0)
0%
踩一下
(0)
0%
------分隔线----------------------------
发表评论
请自觉遵守互联网相关的政策法规,严禁发布色情、暴力、反动的言论。
评价:
表情:
注册登录:不允许匿名留言,登录后留言无需输入验证码。
栏目列表
最新内容