680 likes | 1.01k Views
GVHD: Sinh viên thực hiện : Phạm Trần Vũ 1- Nguyễn Thị Vân Anh 2- Lê Thị Hồng Hà 3- Vũ Thị Lộc Phương 4- Tăng Thu Hương 5- Huỳnh Thị Kim Trâm 6- Hồ Thị Kim Oanh. Outline. General concepts Domain Name System (DNS)
E N D
GVHD: Sinhviênthựchiện: PhạmTrầnVũ 1- NguyễnThịVânAnh 2- LêThịHồngHà 3- VũThịLộcPhương 4- Tăng Thu Hương 5- HuỳnhThị Kim Trâm 6- HồThị Kim Oanh
Outline • General concepts • Domain Name System (DNS) • Directory and Discovery Services • Introduction • Jini • Other name services • Global Name Service (GNS) • X500 Directory Service
Introduction • In a distributed system names are used to refer to a wide variety of resources such as computers, services, remote objects, and files as well as users. • Names are used for identification as well as for describing attributes. • For many purposes, names are preferable to identifiers • because the binding of the named resource to a physical location is deferred and can be changed • because they are more meaningful to users
URIs, URLs and URNs • Uniform Resource Identifiers (URI): identify or name a resource on the Internet. They come in two kinds: • Uniform Resource Locator (URL): locates resource - typed by the scheme field (http, ftp, nfs, etc.) - resources cannot be moved between domains • Uniform Resource Name (URN): names resource - Format: urn: <nameSpace>:<name-within namespace> - Examples: a) urn:ISBN:021-61918-0 b) urn:inf.unibz.it:TR2007-5
Examples of Name Services • File system – maps file name to file • RMI registry – binds remote objects to symbolic names • DNS (=Domain Name Service) – maps domain names to IP addresses – scalable, can handle change • X.500/LDAP directory service – maps person’s name to email address, phone number
Design Issues • Name spaces • Name Resolution • The domain name system
Name Spaces • A name space is a collection of all valid names recognized by a particular service • Allow simple but meaningful names to be used • Potentially infinite number of names • Structured • to allow similar subnames without clashes • to group related names
Hierarchic Name Spaces • Sequence of name tokens resolved in different context – syntax: name token (text string) + delimiter – DNS: inf.unibz.it – Unix: /usr/bin • Name structure reflects organisational structure • Examples – domainnames, Window file system
Flat Name Spaces • Single global context and naming authority for all names – computer serial number – Ethernet address – remote object reference (IP address, port, time, object number, interface id) • Names not meaningful – difficult to resolve (no tree hierarchy) – easy to create
Outline • General concepts • Domain Name System (DNS) • Directory and Discovery Services • Introduction • Jini • Other name services • Global Name Service (GNS) • X500 Directory Service
Namespace Hierarchy Ex: Retal.Sales.Ajax.com.
What is DNS ? • Domain Name System (DNS) is: • an application-layer protocol that is part of the standard TCP/IP protocol suite. • This protocol implements the DNS name service, which is the name service used on the Internet. • DNS is a distributednamingdatabase
What DNS used for? • The basic function of DNS: • Providing name-to-address resolution for TCP/IP-based networks. (mapping) • Others: • Mail Delivery • Get mail host for a domain • Reverse resolution • Get domain name from IP address • Host information • Type of hardware and OS • Well-known services • A list of well-known services offered by a host.
Get Address. • when a program is running on your local machine needs to contact a remote computer, mapping occur. • how to locate address? • requests assistance from the DNS software running on your local machine, which is considered a DNS client ( is call resolver). • sends a request to a DNS name server, which maintains the distributed DNS database: the host names, IP addresses, and other information about a particular group of computers
Domain Names • Fully-Qualified Domain Names
ZONES The data in a name server's database are called zone files. One type of zone file stores IP addresses and host names
DNS Administrative Domains: • Is a group of machines or resources that are administered as a unit. • Is maintained by at least two name servers. • Name servers have the graphical relations like business…
DNS Servers • in.named and DNS Name Servers : Name servers in an administrative domain maintain the DNS database. They run in.name( can be called BIND- University of California at Berkeley). • Primary server. • Secondary. • Cache-only.
DNS Resolver • Name Resolution Services • Standard Name Resolution. • Reverse Name Resolution. • Electronic Mail Resolution. ……
DNS Resolver Functions • Providing The User Interface. • Forming and Sending Queries. • Processing Responses.
DNS Resolver Functions • Other Functions: • Caching. • In fact, it is possible to set up a network so that the resolvers on each of the client machines do nothing more than hand resolution requests to a local DNS server and let the server take care of it. • The client resolver becomes a stub resolver. • Advantage of centralizing name resolution for the network. • Disadvantage of performance reduction.
DNS Basic Name Resolution Techniques: DNS Name Resolution Techniques: • Iterative Resolution • Recursive Resolution
DNS Name Resolution Efficiency Improvements: • Caching • Local Resolution
CACHING • The Motivation for Caching: Locality of Reference • spatial locality of reference: resource is more likely to be referenced if it is near another resource that was recently referenced. • temporal locality of reference: resource is more likely to be accessed if it was recently accessed. • Name Resolver Caching • once a particular name is resolved, it is cached and remains ready for the next time • this eliminates traffic and load on DNS servers.
Local Resolution • DNS servers will perform this check to see if they have the information needed for a request before commencing the “formal” top-down resolution process
DNS Message Header and Question Section Format • ID • QR • Opcode • AA • TC • RD • RA • Z • RCODE • QDCount • ANCount • NSCount • ARCount
DNS Message Resource Record Field Formats • DNS Common Resource Record Format • RData Field Formats For Common Resource Records • A / Address Resource Record (Type Value 1) • NS / Name Server Resource Record (Type Value 2) In this record, the data field carries the domain Carries the domain name of a name server • CName / Canonical Name Resource Record (Type Value 5) • SOA / Start Of Authority Resource Record (Type Value 6) • PTR / Pointer Resource Record (Type Value 12)
HOW ??? • DNS FREE • DNS SERVER ON UNIX
DNS FREE • EDITZONE
DNS SERVER ON UNIX • Installation • At a terminal prompt, enter the following command to install dns: • sudo apt-get install bind9 A very useful package for testing and troubleshooting DNS issues is the dnsutils package. To install dnsutils enter the following: • sudo apt-get install dnsutils
DNS configuration • Declare zones • Forward zone • Reverse zone • Describe zone’s database • Declare DNS client
Outline • General concepts • Domain Name System (DNS) • Directory and Discovery Services • Introduction • Jini • Other name services • Global Name Service (GNS) • X500 Directory Service
Directory and Discovery Services • Directory services • Discovery services • Jini case study
Directory services A special kind of naming service – Searching attributes Entries – Each entry is concerned with a set of <attribute, value> pairs Query – Lookup by known attributes – Return interested attributes – E.g. query one’s telephone No. by his name
Directory services • Sometimes directory services are called “yellow pages services”, while name services are called “white pages services” • Often organized in a hierarchy • Examples of directory services: 1. Microsoft’s Active Directory Services 2. X.500
Discovery services • A discovery service is a directory service that registers the services provided in a spontaneous networking environment. • Is automatically updated as the network configuration changes • Services notify the discovery service of existence via a registration interface • Discovery has a scope (the context)
Discovery services(tt) • Provide an interface for automatically registering and de-registering services, as well as an interface for clients to look up the services they require • Ex: a printer (or the service that manages it) may register its attributes with the discovery service as follows: • ‘resourceClass = printer, type=laser, color=yes, resolution=600dpi, location=room101, url=http://www.hotelNW.com/services/printer98’ • Example - Jini (a Java-based system for spontaneous networking)
Music service Alarm gateway service Internet Hotel wireless network Discovery service Camera TV/PC Guest's Laptop PDA devices Spontaneous network
Jini Discovery Service • Designed to be used for spontaneous networking • Entirely java-based • Computers communicate by means of RMI, and can download code if necessary • Discovery-related components in a Jini system are look up services • A Jini service (such as printing service) may be registered with many look up services
Jini Discovery Service(tt) • A lookup service – A service registers an object with a set of attributes – Clients query the lookup service – Clients download service object that matches query • Leases – A limited period of time during which the service can be used