0% found this document useful (0 votes)
15 views23 pages

Department of Artificial Intelligence & Data Science

Uploaded by

Kanmani K
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
15 views23 pages

Department of Artificial Intelligence & Data Science

Uploaded by

Kanmani K
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPT, PDF, TXT or read online on Scribd
You are on page 1/ 23

KGiSL Institute of Technology

(Approved by AICTE, New Delhi; Affiliated to Anna University, Chennai)


Recognized by UGC, Accredited by NBA (IT)
365, KGiSL Campus, Thudiyalur Road, Saravanampatti, Coimbatore – 641035.

Department of Artificial Intelligence & Data Science


Name of the Faculty : Dr. S. Kalpana/Ms.T.Suganya

Subject Name & Code : CS3551 / DISTRIBUTED COMPUTING

Branch & Department : B.Tech & AI&DS

Year & Semester : III / V

Academic Year :2024-25(ODD)


UNIT I INTRODUCTION 8
Introduction: Definition-Relation to Computer System Components – Motivation – Message - Passing Systems versus Shared
Memory Systems – Primitives for Distributed Communication – Synchronous versus Asynchronous Executions – Design Issues and
Challenges; A Model of Distributed Computations: A Distributed Program – A Model of Distributed Executions – Models of
Communication Networks – Global State of a Distributed System.

UNIT II LOGICAL TIME AND GLOBAL STATE 10


Logical Time: Physical Clock Synchronization: NTP – A Framework for a System of Logical Clocks – Scalar Time – Vector Time;
Message Ordering and Group Communication: Message Ordering Paradigms – Asynchronous Execution with Synchronous
Communication – Synchronous Program Order on Asynchronous System – Group Communication – Causal Order – Total Order;
Global State and Snapshot Recording Algorithms: Introduction – System Model and Definitions – Snapshot Algorithms for FIFO
Channels.

UNIT III DISTRIBUTED MUTEX AND DEADLOCK 10


Distributed Mutual exclusion Algorithms: Introduction – Preliminaries – Lamport’s algorithm – Ricart- Agrawala’s Algorithm –– Token-
Based Algorithms – Suzuki-Kasami’s Broadcast Algorithm; Deadlock Detection in Distributed Systems: Introduction – System Model
– Preliminaries – Models of Deadlocks – Chandy-Misra-Haas Algorithm for the AND model and OR Model.

UNIT IV CONSENSUS AND RECOVERY 10


Consensus and Agreement Algorithms: Problem Definition – Overview of Results – Agreement in a Failure-Free
System(Synchronous and Asynchronous) – Agreement in Synchronous Systems with Failures; Checkpointing and Rollback
Recovery: Introduction – Background and Definitions – Issues in Failure Recovery – Checkpoint-based Recovery – Coordinated
Checkpointing Algorithm - - Algorithm for Asynchronous Checkpointing and Recovery

UNIT V CLOUD COMPUTING 7


Definition of Cloud Computing – Characteristics of Cloud – Cloud Deployment Models – Cloud Service Models – Driving Factors and
Challenges of Cloud – Virtualization – Load Balancing – Scalability and Elasticity – Replication – Monitoring
SYLLABUS

UNIT II LOGICAL TIME AND GLOBAL STATE 10


Logical Time: Physical Clock Synchronization: NTP – A Framework for a System
of Logical Clocks – Scalar Time – Vector Time; Message Ordering and Group
Communication: Message Ordering Paradigms – Asynchronous Execution with
Synchronous Communication – Synchronous Program Order on Asynchronous
System – Group Communication – Causal Order – Total Order; Global State and
Snapshot Recording Algorithms: Introduction – System Model and Definitions –
Snapshot Algorithms for FIFO Channels.
Course Outcomes

OUTCOMES:
Upon the completion of this course, the student will be able to
CO1: Explain the foundations of distributed systems (K2)
CO2: Solve synchronization and state consistency problems (K3)
CO3 Use resource sharing techniques in distributed systems (K3)
CO4: Apply working model of consensus and reliability of distributed systems (K3)
CO5: Explain the fundamentals of cloud computing (K2)
LOGICAL TIME

 The concept of causality between events is


fundamental to the design and analysis of parallel
and distributed computing and operating systems.

 Usually causality is tracked using physical time.


However, in distributed systems, it is not possible to
have global physical time.

 The logical time in distributed systems is used to


maintain the consistent ordering of events.

 The knowledge of the causal precedence relation


among the events of processes helps solve a variety
of problems in distributed systems.
LOGICAL TIME

 Examples of some of these problems is as follows:

 Distributed algorithms design- Knowledge helps maintain consistency in replicated


