Welcome to Scribd, the world's digital library. Read, publish, and share books and documents. See more
Standard view
Full view
of .
Look up keyword
Like this
0 of .
Results for:
No results containing your search query
P. 1


Ratings: (0)|Views: 181|Likes:
Published by Richi Richa

More info:

Published by: Richi Richa on Dec 13, 2012
Copyright:Attribution Non-commercial


Read on Scribd mobile: iPhone, iPad and Android.
download as DOCX, PDF, TXT or read online from Scribd
See more
See less





Advanced Operating Systems(Distributed Systems)
Assignment Set
1. What is a message passing system? Discuss the desirable features of a messagepassing system.ANS:-
Discuss the
implementation of RPC Mechanism in detail.ANS:-
In computer science, a remote procedure call (RPC) is an inter-process communication that allows a computer program tocause a subroutine or procedure to execute in another addressspace (commonly on another computer on a shared network)without the programmer explicitly coding the details for thisremote interaction. That is, the programmer writes essentiallythe same code whether the subroutine is local to the executingprogram, or remote. When the software in question usesobject-oriented principles, RPC is called remote invocation orremote method invocation.
Note that there are many different (often incompatible)technologies commonly used to accomplish this.
Message passing
An RPC is initiated by the client, which sends a requestmessage to a known remote server to execute a specifiedprocedure with supplied parameters. The remote server sendsa response to the client, and the application continues itsprocess. There are many variations and subtleties in variousimplementations, resulting in a variety of different(incompatible) RPC protocols. While the server is processingthe call, the client is blocked (it waits until the server hasfinished processing before resuming execution).
An important difference between remote procedure calls andlocal calls is that remote calls can fail because of unpredictablenetwork problems. Also, callers generally must deal with such
failures without knowing whether the remote procedure wasactually invoked. Idempotent procedures (those that have noadditional effects if called more than once) are easily handled,but enough difficulties remain that code to call remoteprocedures is often confined to carefully written low-levelsubsystems.
Sequence of events during a RPC
The client calls the Client stub. The call is a local procedurecall, with parameters pushed on to the stack in the normalway.
The client stub packs the parameters into a message andmakes a system call to send the message. Packing theparameters is called marshalling.
The kernel sends the message from the client machine tothe server machine.
The kernel passes the incoming packets to the server stub.
Finally, the server stub calls the server procedure. The replytraces the same steps in the reverse direction.
3. Discuss the following with respect to Distributed Shared Memory:a. Memory Coherence (Consistency) Modelsb. Memory Consistency modelsc. Implementing Sequential Consistencyd. Centralized
Server AlgorithmANS:-4. Explain the following with respect to Resource Management in Distributed Systems:a. Task assignment Approachb. Load
Balancing Approachc. Load
Sharing ApproachANS:-
A) Task assignment Approach
Each process is viewed as a collection of tasks. These tasks arescheduled to suitable processor to improve performance. Thisis not a widely used approach because:
It requires characteristics of all the processes to be known inadvance.
This approach does not take into consideration thedynamically changing state of the system.
In this approach, a process is considered to be composed of multiple tasks and the goal is to find an optimal assignmentpolicy for the tasks of an individual process. The following aretypical assumptions for the task assignment approach:
Minimize IPC cost (this problem can be modeled usingnetwork flow model)
Efficient resource utilization
Quick turnaround time
A high degree of parallelism
B) Approach Load
In this, the processes are distributed among nodes to equalizethe load among all nodes. The scheduling algorithms that usethis approach are known as Load Balancing or Load LevelingAlgorithms. These algorithms are based on the intuition that forbetter resource utilization, it is desirable for the load in adistributed system to be balanced evenly. This a load balancingalgorithm tries to balance the total system load bytransparently transferring the workload from heavily loadednodes to lightly loaded nodes in an attempt to ensure goodoverall performance relative to some specific metric of systemperformance.
We can have the following categories of load balancingalgorithms:
Static: Ignore the current state of the system. E.g. if a nodeis heavily loaded, it picks up a task randomly and transfers it toa random node. These algorithms are simpler to implement butperformance may not be good.

You're Reading a Free Preview

/*********** DO NOT ALTER ANYTHING BELOW THIS LINE ! ************/ var s_code=s.t();if(s_code)document.write(s_code)//-->