Presentation is loading. Please wait.

Presentation is loading. Please wait.

Distributed Systems Naming. Naming Names are used to share resources Name uniquely identify entities Names refer to location If we have named entity,

Similar presentations


Presentation on theme: "Distributed Systems Naming. Naming Names are used to share resources Name uniquely identify entities Names refer to location If we have named entity,"— Presentation transcript:

1 Distributed Systems Naming

2 Naming Names are used to share resources Name uniquely identify entities Names refer to location If we have named entity, then we can access it The organisation and implementation of human- friendly naming systems.

3 Names or Codes, or Numbers? –Names (when meaningful) are easier to remember than codes or numbers… –Number (or sequence codes) are more useful for structuring data and locating resources by a program.. –Example: IPv4 128.250.29.30 marg.csse.unimelb.edu.au CSSE network Level 5 subnet Machine Identifier Australia Education Institutions The University of Melbourne Computer Science and Software Engineering Machine name

4 Naming Naming as it relates to mobile entities Name is a string of bits or characters refer to an entity. Entity may be host, printer, disk, file, user, mailbox, web page, message,…..

5 Names or Codes? or Numbers? –As discussed in file system (hierarchical naming of files) and mounting at right location. Which one is better? Disk 4, Sector 26, Block15 /usr/bin/tar

6 Naming Each entity has access point The name of access point is called address of entity or entity access point Identifier – a reference to an entity that is often unique and never reused E.g. any person has a name and telephone number (access point)

7 Naming The name of entity is independent of its address Name should be: –An identifier (name) refer to only one entity –The name always refers to the same entity

8 Name Spaces The name space is the way that names in a particular system are organized. This also defines the set of all possible names. Examples: –Phone numbers –Credit card numbers –DNS –Human names in the US –Robert Ludlum books –Files in UNIX, Windows –URLs

9 Name Space Name space is the set of all names in distributed system Name space is a directed graph with a single root node. Root node of naming graph is a node with no incoming edges

10 Role of Names and Naming Services - Name Resolution 66.102.11.104 100.109.23.104 Naming Service nameIPattributes www.google.com www.hotmail.com …….. Client

11 Namespaces Within distributed systems, a namespace is represented by a labelled, directed graph with two types of nodes: -leaf nodes: information on an entity. -directory nodes: a collection of named outgoing edges (which can lead to any other type of node). Nodes can be referred to by path names (with absolute or relative). File systems are a classic example …

12 Name Spaces (1) Leaf node represents named entity Directory node is entity in distributed system

13 Name space examples File system is a name space where leaf is a file Directory node represents file directory URL is identifier name for web services

14 Name Space Distribution The name space is partitioned into three layers: Global layer –It is the root node and some other related nodes –It is not changed –It represented organizations,….

15 Name Space Distribution Administrational layer –Represents departments in such organization –It is relatively stable Managerial layer –Nodes change regularly –Represents shared files,…

16 Name Space Distribution Comparing the features/characteristics of name servers that implement nodes within a large-scale name space (partitioned into a global, administrational and managerial layer). Availability and performance requirements are met by replication and caching at each of the various layers (more on caching later). Feature/CharacteristicGlobalAdministrationalManagerial Geographical scale of networkWorldwideOrganizationDepartment Total number of nodesFewManyVast numbers Responsiveness to lookupsSecondsMillisecondsImmediate Update propagationLazyImmediate Number of replicasManyNone or fewNone Is client-side caching applied?Yes Sometimes

17 Name Space Distribution

18 A comparison between name servers for implementing nodes from a large- scale name space partitioned into a global layer, as an administrational layer, and a managerial layer. ItemGlobalAdministrationalManagerial Geographical scale of networkWorldwideOrganizationDepartment Total number of nodesFewManyVast numbers Responsiveness to lookupsSecondsMillisecondsImmediate Update propagationLazyImmediate Number of replicasManyNone or fewNone Is client-side caching applied?Yes Sometimes

19 Name Resolution The process of looking up a name is called name resolution Let the number 0031204430784 does not mean any thing for people but when we give information that this is telephone number then name resolution can start This help information is called closure mechanism

20 More on Name Resolution A “name resolver” provides a local name resolution service to clients – it is responsible for ensuring that the name resolution process is carried out. Two Common Approaches: 1. Iterative Name Resolution. 2. Recursive Name Resolution.

