You are on page 1of 3

Faculty of Engineering and Computing Sciences

Assignment as consider for CT-III Program:B.TECH(CSE)


Course Name: Distributed System Semester: 8 th
Course Code: ECS 805 Section: B
Faculty member: Manish Joshi Total Marks: 18
Submitted By- Ayush Jain (TCA1609030) Submission Date: 6-June-2020

UNIT-I

Ques: 1 Give some basic characteristics of distributed system.


Ans: Some characteristics of distributed system are:
1. Multiple autonomous components.
2. Components are not shared by all users.
3. Resource Sharing.
4. Software runs in concurrent processes on different processors.
5. Multiple points of control.
6. Multiple points of failure.
7. Communication is hidden from users (Transparency).
8. Application can interact with uniform and consistent way.
9. Security.
10. Fault Tolerance.

Ques: 2 What is liveness and fairness in distributed mutual exclusion? Give


the concept of Roucairol- Carvalho Algorithm for it.
Ans:
 Liveness Property: This property states the absence of deadlock and
starvation. Two or more sites should not endlessly wait for messages which
will never arrive.
 Fairness Property: Each process gets a fair chance to execute the CS.
Fairness property generally means the CS execution requests are executed
in the order of their arrival (time is determined by a logical clock) in the
system.

Concept of Roucairol- Carvalho Algorithm:


Roucairol- Carvalho Algorithm has avoided some unnecessary Request
and Reply messages in Ricart and Agrawala’s algorithm by using an implicit
no-Request message.
In this algorithm, if site X has not received a Request message from site Y
since site X executed the CS last time, it implies that site Y has given its
implicit permission to site X. Therefore, site X does not have to ask for
permission from such a site Y, and message traffic is reduced. To achieve this
, at each site , Boolean array A (with N entries) is dynamically updated such
that it records the identifiers of those sites which are not requesting the CS(i.e.
which have not sent request message to Site X since site X executed the CS
last time). The number of messages exchanged per CS execution in this
algorithm is between 0 and 2*(N-1).
UNIT-V

Ques: 3 Give some features of interface definition language (IDL).


Ans: Some features of Interface Definition Language are:
 It is used to set up communications between clients and servers in
remote procedure calls (RPC).
 It describe an interface in a language-independent way.
 It enables communication between software components that do not
share one language, for example, between those written in C++ and
those written in Java.
 IDL is a purely descriptive language
 The IDL specifies only the syntax used to define the data types and
interfaces in a way that is independent of the programming language.

Ques: 4 Give some examples of Traversal Algorithms and give the concept
of Cidon’s DFS Algorithm.
Ans: A traversal algorithm is an algorithm with the following three properties:
 In each computation there is one initiator, which starts the algorithm by
sending out exactly one message.
 A process, upon receipt of a message, either sends out one message or
decides.
 The algorithm terminates in the initiator and when this happens, each
process has sent a message at least once.

Some examples of traversal algorithm are:


1. Sequential Polling.
2. Classical Depth First Search.
3. Awerbuch’s DFS Algorithm.
4. Cidon’s DFS Algorithm.

Cidon’s DFS Algorithm:

 The token is forwarded immediately.


 The following situation is important:
 Process p has been visited by the token and has sent a <vis>
message to its neighbour r.
 The token reaches r before the <vis> message from p.
 In this case r may forward the token to p along a front edge.
 The situation is handled as follows:
 Process p records to which neighbor it most recently sent the
token – normally it expects to get it back from the same.
 If it gets it back from some other neighbor it ignores the token, but
marks the edge rp as used, as if it received a <vis> message from p.
 When r eventually receives the <vis> message from p it behaves as
if it never had sent the token to p.
 Cidon’s Algorithm computes a DFS tree in 2N-2 time units and uses 4.|E|
messages.

You might also like