Anda di halaman 1dari 6

DCS - sample questions with guidance for answers

Allquestions25marks

Q1
(i) The Router Information Protocol (RIP) for the dynamic determination of routes in a network is described as a distributed algorithm. What is RIP and what are the characteristics which make it distributed.

See Coulouris (2012) pp 114-118. An acceptable answer would be a description of the protocol (eg as given at bottem of p 116 or the pseudocode on p 117

(ii)

For the network diagram below derive routing tables which minimise the number of hops a packet must make in getting from each router to the other routers.

Figure1
A to A B C D link self 4 2 1 cost 0 1 1 1 to A B C D B link 4 self 3 4 cost 1 0 1 2 to A B C D C link 2 3 self 2 cost 1 1 0 2 to A B C D D link 1 1 1 self cost 1 2 2 0

(iii)

Show the sequence of changes to your routing tables that would occur (according to the RIP algorithm) if a link labelled 5 in Figure 1 is added between router C and router D.

On discovery of link 5 between C and D the routing tables for C and D would change to:

C to A B C D link 2 3 self 5 cost 1 1 0 1 to A B C D

D link 1 1 5 self cost 1 2 1 0

As the costs associated with paths using link 5 are lower for the path between C and D than current costs and the costs would be unchanged for all other paths, the RIP would result in: A to A B C D link self 4 2 1 cost 0 1 1 1 to A B B D B link 4 self 3 4 cost 1 0 1 2 to A B C D C link 2 3 self 5 cost 1 1 0 1 to A B C D D link 1 1 5 self cost 1 2 1 0

Q2
(i) Define time coupling, space coupling, synchronous and asynchronous. For each of a,b and c below describe and give examples of systems which are: a) time-coupled and space-coupled b) time-coupled and space-uncoupled c) time-uncoupled and space-uncoupled Synchronous communication paradigms are time-coupled, but are asynchronous communication paradigms always time-uncoupled? Explain your answer with examples.
Asynchronous paradigms are those where a process sends a message and continued with something else. Where the message does not need a reply this might be time-uncoupled. Many asynchronous systems, however, require replies or call -backs and the assumptionn is that all relevant processes are operating at the same time. Even in the case where a reply is not required for a particular process, the whole system is usually dependent, for timely, reliable responses, on all part of the system operating at the same time. Ie asynchronous does not imply time-uncoupled

See Coulouris (2012) pp 246-248.

(ii)

Using appropriate examples, discuss time and space coupling in the context of volatile environments. Why is direct communication generally advised against for volatile

environments. Assess the decision to stream to mobile phones in the light of this advice.
When change is anticipated both in terms of the availability of computers and the underlying network, such environments are described as volatile . Mobile computing is a good example of a highly volatile environment where users may connect and disconnect from the global network and may also experience periods of disconnection or weak connection because of location. Indirect communication is an appropriate strategy for such volatile environments for two key reasons: Firstly, with the potential for failure, it is useful to have a communication mechanism that does not communicate directly with a given recipient, rather indirectly through an intermediary, providing a level of freedom for the system to replace, update, replicate or migrate the intended receiver (space uncoupling). Secondly, with the potential for disconnection (of both sender and receiver), it is useful to have a communication mechanism that does not rely on both parties being available at the same time to communicate (time uncoupling). The decision to streaming is a direct method of communication - both parties need to be available for the communication to work. Streaming to mobiles then is risky in terms of quality of service.

Q3
(i) Critically compare three methods of indirect communication in distributed systems.
See Coulouris (2012) pp 248-291. Pick three methods and describe them briefly. Compare them, particuarly, with regards to the types of system for which they are appropriate, giving examples for each method you describe.

(ii)

Read the following scenario: FineDesign: FineDesignareasmalldesignandretailcompanythathaveanumberofsoftware packagesforproductdesign,forcontrollingfabricatingmachines.forproject management.forpurchasingrawmaterials,andfortakingordersandinvoicing customers.Theproductdesigntoolproducesinstructionsforthefabricatingmachine.It alsogeneratesestimatesofthematerialsrequiredforeachindividualproduct,which havetobeenteredbyhandintotheorderingpackage.Theorderingpackage communicateswithsuppliersviaaB2Becommercesiteandordersmaterialsatagreed prices.Itreportstheordersithasplacedandthepricespaidforthematerial.This informationisenteredintotheinvoicingsoftwareinordertocontributetothecalculation ofpricesforthefinishedproducts. Discuss the requirements for integrating the applications by allowing the packages to communicate with each other and propose a method for the integration.