databases, and helps design correct deadlock detection algorithms

 Tracking of dependent events- knowledge helps construct a consistent state for


resuming re-execution; in failure recovery, it helps build a checkpoint

 Knowledge about the progress- Knowledge helps measure the progress of


processes in the distributed computation. Useful in discarding obsolete information,
garbage collection, and termination detection.

 Concurrency measure – Knowledge is useful in measuring the amount of


concurrency in a computation. All events that are not causally related can be
executed concurrently
LOGICAL TIME
PHYSICAL CLOCK SYNCHRONIZATION: NTP
PHYSICAL CLOCK SYNCHRONIZATION: NTP

Motivation:
In centralized systems, there is only single clock. A process gets the time by simply
issuing a system call to the kernel.

In distributed systems, there is no global clock or common memory. Each processor
has its own internal clock and its own notion of time.

These clocks can easily drift seconds per day, accumulating significant errors over
time.

Also, because different clocks tick at different rates, they may not remain always
synchronized although they might be synchronized when they start.

This clearly poses serious problems to applications that depend on a synchronized


notion of time.
PHYSICAL CLOCK SYNCHRONIZATION: NTP

Motivation:
For most applications and algorithms that run in a distributed system, we need to know
time in one or more of the following contexts:
◮ The time of the day at which an event happened on a specific machine in the
network.
◮ The time interval between two events that happened on different machines in the
network.
◮ The relative ordering of events that happened on different machines in the
network.
Unless the clocks in each machine have a common notion of time, time-based queries
cannot be answered.
Clock synchronization has a significant effect on many problems like secure systems,
fault diagnosis and recovery, scheduled operations, database systems, and real-world
clock values.
PHYSICAL CLOCK SYNCHRONIZATION: NTP

Clock synchronization is the process of ensuring that physically


distributed processors have a common notion of time.

Due to different clocks rates, the clocks at various sites may diverge
with time and periodically a clock synchronization must be performed to
correct this clock skew in distributed systems.

Clocks are synchronized to an accurate real-time standard like UTC


(Universal Coordinated Time).

Clocks that must not only be synchronized with each other but also
have to adhere to physical time are termed physical clocks.
PHYSICAL CLOCK SYNCHRONIZATION: NTP
PHYSICAL CLOCK SYNCHRONIZATION: NTP

 Clock Skew – Relative Difference in clock values of Two Processes.

 Clock Drift – Relative Difference in clock frequencies (rates) of two processes.


PHYSICAL CLOCK SYNCHRONIZATION: NTP
PHYSICAL CLOCK SYNCHRONIZATION: NTP
PHYSICAL CLOCK SYNCHRONIZATION: NTP
PHYSICAL CLOCK SYNCHRONIZATION: NTP
PHYSICAL CLOCK SYNCHRONIZATION: NTP

 Network Time Protocol (NTP) is a protocol that helps the computers clock times to
be synchronized in a network. This protocol is an application protocol that is responsible
for the synchronization of hosts on a TCP/IP network.

 NTP servers have access to highly precise and atomic clocks GPU clocks.

 It uses Coordinated Universal Time (UTC) to synchronize CPU clock time.

 NTP uses a hierarchical system of time resources and provides synchronization within the stratum
servers.

 First, at the topmost level, there is highly accurate time resources’ ex. atomic or GPS clocks. These
clock resources are called stratum 0 servers, and they are linked to the below NTP server called
Stratum 1,2 or 3 and so on.

 These servers then provide the accurate date and time so that communicating hosts are synced to
each other.
PHYSICAL CLOCK SYNCHRONIZATION: NTP
PHYSICAL CLOCK SYNCHRONIZATION: NTP

 Network Time Protocol (NTP)

 The primary server at the root synchronizes with the UTC.


 The next level contains secondary servers, which act as a backup to the primary server.
 At the lowest level is the synchronization subnet which has the clients.
Clock offset and delay estimation:
 In practice, a source node cannot accurately estimate the local time on the target node due to
varying message or network delays between the nodes.
 This protocol employs a common practice of performing several trials and chooses the trial with
the minimum delay.
 Figure 3.6 shows how NTP timestamps are numbered and exchanged between peers A and B.
Let T1,T2,T3,T4 be the values of the four most recent timestamps as shown. Assume clocks A
and B are stable and running at the same speed.
PHYSICAL CLOCK SYNCHRONIZATION: NTP
PHYSICAL CLOCK SYNCHRONIZATION: NTP
PHYSICAL CLOCK SYNCHRONIZATION: NTP

You might also like