计算机网络讲义——dns课件

上传人:ji****n 文档编号:54549340 上传时间:2018-09-14 格式:PPT 页数:55 大小:404.50KB
返回 下载 相关 举报
计算机网络讲义——dns课件_第1页
第1页 / 共55页
计算机网络讲义——dns课件_第2页
第2页 / 共55页
计算机网络讲义——dns课件_第3页
第3页 / 共55页
计算机网络讲义——dns课件_第4页
第4页 / 共55页
计算机网络讲义——dns课件_第5页
第5页 / 共55页
点击查看更多>>
资源描述

《计算机网络讲义——dns课件》由会员分享,可在线阅读,更多相关《计算机网络讲义——dns课件(55页珍藏版)》请在金锄头文库上搜索。

1、2: Application Layer,1,DNS: Domain Name System,People: many identifiers: SSN, name, Passport # Internet hosts, routers: IP address (32 bit) - used for addressing datagrams “name”, e.g., gaia.cs.umass.edu - used by humans Q: map between IP addresses and name ?,Domain Name System: distributed database

2、 implemented in hierarchy of many name servers application-layer protocol host, routers, name servers to communicate to resolve names (address/name translation) note: core Internet function implemented as application-layer protocol complexity at networks “edge”,2: Application Layer,2,DNS name server

3、s,no server has all name-to-IP address mappings local name servers: each ISP, company has local (default) name server host DNS query first goes to local name server authoritative name server: for a host: stores that hosts IP address, name can perform name/address translation for that hosts name,Why

4、not centralize DNS? single point of failure traffic volume distant centralized database maintenancedoesnt scale!,2: Application Layer,3,DNS: Root name servers,contacted by local name server that can not resolve name root name server: contacts authoritative name server if name mapping not known gets

5、mapping returns mapping to local name server dozen root name servers worldwide,2: Application Layer,4,Simple DNS example,host surf.eurecom.fr wants IP address of gaia.cs.umass.edu 1. Contacts its local DNS server, dns.eurecom.fr 2. dns.eurecom.fr contacts root name server, if necessary 3. root name

6、server contacts authoritative name server, dns.umass.edu, if necessary,requesting host surf.eurecom.fr,gaia.cs.umass.edu,root name server,authorititive name server dns.umass.edu,1,2,3,4,5,6,2: Application Layer,5,DNS example,Root name server: may not know authoratiative name server may know intermed

7、iate name server: who to contact to find authoritative name server,requesting host surf.eurecom.fr,gaia.cs.umass.edu,root name server,1,2,3,4,5,6,authoritative name server dns.cs.umass.edu,7,8,2: Application Layer,6,DNS: iterated queries,recursive query: puts burden of name resolution on contacted n

8、ame server heavy load? iterated query: contacted server replies with name of server to contact “I dont know this name, but ask this server”,requesting host surf.eurecom.fr,gaia.cs.umass.edu,root name server,1,2,3,4,5,6,authoritative name server dns.cs.umass.edu,7,8,iterated query,2: Application Laye

9、r,7,DNS: caching and updating records,once (any) name server learns mapping, it caches mapping cache entries timeout (disappear) after some time update/notify mechanisms under design by IETF RFC 2136 http:/www.ietf.org/html.charters/dnsind-charter.html,2: Application Layer,8,DNS records,DNS: distrib

10、uted db storing resource records (RR),Type=NS name is domain (e.g. ) value is IP address of authoritative name server for this domain,Type=A name is hostname value is IP address,Type=CNAME name is an alias name for some “cannonical” (the real) name value is cannonical name,Type=MX value is hostname

11、of mailserver associated with name,2: Application Layer,9,DNS protocol, messages,DNS protocol : query and repy messages, both with same message format,msg header identification: 16 bit # for query, repy to query uses same # flags: query or reply recursion desired recursion available reply is authori

12、tative,2: Application Layer,10,DNS protocol, messages,Name, type fieldsfor a query,RRs in reponse to query,records for authoritative servers,additional “helpful” info that may be used,2: Application Layer,11,Socket programming,Socket API introduced in BSD4.1 UNIX, 1981 Now Industry standard Availabl

13、e on many operating systems explicitly created, used, released by apps client/server paradigm two types of transport service via socket API: unreliable datagram reliable, byte stream-oriented,Goal: learn how to build client/server application that communicate using sockets,2: Application Layer,12,Wh

14、at is “socket”?,A socket is a virtual connection between two applications Using a socket, two processes can communicate with each other The socket is the major communication tool for Internet applications A socket is bi-directional (full-duplex) transmission A socket can be created dynamically,2: Ap

15、plication Layer,13,Network,Socket as a virtual connection between two processes,(physical connection),Host B,Process 2,Host A,Process 1,Information Hiding,2: Application Layer,14,Socket as a client/server model,2: Application Layer,15,Socket,OS abstraction (not hardware) Created dynamically Persists

16、 only while application runs Referenced by a descriptor,2: Application Layer,16,Descriptor,Small integer One per active socket Used in all operations on socket Generated by OS when socket created Only meaningful to application that owns socket In UNIX, integrated with file descriptors,2: Application Layer,17,Creating a Socket,Application calls socket functionOS returns descriptor for socket Descriptor valid until application closes socket or exits Common: protofamily = PF_INET, type = SOCK_STREAM,SOCK_DGRAM or SOCK_RAW,

展开阅读全文
相关资源
正为您匹配相似的精品文档
相关搜索

最新文档


当前位置:首页 > 中学教育 > 初中教育

电脑版 |金锄头文库版权所有
经营许可证:蜀ICP备13022795号 | 川公网安备 51140202000112号