The organisation appears to have a number of systems some of which communicate directly and some of which require human intervention to enable communication. The systems are: design - communicates directly with fabrication and via human intervention to ordering fabrication - communicates directly with design ordering - communicates directly with suppliers via e-commerce site and via human intervention with invoicing e-commerce - communicates directly with ordering invoicing - communicates via human intervention with ordering project management - appears not to be integrated with any other system This is a classic enterprise integration problem requiring the buffering or queuing of information between the systems in the enterprise. There are also likely to be the requirements for translation or re-formatting of data so that one system can read the (re-formatted) output of another. It would also be desirable to integrate the project management system with the other systems. The use of persistent data in the form of queues would allow any re-formatting to take place while the data is in the queues and allow the project management system to be linked to the queues with the por=tential of monitoring progress of designs, fabrications, orders and invoices.

Q4
(i) Distinguish between Thread-per-request, Thread-per-connection and Thread-per-object architectures for server threading.

See Coulouris (2012) pp 308-311. The diagrams in Figure 7.6 might be particularly useful here.

(ii)

Assuming a server response requires an average of 5 ms for its processing and 10 ms for uncached disc access. What is the maximum number of requests the server running a single thread can handle per second.

ave. processing time = 5 ms ave. disc access time = 10 ms ave. total service time = 15 ms Therefore 1000/15 = 66 requests per s

(iii)

Assuming caching adds an average of 0.5 ms to the processing time and the hit rate for cached access to the disc is 80%. How would caching affect the throughput of the server?

ave. processing time = 5.5 ms ave. cached access time = hitRate*cacheAccessTime + (1-hitRate)*discAccessTime for these purposes, cachAccessTime is negligible (call it 0) and hit rate is 80% (=0.8) ave. cached access time = 0 + 0.2*10 = 2 ms ave. total service time = 5.5 + 2 = 7.5 ms Therefore 1000/7.5 = 133 requests per s

(iv)

Calculate the effect of using two threads on a single processor. Would there be any improvement in performance if the two treads were run on separate processors?

Using two threads means that the cached disc access for one thread can be done while the other is processing Thus the average time for each request is is just the processing time for the request = 5.5 ms and the system can now handle 1000/5.5 = 181 requests per second. Running the threads on two processors means that two requests can be handled at the same time, therefore the ava processing time is 5.5/2 = 2.75 ms and the throughput is now 1000/2.75 = 363 requests per s

Q5
(i) What is a reflection or replay attack?
See Coulouris (2012) pp 480-486. Clearly, questions could be asked about other attacks.

(ii)

The following protocol is vulnerable to a reflection attack on Bob

Figure 2 A security protocol Show how the reflection attack can be achieved.
Mallory sends A, RM to Bob Bob responds with RB nd KAB(M) Mallory now starts a new session by sending A, RB Bob responds with RB2 and KAB(RB) Mallory replays to KAB(RB) Bob as his response to the first session

(iii)

Which principle of security is violated by this protocol? How might the protocol be modified to protect against such attacks?

The priciple vilated is the one which asserts that there should never be more information provided then is required to achieve the current action. All Bob needs to provide to test Alice is a challenge. Providing a reply to Alices challenge provides more information than is required. A safer protocol is:

Here there is only the required information in each exchange.

Q6
(i) Define transparency in the context of distributed computer systems. Using appropriate examples, describe five types of transparency.

See Coulouris (2012) pp 39-40

(ii)

Describe an aspect of distributed systems with which you are familiar and critically assess how it supports transparency.

The answer to this depends on your research. You have the opportunity to show wht you know about your researched topic in the context of your answer to part (i). Keep the anser focused on (in this case) transparency.

[Note: a similar question could be asked about security]

Anda mungkin juga menyukai