Distributed Systems Unit 2
Distributed Systems Unit 2
UNIT II
Operating System Support- Introduction
🔹 What Is It About?
In a Distributed System (DS), multiple computers (nodes) work together to appear as a
single coherent system to the user. The Operating System (OS) plays a central role in
making this illusion of a unified system a reality.
The goal of OS support in DS is to manage resources, provide abstraction, and enable
communication and coordination between processes on different machines seamlessly.
Security and
Ensures secure access control and encrypted communications.
Authentication
Development
Simpler to develop and maintain Complex to develop and maintain
Complexity
Introduction:
In a Distributed System (DS), multiple autonomous computers are interconnected and work
together as a single coherent system. The Operating System (OS) layer is a crucial
component that provides the necessary support for communication, coordination, and
resource management across all nodes in the distributed environment.
Definition:
The Operating System layer in a Distributed System refers to the combination of local
operating systems, communication mechanisms, and middleware that together provide a
platform to manage distributed resources, processes, and services efficiently and
transparently.
Every node (computer) in the distributed system has its own hardware.
The distributed OS uses this hardware to run programs and store data.
(Each computer's
manager)
(The computers)
Security and
Provides secure access, data protection, and user verification.
Authentication
Introduction:
In a Distributed System (DS), multiple autonomous nodes share resources such as files,
memory, services, and devices across a network. Protection refers to the mechanisms that
control the access of programs, processes, or users to system resources, ensuring that only
authorized entities can access or modify data in the system.
Protection is essential to maintain data integrity, privacy, and system stability, especially
when users and resources are distributed over a network.
Definition:
Protection in distributed systems is the process of enforcing rules that define which user or
process is allowed to access, use, or modify specific resources across the distributed
environment.
It is implemented through a combination of hardware, operating system controls, and
security policies.
Objectives of Protection:
1. Controlled Access – Prevent unauthorized access to resources.
2. Data Integrity – Ensure data is not altered by unauthorized processes.
3. System Stability – Prevent one process from interfering with another.
4. Fault Isolation – Minimize the impact of failures caused by malicious or buggy
programs.
Protection Domains:
A protection domain is a collection of objects (resources like files, memory,
printers) and the access rights (like read, write, execute) associated with those
objects.
Domains define what a process can do within the system.
There are two types:
1. Static Domains – Defined at the time of process creation and do not change.
2. Dynamic Domains – Can be changed during process execution.
In this table:
User 1 can read File A, write to File B.
User 2 can read File A, and print using the printer.
Admin has full rights over everything.
Introduction:
In Distributed Systems (DS), computation is performed across multiple interconnected nodes.
The fundamental units of execution in such systems are processes and threads. They are
responsible for carrying out tasks such as managing communication, performing
computations, and accessing distributed resources. Understanding their behavior is crucial for
ensuring coordination, communication, and concurrency in distributed environments.
Definition:
A Process is an independent unit of execution with its own memory space, code, and
data.
A Thread is a lightweight unit of execution within a process. Multiple threads can
run in a single process and share the same memory space.
❖ Types:
User-level threads – Managed by user-level libraries.
Kernel-level threads – Managed by the operating system.
❖ Benefits:
Faster context switching than processes.
Shared address space makes inter-thread communication easy.
Efficient use of multiprocessor systems.
❖ Role in DS:
Used for handling multiple client requests simultaneously in servers.
Ideal for non-blocking I/O operations.
Common in multi-threaded servers, such as in web applications, file servers, and
database servers.
Comparison: Processes vs Threads
Feature Process Thread
Fault Isolation Strong (isolated failures) Weak (can crash entire process)
1. Introduction:
Distributed systems consist of multiple independent computers (nodes) connected via a
network. These nodes need to communicate and coordinate with each other to perform
distributed tasks.
Two key mechanisms that enable this cooperation are:
Communication – for data exchange between processes across machines.
Invocation – for remote execution of functions or methods on other systems.
These mechanisms ensure transparency, modularity, and fault isolation in distributed
environments.
🔹 2. Communication in Distributed Systems:
2.1 Definition:
Communication refers to sending and receiving data between processes running on different
machines. It is essential for synchronization, data sharing, and cooperation in a distributed
setup.
3.1 Definition:
Invocation is the process where a client process calls a procedure/method located on a
remote server machine, as though it were local.
It hides the network complexity and provides location transparency.
🔹 6. Role of Middleware:
Middleware abstracts the complexity of communication and invocation:
Examples: CORBA, Java RMI, gRPC, DCOM.
Provides:
o Naming services
o Security layers
o Error handling
o Transparent invocation APIs
🔹 7. Use Cases:
Use Case Communication Type
1. Introduction:
An Operating System (OS) in a Distributed System (DS) acts as a software layer that
manages resources across multiple, geographically dispersed computers, making them
appear as a single cohesive system to users.
The OS architecture in DS determines how resources are accessed, shared, scheduled, and
protected across different nodes. The architecture influences transparency, scalability, fault-
tolerance, and performance of the system.
1. Introduction
A Distributed File System (DFS) is a file system that allows files to be stored across
multiple machines and accessed as if they were stored locally. It provides a unified
interface for users to interact with files regardless of their physical location in the network.
The DFS plays a critical role in distributed systems by enabling transparent, consistent, and
scalable file access, thus supporting resource sharing and distributed computing.
2. Definition
A Distributed File System is a system that manages file storage and access across multiple
computers in a network, giving users and applications the illusion of a single centralized
file system.
5. Features of DFS
Feature Description
File Sharing Multiple users can access and share files concurrently.
Location
Files can be moved without affecting user access.
Independence
Network File System by Sun Microsystems. Provides remote access to files over a
NFS
network.
HDFS Hadoop Distributed File System, used for storing large data sets in big data systems.
7. Advantages of DFS
Facilitates centralized file management across multiple systems.
Provides location transparency and ease of access.
Enhances fault tolerance through file replication.
Supports concurrent access with proper consistency mechanisms.
Enables scalable and distributed storage solutions.
8. Challenges in DFS
Maintaining consistency across multiple replicas.
Ensuring security and authentication in a networked environment.
Handling failures gracefully and maintaining availability.
Managing data synchronization across distributed nodes.
Latency issues in accessing remote files compared to local ones.
1. Introduction
In a Distributed File System (DFS), the File Service Architecture defines how file services
are structured and how client applications interact with files stored across a network.
The architecture is designed to provide access transparency, efficient file sharing, and
reliable communication between clients and file servers in a distributed environment.
2. Definition
File Service Architecture refers to the logical structure and components used to deliver
file-related operations such as reading, writing, creating, deleting, and updating files in a
distributed file system.
The architecture separates logical file system functions from physical storage mechanisms,
promoting modularity and scalability.
🔹 2. Directory Service
➤ Description:
Maps human-readable file names to internal file identifiers used by the flat file
service.
Provides naming, grouping, and file organization features.
➤ Features:
Supports hierarchical file organization (folders/directories).
Resolves file names to file IDs.
➤ Example:
lookup("/user/shubh/notes.txt") → returns file ID
create("/user/shubh/newfile.txt")
🔹 3. Client Module
Provides user interface for performing file operations.
Translates user requests into calls to directory or flat file service.
May include caching mechanisms to improve performance.
Modular Design Different layers handle naming, data access, and storage independently.