Distributed Systems : Home exercises
Home exercise 1
Deadline Friday 8.11 at 23:55. To be returned through Moodle. Return a PDF document. Please, remember to state your name and student number clearly.
Task description
Read the article The Many Faces of Publish/Subcribe by Eugster et al. The publish/subscribe architecture it describes is at least partially implemented by many social network services today. No doubt, Facebook's (FB's) engineers have also had somebody to read the paper for them.
In each of the following tasks, compare FB with previous paradigms/services: IRC, e-mail, newsgroups, and blogs. You may swap a service for one
of your own if you wish.
- Does Facebook implement stronger variants of the three decouplings than earlier services? Give examples of each of the three, if any exist. You can use either the standard features implemented by FB or applications implemented by third parties.
- Does FB implement all three subscription schemes? How? Do any of the earlier services have equivalent schemes?
- In terms of functionality, what new properties has FB added, when compared with each of the earlier services? Could the properties have been implemented using combinations of the services?
In grading this exercise, points are based on the detail and wit of the analysis, not the amount of text produced. A well-written answer should show that the author has understood the concepts in the original article, and how they are reflected in real-world examples.
Home exercise 2
Deadline Friday 8.11 at 23:55. To be returned through Moodle. You need to include a document that gives the instructions on how to run your program and describes the execution process. The programming language is bash. Put all the files in an archive and name it yourlastname_DS13_HE2.xxx.
Let's make this clear, returns that are:
- late
- or written using something other than bash
- or do not have the above mentioned document
- or are not original individual work
will be failed.
Task description
This assignment follows roughly the same rules as the cat and mouse exercises in the second exercises session, but there are some twists so read this description carefully. To start with, the cats are better organized this time. Catty Cat has asked its urban cousin Jazzy Cat to come and help to chase the mouse. In similar vein, Catty brought Listy Cat and Cordy Cat to help to organize the hunt. This time the Catty and Jazzy will only attack the mouse together, which leaves the mouse no change to escape.
Write the following bash scripts:
mouse.sh The mouse
chase_cat.sh For Catty and Jazzy
listy.sh For Listy
cordy.sh For Cordy
The mouse starts by going to one of the ukko nodes and listens a port through nc. Then it is up to Cordy to dispatch Catty and Jazzy so that they search the ukkonodes one by one. Catty and Jazzy communicate to Cordy through Listy cat. Listy keeps an open socket through nc and writes the messages to a file called cmsg. Cordy reads the messages from the cmsg file. Cordy coordinates the search by sending Catty and Jazzy with ssh to the ukkonodes to search the mouse. Cordy gives the commands as command line parameter as follows:
S catname Search the ukkonode (e.g. ./chase_cat.sh S Jazzy)
A catname Attack the mouse on the ukkonode
Catty and Jazzy can send the following messages to Listy using nc:
F ukkoXXX catname Found the mouse on ukkoXXX (e.g. F ukko300 Catty),
N ukkoXXX catname No mouse on ukkoXXX,
G ukkoXXX catname Got the mouse
When a cat finds the mouse it will send the F message. Cordy will then make the other cat to search the same node. When Cordy knows that both cats have found the mouse it can give the Attack command to either of the cats. The cat attacks by sending the MEOW message to the mouse. When the mouse receives the MEOW message, it will send the SIGINT signal to the attacking cat (indicating it has been caught). The attacking cat will report back of a succesful attack with the G message.
Here are some constraints that you must apply:
- Select 10-20 ukkonodes to use and put them on a file called ukkonodes. Start the mouse process on one of them. The program must work so that it does not matter which of the selected nodes is chosen for the mouse.
- Cordy can handle one line from cmsg file per 3 seconds.
- Jazzy and Catty need 10 seconds to search one ukkonode.
- The attack can only happen after both Catty and Jazzy have found the mouse.
- The attack takes 5 seconds.
- The attacking cat will wait 10 seconds for the SIGINT signal.
- The mouse does not move.
- The port number used with the nc communication must specified in a file called nc_port_number, that is, the port number is read from that file when needed.
- The node where Listy (listy.sh) resides must be defined in a file called listy_location.
- Name all files as defined in this description.
You should be able to implement a working program. However, note that some parts are by nature fault-prone. Remember to comment your code. Have fun!
Home exercise 3
Deadline: 20 December 2013 at 23:55.
Pick and read three of these papers and write a short essay of each three. The following questions should guide you to a decent result, adding your own thoughts will better the result. Return all essays as one PDF document on Moodle.
What are the main contributions of the paper?
What are the main results of the paper?
What are the strong and weak points of the paper?
What new does the paper offer compared to the previous/related work?
In which ways does the paper relate to the things learnt during this course?
- Networking Named Content. V. Jacobson, et al. CoNEXT '09, 2009.
- CAP twelve years later: How the "rules" have changed. E. Brewer. Computer, vol. 45, no. 2, Feb., 2012.
- Understanding Network Failures in Data Centers: Measurement, Analysis, and Implications. P. Gill, N. Jain, and N. Nagappan. SIGCOMM 2011
- A First Look at Problems in the Cloud. T. Benson, S. Sahu, A. Akella, and A. Shaikh. HotCloud 2010.
- Characterization of Failures in an Operational IP Backbone Network. A. Markopoulou, G. Iannacone, S. Bhattacharyya, C. Chuah, Y. Ganjali, and C. Diot. Transactions on Networking 2008.
- Towards Understanding Modern Web Traffic. S. Ihm, and V. Pai. IMC 2011.
- Network Traffic Characteristics of Data Centers in the Wild. T. Benson, A. Akella, and D. Maltz. IMC 2010.
Home exercise 4
Deadline: 20 December 2013 at 23:55.
Background:
Read the article "Fault Tolerance by Design Diversity: Concepts and Experiments" by A. Avizienis & J. P. J. Kelly.
Task description:
Write an example program that consists of at least two objects. The first object A calls one or more methods of the second object B. B must
contain at least three faults: they will be intentionally introduced into the program code. A will be partially fault-tolerant.
One of the faults in B shall remain invisible to A. The second shall manifest as an error, but will be detected by A and handled (tolerated) by the method invocation. The third fault should be left unhandled by A and propagate as a failure to the user of A.
Requirements
In the program, each fault must be carefully documented, as well as the execution sequence that causes the faults to propagate as errors or failures.
The purpose of the exercise is to show that you have understood the threefold model of malfunctions presented in the article.
The program code must run on the Department's workstations. Please do NOT use the shell servers melkki, melkinkari, melkinpaasi, or alkokrunni for programming this task.
Write a document that describes what your program tries to achieve. Put all the files in an archive and name it yourlastname_DS13_HE4.xxx. Submission on Moodle.