CIS 505 Software Systems Lecture 13 Name Services I CDK 91 9 2 01 14 19 CIS 505 Design space What do you do when change your phone number Email call friend ASAP 400 friends White page updated once a year Changes are infrequent 01 14 19 CIS 505 Design space Design considerations 2 Size of local directory Delay and cost of update propagation Challenges Scale Frequency of change 01 14 19 CIS 505 What is in a name Pure name Un interpreted bit patterns Always have to be looked up May refer to a service instead of a single object Address Identifies the location of an object Efficient for accessing objects But inadequate as ID 01 14 19 CIS 505 Domain Name Service DNS A planetary name service that translates Internet domain names maps node name to IP address mostly independent of location routing etc Use of hierarchy for scalability decentralized administration of the name space hierarchical authority and trust 01 14 19 CIS 505 DNS 101 Domain names are the basis for the Web s global URL space provides a symbolic veneer over the IP address space names for autonomous naming domains e g cis upenn edu names for specific nodes e g codex cis upenn edu names for service aliases e g www mail servers 01 14 19 CIS 505 Domain Name Hierarchy DNS name space is hierarchical com gov org fully qualified names are little endian net firm scalability top level shop decentralized administration arts domains web domains are naming contexts generic TLDs us fr country code replaces primordial flat hosts txt namespace TLDs edu upenn drexel cs ee central 01 14 19 cis washington wharton cs www C1K How is this different from hierarchical directories in distributed file systems Do we already know how to implement this CIS 505 DNS Implementation 101 WWW server for nhc noaa gov IP 140 90 176 22 DNS protocol implementation www nhc noaa gov is 140 90 176 22 DNS server for nhc noaa gov lookup www nhc noaa gov local DNS server typically in a library gethostbyname gethostbyaddr cooperating servers 01 14 19 UDP based client server client side resolvers query answer referral model forward queries among servers common implementation BIND CIS 505 DNS Name Server Hierarchy DNS servers are organized into a hierarchy that mirrors the name space Specific servers are designated as authoritative for portions of the name space Servers may delegate management of drexel subdomains to child name servers Parents refer subdomain queries to their children 01 14 19 ee edu upenn com Root servers list gov servers for every org net TLD firm shop arts web us fr Subdomains correspond to organizational admininstrative boundaries which are not necessarily geographical wharton Servers are bootstrapped with pointers to selected peer and parent servers cis Resolvers are bootstrapped with pointers to one or more local servers they issue recursive queries CIS 505 DNS The Big Issues 1 Naming contexts 2 What about trust How can we know if a server is authoritative or just an impostor I want to use short unqualified names like central instead of central cis upenn edu when I m in the cis upennedu domain What happens if a server lies or behaves erratically What denial of service attacks are possible What about privacy 3 What if an upstream server fails 4 Is the hierarchical structure sufficient for scalability more names vs higher request rates 01 14 19 CIS 505 DNS Caching TLD root Local server caches edu upenn edu cis upenn edu and c1k cis upenn edu edu upenn Caching of query responses allows subsequent queries to bypass the roots of the server hierarchy Each response is stamped with a time to live TTL to limit damage from stale cache entries cis What about negative caching is it worthwhile to cache negative responses query response C1k cis upenn edu 01 14 19 CIS 505 DNS Replication Every DNS domain has or should have at least one secondary name server replica edu domain admin updates primary configure peers to offload queries from primary serve as authoritative backup upenn Secondary replicas keep themselves up to date by periodically fetching refreshing the entire naming database via zone transfer TCP ee cis The primary database is timestamped with a serial number to short circuit if no updates have occurred since last zone transfer primary How to load balance the secondaries query secondary query backup zone transfer 01 14 19 CIS 505 The Server Selection Problem server array A server farm B Which server Which network site Contact the weather service 01 14 19 CIS 505 DNS Round Robin a b c d Brisco Rutgers RFC 1794 DNS server for nhc noaa gov What about DNS caching www nhc noaa gov is How to handle server failures IP address a How effective is the load balancing or b c d lookup www nhc noaa gov local DNS server 01 14 19 CIS 505 Generalized Cache CDN External View Origin Servers push request reply Content Distribution Networks Web Caches request reply Clients 01 14 19 CIS 505 Generalized Cache CDN Internal View Interior Caches Request Routing Function root caches reverse proxies CDN caches Leaf Caches e g ISP proxies bound client populations 01 14 19 CIS 505 DNS based Request Routing How to apply the request routing function Some intermediary intercepts the request and directs it to a selected site Or interpose on the binding procedure before the client sends the request itself Smart proxies or switches E g look at URL or server IP address Smart clients Active Names RPC binding or DNS lookup Third party CDNs are based on DNS servers that select the cache replica site on DNS lookup for the request Akamai Digital Island Web hosting providers e g Exodus etc Like DNS RR but smarter 01 14 19 CIS 505 Using DNS for Third party CDNs Intelligent DNS based request routing has some tricky parts Third party CDNs contract with content providers e g Web sites such as cnn com to serve a subset of their content Resource rich content e g images audio video To use DNS request routing the CDN must assume DNS duties for the URLs that reference the content it serves The content provider does not want to designate the CDN as the authoritative DNS server for its domain e g cnn com Solution make up new DNS domains for the client provider s content served by the CDN 01 14 19 CIS 505 Domain Granularity and Akamaizing CDN e g Akamai creates new domain names for each client content provider The CDN s DNS servers are authoritative for the new domains The client content provider modifies its content so that embedded URLs reference the new domains e g a128 g akamai net Akamaize
View Full Document