DOC PREVIEW
Berkeley COMPSCI 268 - L-17 DNS and the Web

This preview shows page 1-2-14-15-29-30 out of 30 pages.

Save
View full document
View full document
Premium Document
Do you want full access? Go Premium and unlock all 30 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 30 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 30 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 30 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 30 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 30 pages.
Access to all documents
Download any document
Ad free experience
Premium Document
Do you want full access? Go Premium and unlock all 30 pages.
Access to all documents
Download any document
Ad free experience

Unformatted text preview:

CS 268: Computer NetworkingL-17 DNS and the Web2DNS and the Web• DNS• CDNs• Readings• DNS Performance and the Effectiveness ofCaching• Development of the Domain Name System3Naming• How do we efficiently locate resources?• DNS: name  IP address• Service location: description  host• Other issues• How do we scale these to the wide area?• How to choose among similar services?4Overview• DNS• Server Selection and CDNs5Obvious Solutions (1)Why not centralize DNS?• Single point of failure• Traffic volume• Distant centralized database• Single point of update• Doesn’t scale!6Obvious Solutions (2)Why not use /etc/hosts?• Original Name to Address Mapping• Flat namespace• /etc/hosts• SRI kept main copy• Downloaded regularly• Count of hosts was increasing: machine perdomain  machine per user• Many more downloads• Many more updates7Domain Name System Goals• Basically building a wide area distributeddatabase• Scalability• Decentralized maintenance• Robustness• Global scope• Names mean the same thing everywhere• Don’t need• Atomicity• Strong consistency8DNS RecordsRR format: (class, name, value, type, ttl)• DB contains tuples called resource records (RRs)• Classes = Internet (IN), Chaosnet (CH), etc.• Each class defines value associated with typeFOR IN class:• Type=A• name is hostname• value is IP address• Type=NS• name is domain (e.g. foo.com)• value is name of authoritativename server for this domain• Type=CNAME• name is an alias name forsome “canonical” (the real)name• value is canonical name• Type=MX• value is hostname ofmailserver associated withname9DNS Design: Hierarchy Definitionsrootedunetorgukcomgwu cmu berkeleybumitcseecs• Each node in hierarchystores a list of names thatend with same suffix• Suffix = path up tree• E.g., given this tree, wherewould following be stored:• Fred.com• Fred.edu• Fred.berkeley.edu• Fred.cs.berkeley.edu• Fred.cs.mit.edu10DNS Design: Zone Definitionsrootedunetorgukcomcagwu cmu ucb bumitcseecsradlabSingle nodeSubtreeCompleteTree• Zone = contiguoussection of name space• E.g., Complete tree,single node or subtree• A zone has an associatedset of name servers11DNS Design: Cont.• Zones are created by convincing owner node tocreate/delegate a subzone• Records within zone stored multiple redundant nameservers• Primary/master name server updated manually• Secondary/redundant servers updated by zone transferof name space• Zone transfer is a bulk transfer of the “configuration” of a DNSserver – uses TCP to ensure reliability• Example:• CS.Berkeley.EDU created by Berkeley.EDUadministrators12Servers/Resolvers• Each host has a resolver• Typically a library that applications can link to• Local name servers hand-configured (e.g./etc/resolv.conf)• Name servers• Either responsible for some zone or…• Local servers• Do lookup of distant host names for local hosts• Typically answer queries about local zone13DNS: Root Name Servers• Responsible for“root” zone• Approx. dozen rootname serversworldwide• Currently {a-m}.root-servers.net• Local name serverscontact root serverswhen they cannotresolve a name• Configured with well-known root servers14DNS Message FormatIdentificationNo. of QuestionsNo. of Authority RRsQuestions (variable number of answers)Answers (variable number of resource records)Authority (variable number of resource records)Additional Info (variable number of resource records)FlagsNo. of Answer RRsNo. of Additional RRsName, type fieldsfor a queryRRs in responseto queryRecords forauthoritativeserversAdditional“helpful info thatmay be used12 bytes15DNS Header Fields• Identification• Used to match up request/response• Flags• 1-bit to mark query or response• 1-bit to mark authoritative or not• 1-bit to request recursive resolution• 1-bit to indicate support for recursive resolution16Typical ResolutionClientLocal DNS serverroot & edu DNS serverns1.berkeley.edu DNS serverwww.cs.berkeley.eduNS ns1.berkeley.eduwww.cs.berkeley.eduNS ns1.cs.berkeley.eduA www=IPaddrns1.cs.berkeley.eduDNSserver17Typical Resolution• Steps for resolving www.berkeley.edu• Application calls gethostbyname() (RESOLVER)• Resolver contacts local name server (S1)• S1 queries root server (S2) for (www.berkeley.edu)• S2 returns NS record for berkeley.edu (S3)• What about A record for S3?• This is what the additional information section is for(PREFETCHING)• S1 queries S3 for www.berkeley.edu• S3 returns A record for www.berkeley.edu• Can return multiple A records  what does thismean?18Lookup MethodsRecursive query:• Server goes out andsearches for more info(recursive)• Only returns final answeror “not found”Iterative query:• Server responds with asmuch as it knows(iterative)• “I don’t know this name,but ask this server”Workload impact on choice?• Local server typically doesrecursive• Root/distant server doesiterativerequesting hostsurf.eurecom.frgaia.cs.umass.eduroot name serverlocal name serverdns.eurecom.fr123456authoritative nameserverdns.cs.umass.eduintermediate name serverdns.umass.edu78iterated query19Workload and Caching• What workload do you expect for different servers/names?• Why might this be a problem? How can we solve this problem?• DNS responses are cached• Quick response for repeated translations• Other queries may reuse some parts of lookup• NS records for domains• DNS negative queries are cached• Don’t have to repeat past mistakes• E.g. misspellings, search strings in resolv.conf• Cached data periodically times out• Lifetime (TTL) of data controlled by owner of data• TTL passed with every record20Typical ResolutionClientLocal DNS serverroot & edu DNS serverns1.berkeley.edu DNS serverwww.cs.berkeley.eduNS ns1.berkeley.eduwww.cs.berkeley.eduNS ns1.cs.berkeley.eduA www=IPaddrns1.cs.berkeley.eduDNSserver21Subsequent Lookup ExampleClientLocal DNS serverroot & edu DNS serverberkeley.edu DNS servercs.berkeley.eduDNSserverftp.cs.berkeley.eduftp=IPaddrftp.cs.berkeley.edu22Reliability• DNS servers are replicated• Name service available if ≥ one replica is up• Queries can be load balanced between replicas• UDP used for queries• Need reliability  must implement this on top of UDP!• Why not just use TCP?• Try alternate servers on timeout• Exponential backoff when retrying same server• Same identifier for all


View Full Document

Berkeley COMPSCI 268 - L-17 DNS and the Web

Documents in this Course
Lecture 8

Lecture 8

33 pages

L-17 P2P

L-17 P2P

50 pages

Multicast

Multicast

54 pages

Load more
Download L-17 DNS and the Web
Our administrator received your request to download this document. We will send you the file to your email shortly.
Loading Unlocking...
Login

Join to view L-17 DNS and the Web and access 3M+ class-specific study document.

or
We will never post anything without your permission.
Don't have an account?
Sign Up

Join to view L-17 DNS and the Web 2 2 and access 3M+ class-specific study document.

or

By creating an account you agree to our Privacy Policy and Terms Of Use

Already a member?