DISTRIBUTED SYSTEM
CHAPTER 10 : CASE STUDY
LAB WORK SOLUTION- DISTRIBUTED SYSTEM
DISTRIBUTED SYSTEM -BCA -ALL SLIDES
MCQ- DISTRIBUTED SYSTEM

NAME SERVICES 

 

Name services play a crucial role in distributed systems by providing a means to identify, locate, and manage resources through human-readable names. They enable users and applications to interact with various resources without needing to know their physical locations or underlying addresses.

Functions of Name Services

  1. Name Resolution: Converting human-readable names into resource identifiers, such as IP addresses, object references, or service handles.
  2. Directory Services: Storing and providing additional information about resources, such as attributes, properties, and metadata.
  3. Name Management: Creating, deleting, and organizing names within a namespace, ensuring consistency and uniqueness.
  4. Scalability and Availability: Ensuring that the name service can handle a large number of queries and remain available despite network failures or high loads.
  5. Security: Providing mechanisms to ensure the integrity and authenticity of the name-to-resource mappings.

Types of Name Services

  1. Domain Name System (DNS):
    • Translates domain names to IP addresses.
    • Organized hierarchically, with top-level domains (e.g., .com, .org) and subdomains.
    • Provides various record types (A, AAAA, CNAME, MX, etc.).
  2. Lightweight Directory Access Protocol (LDAP):
    • Used for accessing and managing directory services over a network.
    • Stores hierarchical information about users, groups, devices, and other resources.
    • Commonly used for authentication and authorization in enterprise environments.
  3. Java Naming and Directory Interface (JNDI):
    • A Java API for accessing various naming and directory services.
    • Provides a unified interface to interact with different naming and directory services like DNS, LDAP, and RMI registries.
    • Allows Java applications to look up and bind objects, such as EJB components, data sources, and environment variables.
  4. Network Information Service (NIS):
    • Provides a distributed database for sharing configuration information within a network.
    • Commonly used in Unix and Linux environments to manage user and group information, hostnames, and other configuration data.

DOMAIN NAME SYSTEM (DNS)

DNS is a hierarchical and decentralized naming system for computers, services, or any resource connected to the Internet or a private network. It translates human-readable domain names (like www.ezexplanation.com) into IP addresses (like 192.0.2.1), which are used by computers to identify each other on the network.

Components of DNS

  1. Domain Names: Structured in a hierarchical manner, consisting of labels separated by dots (e.g., www.ezexplanation.com).
  2. DNS Zones: Segments of the DNS namespace that are managed by a particular organization or administrator.
  3. DNS Records: Data associated with domain names, including:
    • A Record: Maps a domain name to an IPv4 address.
    • AAAA Record: Maps a domain name to an IPv6 address.
    • CNAME Record: Maps a domain name to another domain name (canonical name).
    • MX Record: Specifies mail servers for email routing.
    • TXT Record: Contains text information, often used for verification and security purposes.

Working of DNS

Consider a scenario where an application needs to find the IP address of a web server using DNS:

  1. Query Initiation: The application sends a DNS query for www.ezexplanation.com to a DNS resolver.
  2. Recursive Resolution:
    • The resolver checks its cache for the IP address.
    • If not found, it queries a root DNS server.
    • The root server responds with the address of the TLD server for .com.
    • The resolver queries the .com TLD server, which responds with the authoritative DNS server for example.com.
    • The resolver queries the authoritative server, which returns the IP address for www.example.com.
  3. Response: The resolver caches the result and returns the IP address to the application.
  4. Connection: The application uses the IP address to establish a connection to the web server.

 

DNS Server Types

  1. Recursive Resolver: Receives queries from client machines and recursively queries other DNS servers to resolve the domain name.
  2. Root Name Server: The top-level DNS server that directs queries to appropriate TLD (Top-Level Domain) servers.
  3. TLD Name Server: Manages top-level domains (e.g., .com, .org) and directs queries to authoritative name servers.
  4. Authoritative Name Server: Contains the DNS records for specific domains and responds to queries with the definitive answers.

DNS Resolution Process

  1. Query Initiation: A user enters a domain name in their web browser.
  2. Recursive Query: The query is sent to a recursive resolver.
  3. Root Server Query: If the resolver does not have the cached answer, it queries a root name server.
  4. TLD Server Query: The root server responds with the address of a TLD server.
  5. Authoritative Server Query: The TLD server responds with the address of the authoritative name server for the requested domain.
  6. Final Resolution: The authoritative name server returns the IP address associated with the domain name.
  7. Response: The resolver sends the IP address back to the client, which then connects to the web server.

DNS Security

  • DNSSEC (DNS Security Extensions): Adds security to DNS by enabling DNS responses to be verified for authenticity.
  • TSIG (Transaction Signatures): Provides a way to secure updates and communications between DNS servers.
  • DNS Over HTTPS (DoH) and DNS Over TLS (DoT): Encrypt DNS queries to enhance privacy and security.