DC Ans Key
DC Ans Key
7. *Logical clock:* A mechanism to order events without physical clocks (e.g., Lamport
timestamps).
8. *Global state:* The collective state of processes and communication channels at a specific
time.
10.Response time : Response time refers to the duration it takes for a system to react to a given
input or request.
Part-B
11.a. Difference between message passing and shared memory process communication
1.Mobile Sysytem
### Steps
1. *Initiation:*
2. *Marker Receiving Rule:*- When a process receives a marker for the first time:
4. *Completion:*
13*b. Elucidate on the Total Causal Order in Distributed System with a Neat Diagram:*
In distributed systems, *causal ordering* ensures that related events are processed in the order of
their causality. The *Total Causal Order* extends this concept by guaranteeing that all events in
the system follow a single global order, ensuring that all processes see the events in the same
sequence.
- *Example:* Consider two processes P1 and P2. If P1 sends a message to P2 and this message
triggers a subsequent action, all processes in the system should see the initial event before the
triggered action.### Achieving Total Causal Order
consider two processes, P1 and P2, and three events: *a, **b, and **c*:### Diagram:
14. a. What are the four different types of ordering the messages?
In distributed systems, message ordering is crucial to maintain consistency and coordination
between processes. The four main types of message ordering are:
2. *Causal Ordering:* *
3. *Total Ordering:
Group communication refers to the mechanisms and protocols that allow multiple processes in a
distributed system to communicate efficiently and in coordination. There are several types of
group communication, each suited to different requirements and use cases:
1. *Unicast Communication:
2. *Broadcast Communication:*
3. *Multicast Communication:*
4. *Anycast Communication:*
### Steps:
1. *Requesting Critical Section:* - When a process wants to enter the critical section (CS), it
sends a request message (with a timestamp) to all other processes.
3. *Entering Critical Section:* - A process enters the CS when it has received replies from all
other processes.
4. *Releasing the Critical Section:* - After exiting the CS, the process sends all delayed replies
to pending requests.
2. *Requesting the Token:*- If a process wants to enter the critical section and does not have the
token, it broadcasts a request message to all other processes. It enters the CS when it receives the
token.
3. *Token Passing:* - When the process exits the critical section, it passes the token to the next
process that has requested it.
4. *Request Queue and Sequence Numbers:* - Each process maintains a queue of requests and a
sequence number for each process to track the order of requests.
Part C
16.*(a) Types of Failures in Distributed Systems:*
1. *Crash Failure*:
2. *Omission Failure*:
3. *Timing Failure*:.
4. *Response Failure*:
5. *Byzantine Failure*:
3. *Remote Procedure Call (RPC)*: Allows a program to execute a procedure on a remote server
as if it were local.
5. *Multicast*: Enables sending a message from one process to a selected group of processes.
6. *Broadcast*: Sends a message from one process to all other processes in the system.
The global state in distributed systems represents the combined states of all processes and
communication channels at a specific point. Due to the lack of global time, algorithms like the
*Chandy-Lamport snapshot* are used to capture a consistent global state, ensuring that
concurrent operations do not interfere. Capturing the global state is crucial for tasks like
deadlock detection, distributed debugging, and ensuring fault tolerance across distributed
systems.