21 Iterative Name Resolution The name resolver queries each name server (at each layer) in an iterative fashion. Note: the client is doing all the work here (and generating a lot of traffic, too).

22 Name Resolution If distributed system is in LAN only, then it implements name space by means of single name server In WAN, Distributed system implements name space over multiple name servers

23 Recursive Name Resolution The name resolver starts the process, then each server temporarily becomes a client of the next name server until the resolution is satisfied. The results are then returned to the client.

24 Caching and Recursive Name Resolution Recursive name resolution of. Name servers cache intermediate results for subsequent lookups. This is seen as a key advantage to the recursive name resolution approach, even though the workload has been moved from the client to the servers. Nevertheless, think about subsequent lookups … Server for node Should resolve Looks up Passes to child Receives and caches Returns to requester cs # -- # vu # # # # ni # # # # # # root # # # # # # # #

25 Iterative vs. Recursive Resolution The comparison between recursive and iterative name resolution with respect to communication costs. Again, the recursive technology is generally regarded to have an advantage in this situation (especially over longer, more expensive WAN links).

26 Two Naming Examples The Domain Name Service (DNS) The X.500 Directory Service

27 Domain Name System (DNS) P. Mockapetris, K. Dunlap: “Development of the domain name system”, Proc. SIGCOMM’88 Symposium –Address/name translation DNS is used for looking up host address and mail servers –Hierarchical name space distributed database –Distributed set of servers –Replicated for reliability –The name space consists of set of labels (each of length 63 char) and the complete path name is 255 char

28 DNS Names A subtree within DNS is referred to as a “domain”. A path name is referred to as a “domain name”. These can be relative or absolute. A DNS server operates at each node (except those at the bottom). Here, the information is organised into “resource records”.

29 DNS Name Servers Why not have a central DNS server? single point of failure traffic volume may be far maintenance difficult Alternative no server has all name-to-IP address mappings

30 Resolver and name server 1.An application program on a host accesses the domain system through a DNS client, called the resolver 2.Resolver contacts DNS server, called name server 3.DNS server returns IP address to resolver which passes the IP address to application Reverse lookups are also possible, i.e., find the hostname given an IP address

31 Authoritative DNS Servers No server has all name-to-IP mappings –local name servers: Each institution/company/ ISP has a local (default) name server Host DNS query first tries the local name server –authoritative name server: For a host: stores that host’s IP address & name Can perform name/address translation

32 DNS name servers Note: Name server names are in italics, and the corresponding domains are in parentheses. Arrows denote name server entries a.root-servers.net (root) ns0.ja.net (ac.uk) dns0.dcs.qmw.ac.uk (dcs.qmw.ac.uk) alpha.qmw.ac.uk (qmw.ac.uk) dns0-doc.ic.ac.uk (ic.ac.uk) ns.purdue.edu (purdue.edu) uk purdue.edu ic.ac.uk qmw.ac.uk dcs.qmw.ac.uk *.qmw.ac.uk *.ic.ac.uk *.dcs.qmw.ac.uk *.purdue.edu ns1.nic.uk (uk) ac.uk co.uk yahoo.com

33 Composed naming domains used to access a resource from a UR http://www.cdk3.net:8888/WebExamples/earth.html URL Resource ID (IP number, port number, pathname) Network address 2:60:8c:2:b0:5a file Web server 55.55.55.55WebExamples/earth.html8888 DNS lookup Socket

34 URL example If the URL http://www.cdk3.net:8888/web_examples/earth.html is given to DNS and it looks up for it, so: http://www.cdk3.net:8888/web_examples/earth.html URL will be “55.55.55.55” +”8888”+”web_examples/earth.html” IP + port # + path name IP to get the server address Port# to get socket Trace the path name to get the file “earth.html” from the socket

35 DNS example: mail address Name Server Mail Transfer Agent TCP IP 139.91.157.50 User1@ics.forth.gr MX for ics.forth.gr ? User 139.91.157.50

36 DNS master file (hosts.txt) of host names & their IPs maintained by Network Information Center (NIC) distributed by email, or downloaded by FTP The global layer of DNS are:.com,.edu,.gov,.mil,.net,.org,.uk,.eg,… DNS is stored in files with set of records (internet database) as A, NS, ….

37 Domain Hierarchy Domain := context for defining/resolving names educomgovmilorgnetukgr ibmyahoo ieee uoc csd soc econ Crete

