• Home
  • Textbooks
  • Distributed Systems: An Algorithmic Approach (Chapman & Hall/CRC Computer & Information Science Series)
  • Distributed Snapshot

Distributed Systems: An Algorithmic Approach (Chapman & Hall/CRC Computer & Information Science Series)

Sukumar Ghosh

Chapter 8

Distributed Snapshot - all with Video Answers

Educators


Chapter Questions

05:24

Problem 1

Prove that in a system with $\mathbf{N}$ processes, the Chandy-Lamport distributed snapshot algorithm will always show that $(\mathbf{N}-\mathbf{1})$ channels are empty. Also compute the message complexity when the algorithm runs on a strongly connected network of $\mathbf{N}$ processes and E channels.

Chris Trentman
Chris Trentman
Numerade Educator

Problem 2

Construct an example to show that Chandy-Lamport distributed snapshot algorithm does not work when the channels are not FIFO.

Check back soon!
11:39

Problem 3

In Figure 8.7, show all the consistent cuts that (a) include event d, (b) exclude event d but include event $\mathrm{g}$. FIGURE 8.7 Events in a system of three processes 0, 1, 2. (CAN'T COPY FIGURE)

Samuel Hannah
Samuel Hannah
Numerade Educator
03:17

Problem 4

Extend Chandy-Lamport algorithm so that it can be used on a network whose topology is a directed acyclic graph. Discuss any limitations of the extended version.

Chris Trentman
Chris Trentman
Numerade Educator

Problem 5

Assume that the physical clocks of all the processes are synchronized and channel propagation delays are known. Suggest an alternative algorithm for computing a distributed snapshot based on the physical clock and the channel delays.

Check back soon!
04:20

Problem 6

Sunrise Bank wants to find out its cash reserve, so it initiates an audit in all of its branches. At any moment, a sum of money may be in transit from one branch of the bank to another. ATM transactions, customer transactions through bank tellers, and inter-branch transactions are the only possible types of transactions.
Define two teller processes T1 and T2 at two different branches, and three ATM processes A1, A2, A3, each with a predefined amount of cash. Assume that four customers have an initial balance of a certain amount in their checking accounts. Each user can deposit money into, or withdraw money from their accounts through any ATM, or a teller. In addition, any customer can transfer an amount of available cash from her account to any other customer, some of which may lead to inter-branch transfers. Use Lai-Yang algorithm to conduct an audit of Sunrise bank. Allow the users to carry our transactions at arbitrary instant of time. The audit must reveal that at any moment total cash $=$ initial balance + credit - debit regardless of when and where users transact money.

Jennifer Stoner
Jennifer Stoner
Numerade Educator

Problem 7

While distributed snapshot is a mechanism for reading the global state of a system, there are occasions when the global state is to be reset to a new value. An example is a failure or a coordination loss in the system. As with the snapshot algorithms, we rule out the use of freezing the network. Explore if the Chandy-Lamport algorithm can be adapted for this purpose by replacing all reads by writes. Thus, when a process receives a marker, it will first reset its state, and then send out the marker in one indivisible action.

Check back soon!
01:09

Problem 8

You have been assigned to a project that measures how busy the Internet is. As a part of this project, you have to measure the maximum number of messages that are in transit at a time in the Internet. Assuming that all machines on the Internet and their system administrators agree to cooperate with you, suggest a plan for measurement.

AG
Ankit Gupta
Numerade Educator
05:42

Problem 9

In some busy cities, the directions of one-way traffic signs are reversed depending on the time of the day. During the morning rush hours, more streets are oriented towards the downtown, whereas in the evening rush hours, these streets are oriented away from the downtown. So, at some point of time, these changes have to be made. There are two constraints (i) blocking a road from traffic is not an option and (ii) the same street must not display conflicting signs at the two ends, as this will cause collisions or jams. Suggest an algorithm for changing the traffic directions. You can assume that the traffic light at each crossing is a process that can communicate with the traffic lights at the neighboring crossings.

Carson Merrill
Carson Merrill
Numerade Educator

Problem 10

The Chandy-Lamport only helps record fragments of the global state. In the next phase, these fragments have to be collected to form a meaningful global state. Instead of making it a two-phase process, explore the possibility of computing the global state of a distributed system in a single phase using a mobile agent. Assume that the topology is strongly connected, and the edges represent FIFO channels. The initiator will send out a mobile agent with a briefcase that will store its data. The briefcase has a variable $\mathbf{S}$ - it is an array of the local states of the various processes. Before the agent is launched, $\forall \mathbf{i}: \mathbf{S}[\mathbf{i}]=$ undefined. At the end, the agent will return to the initiator, and the $\mathbf{S}$ will represent a consistent global state.

Check back soon!