Host addresses eg 169229131109 a number used by protocols conforms to network structure the where Host names eg instreecsberkeleyedu mnemonic name usable by humans ID: 1045632
Download Presentation The PPT/PDF document "DNS and HTTP CS 168 Domain Name Service" is the property of its rightful owner. Permission is granted to download and print the materials on this web site for personal, non-commercial use only, and to display it on your personal computer provided you do not modify the materials and that you retain all copyright notices contained in the materials. By downloading content from our website, you accept the terms of this agreement.
1. DNS and HTTPCS 168
2. Domain Name ServiceHost addresses: e.g., 169.229.131.109a number used by protocolsconforms to network structure (the “where”)Host names: e.g., instr.eecs.berkeley.edumnemonic name usable by humansconforms to organizational structure (the “who”)The Domain Name System (DNS) is how we map from one to the othera directory service for hosts on the Internet
3. Hierarchical Namespace“Top Level Domains” are at the topDomains are subtreese.g.: .edu, berkeley.edu, eecs.berkeley.eduName is leaf-to-root pathinstr.eecs.berkeley.eduName collisions trivially avoided!each domain’s responsibilityrooteducomgovmilorgnetukfrberkeleyuclaeecssimsinstr…
4. Recursive DNS QueryAsk local DNS server to get the response for you“Let me find out where it is for you”Rootcomns1.google.comwww.google.comdns.berkeley.eduWhere is www.google.com?
5. Iterative DNS queryAsk Server who to ask next“I don’t know this name, but this other server might”Rootcomns1.google.comwww.google.comdns.berkeley.eduWhere is www.google.com?
6. DNS RecordsDNS info. stored as resource records (RRs)RR is (name, value, type, TTL)Type = A: (-> Address)name = hostnamevalue = IP addressType = NS: (-> Name Server)name = domainvalue = name of dns server for domain
7. DNS Records (contd.)Type = CNAME: (-> Canonical NAME)name = hostnamevalue = canonical nameType = MX: (-> Mail eXchanger)name = domain in email addressvalue = canonical name(s) of mail server(s)
8. Fun with dig!
9. Hyper Text Transfer Protocol (HTTP)Client-server architectureserver is “always on” and “well known”clients initiate contact to serverSynchronous request/reply protocol Runs over TCP, Port 80StatelessASCII format
10. Client/Server communicationGET /somedir/page.html HTTP/1.1Host: www.someschool.edu User-agent: Mozilla/4.0Connection: close Accept-language: fr (blank line) HTTP/1.1 200 OK Connection closeDate: Thu, 06 Aug 2006 12:00:15 GMT Server: Apache/1.3.0 (Unix) Last-Modified: Mon, 22 Jun 2006 ... Content-Length: 6821 Content-Type: text/html(blank line) data data data data data ... HTTP Request(Client to Server)(Server to Client)HTTP Response(method)(resource)(protocol version)c(header)(protocol version)(status code)(status phrase)(header)(data)
11. HTTP’s stateless-nessPros?ScalableEasier to handle failuresOrder of requests is immaterialCons?Can’t keep state! (shopping cart, user profiles…)Solution?Client-side stateCookies!
12. HTTP Performance: Non-persistent TCP ConnectionTCP SYNTCP SYN-ACKTCP ACK + HTTP REQUESTTCP ACK + HTTP RESPONSETCP FINTCP FIN-ACKTCP ACKTCP ACK1 RTT1 RTT+ transmission
13. Other options?Concurrent Requests and responsesUse multiple connections in parallelPersistent ConnectionsMaintain TCP connection across multiple requestsPipelined Requests and ResponsesBatch requests and responses to reduce the number of packets
14. Easy ways to order!Go to storeOrder burgerGo to storeOrder drinkGo to storeOrder friesGo to store with two friendsEach person orders one item (in parallel)Go to storeOrder burger, drink and fries1Go to storeOrder burgerOrder drinkOrder fries234
15. Q2
16. Q3
17.