38 The DNS Name Space The most important types of resource records forming the contents of nodes in the DNS name space. Type of record Associated entity Description SOAZoneHolds information on the represented zone AHostContains an IP address of the host this node represents MXDomainRefers to a mail server to handle mail addressed to this node SRVDomainRefers to a server handling a specific service NSZoneRefers to a name server that implements the represented zone CNAMENodeSymbolic link with the primary name of the represented node PTRHostContains the canonical (Pointer) name of a host HINFOHostHolds information on the host ( Machine architecture & OS) TXTAny kindContains any entity-specific information considered useful

39 DNS Implementation An excerpt from the DNS database for the zone cs.vu.nl. The “database” is a small collection of files maintained within each DNS “zone”.

40 DNS records DNS: distributed db storing resource records (RR) oType=NS oname is domain (eg., foo.com) ovalue is hostname of authoritative name server for this domain o Eg: (foo.com, dns.foo.com, NS) RR format: (name, value, type, ttl) o Type=A o name is hostname o value is IP address o Eg: (relay1.bar.foo.com, 145.37.93.126, A) o Type=CNAME o name is alias name for some “canonical” (the real) name, eg., www.ibm.com is really servereast.backup2.ibm.com o value is canonical name o Type=MX o value is name of mailserver associated with name

41 DNS example (I) H ost sci.alexu.edu.eg wants IP address of gaia.cs.umass.edu 1. Contacts its local DNS server, dns.alexu.edu.eg 2. dns.alexu.edu.eg contacts root name server, if necessary 3. root name server contacts authoritative name server, dns.umass.edu, if necessary requesting host Sci.alexu.edu.eg gaia.cs.umass.edu root name server authoritative name server dns.umass.edu local name server dns.alexu.edu.eg 1 2 3 4 5 6

42 DNS example (II) Root name server: may not know authoritative name server may know intermediate name server: who to contact to find the authoritative name server requesting host sci.alexu.edu.eg local name server dns.alexu.edu.eg gaia.cs.umass.edu root name server 1 2 3 4 5 6 authoritative name server dns.cs.umass.edu intermediate name server dns.umass.edu 7 8

43 DNS example (III): Iterated queries recursive query: puts burden of name resolution on contacted name server heavy load? iterated query: contacted server replies with name of server to contact “I don’t know this name, but ask this server” requesting host Sci.alexu.edu.eg gaia.cs.umass.edu root name server local name server dns.alexu.edu.eg 1 2 3 4 5 6 authoritative name server dns.cs.umass.edu intermediate name server dns.umass.edu 7 8 iterated query

44 DNS Root Servers (I) Contacted by local name server that can not resolve a name Root name server: contacts authoritative name server if name mapping not known gets mapping returns mapping to local name server 13 root name servers worldwide {a, b, c, …, m}.root-servers.org Critical part of the Internet infrastructure !

45 DNS Root Servers (III) F: Internet Systems Consortium, Inc. Sites: Ottawa, Toronto San Jose, San Francisco, Los Angeles New York City Rome, Paris, Lisbon, Madrid, Munich Sao Paulo Beijing, Seoul, Taipei, Hong Kong, Singapore, Dubai Moscow Dubai Brisbane, Auckland Monterrey Johannesburg Tel Aviv Jakarta

46

47 Addresses of root servers A.ROOT-SERVERS.EDU. (formerly NS.INTERNIC.NET) 10.0.2.32 A.ROOT-SERVERS.NET. (formerly NS1.ISI.EDU) 198.41.0.4 B.ROOT-SERVERS.NET. (formerly C.PSI.NET) 128.9.0.107 C.ROOT-SERVERS.NET. (TERP.UMD.EDU) 192.33.4.12 D.ROOT-SERVERS.NET. (NS.NASA.GOV)128.8.10.90 E.ROOT-SERVERS.NET. (NS.ISC.ORG)192.203.23 F.ROOT-SERVERS.NET. (NS.NIC.DDN.MIL) 192.5.5.241 G.ROOT-SERVERS.NET. (AOS.ARL.ARMY.MIL) 192.112.36.4 H.ROOT-SERVERS.NET. (NIC.NORDU.NET)128.63.2.53 I.ROOT-SERVERS.NET. (at NSI (InterNIC))192.36.148.17 J.ROOT-SERVERS.NET. (operated by RIPE NCC) 198.41.0.10 K.ROOT-SERVERS.NET. (at ISI (IANA)) 193.0.14.129 L.ROOT-SERVERS.NET. (operated by WIDE, Japan)198.32.64 M.ROOT-SERVERS.NET. 202.12.27.33

48 DNS Implementation - BIND (I) Developed at Berkeley UDP-based –avoid the overhead of TCP connection 2 parts: –resolver handles the queries issued by applications “client” for up to 3 name servers –name server implements referrals, canonical name substitution, etc

49 DNS Implementation - BIND (II) Resolver: –Up to 3 names servers, in fixed ordered queried in sequence –Try 2nd server if 1st does not respond, try 3rd server if 2nd does not respond initial timeout: 1 sec timeout := 2*timeout, if none of the servers responds –A server is tried up to 4 times Max. #queries before giving up: 12 –The query ID is not changed upon retransmissions The resolver does not care which server responds … nor which query packet generated a response

50 DNS Implementation - BIND (III) Name server: –list of up to 16 addresses of name servers always sorted by the server’s expected response time –Cycle through list of servers, up to 3 times Initial timeout: 4 sec Max. timeout: 45 sec Timeout is doubled after each cycle A single query destined to an unreachable, unreplicated name server would lead up to 9 query datagrams –Up to 20 referrals protection against looping ! –… or up to 8 canonical name substitutions

51 Example: X.500 Naming Service A traditional naming service (like DNS) operates very much like the Telephone Directory. Find ‘B’, then find ‘Barry’, then find ‘Paul’, then get the number. With a directory service, the client can look for an entity based on a description of its properties instead of its full name. This is more like the Yellow Pages. Find ‘Perl Consultants’, obtain the list, search the list, find ‘Paul Barry’, then get the number.

52 X.500 principles Organizes directory entries into a hierarchical namespace Powerful search capabilities Often used for interfacing incompatible directory services Used DAP for client-server communication DAP (App. Layer) requires entire OSI stack to operate Too heavy for small environments

53 More on X.500 Directory entries in X.500 are roughly equivalent to domain names in DNS. The entries are organised as a series of “Attribute/Value Pairings” A collection of directory entries is referred to as a Directory Information Base (DIB).

54 The X.500 Name Space (1) A simple example of a X.500 directory entry using X.500 naming conventions. AttributeAbbr.Value CountryCEG LocalityLAlexandria OrganizationLAlexu Universiteit OrganizationalUnitOUMath. & Comp. Sc. CommonNameCNMain server Mail_Servers--130.37.24.6, 192.31.231,192.31.231.66 FTP_Server--130.37.21.11 WWW_Server--130.37.21.11

55 Tanenbaum & Van Steen, Distributed Systems: Principles and Paradigms, 2e, (c) 2007 Prentice-Hall, Inc. All rights reserved. 0-13-239227-5 Hierarchical Implementations: LDAP (2) Figure 5-23. (a) Part of a directory information tree.

56 56 Part of the X.500 Directory Information Tree (DIT) X.500 Service (root) Australia (country) India US A NSW (state) Vic (state) Govt Private Educational Monash UniMelb CSSE Medicine Staff Students Object class for NSW govt.

57 The X.500 Name Space (3) Two directory entries having Host_Name as RDN. AttributeValueAttributeValue CountryNLCountryNL LocalityAmsterdamLocalityAmsterdam OrganizationVrije UniversiteitOrganizationVrije Universiteit OrganizationalUnitMath. & Comp. Sc.OrganizationalUnit Math. & Comp. Sc. CommonNameMain serverCommonNameMain server Host_NamestarHost_Namezephyr Host_Address192.31.231.42Host_Address192.31.231.66

58 Naming versus Locating Entities a)Direct, single level mapping between names and addresses. b)T-level mapping using identities.

59 Mobile IP Traditional routing –based on IP destination address –network prefix determines physical subnet –change of physical subnet implies change of IP address (conform to new subnet), or special routing table entries to forward packets to new subnet Changing of IP address –DNS updates take to long time –TCP connections break –security problems Changing entries in routing tables –does not scale with the number of mobile hosts and frequent changes in the location –security problems Solution requirements –retain same IP address, use same layer-2 protocols –authentication of registration messages, …

60 Mobile IP routers Anchor point for communication with the mobile node A tunnel is established bet. the home agent & a reachable point for the mobile node. Association bet. Home IP & Care-of address


Download ppt "Distributed Systems Naming. Naming Names are used to share resources Name uniquely identify entities Names refer to location If we have named entity,"

Similar presentations


Ads by Google