Assignment #3 - IT 332 - Distributed Systems

screechingagendaΔίκτυα και Επικοινωνίες

26 Οκτ 2013 (πριν από 3 χρόνια και 9 μήνες)

137 εμφανίσεις

King Saud University

College of Computer and Information Sciences

Department of information technology



IT 332







1
st

semester 1432/1433


Assignment

#
3

Due date
:
Sunday,
16

October

2011




















Q1
-

In this proble
m you are to compare reading a fi
le using a single
-
threaded file
server and a multithreaded server. It takes 15 msec to get a request for work, dispatch
it, and do the rest of the necessary processing, assuming that the data needed are in a
cache in main memory. If a disk operation is nee
ded, as is the case one
-
third of the
time, an additional 75 msec is required, during which time the thread sleeps. How
many requests/sec can the server handle if it is single threaded? If it is multithreaded?


Q2
-

In the text
, we described a multithreaded

fi
le server, showing why it is better
than

a single
-
threaded server and a fi
nite
-
state machine server. Are there any
circumstances in which a single
-
threaded server might be better? Give an example.


Q3
-

Statically associating only a single thread with a

lightweight process is not such a good
idea. Why not?


Q4
-

Having only a single lightweight process per process is also not such a

good
idea. Why not?


Q5
-

Constructing a concurrent server by spawning a process has some advantages and
disadvantages comp
ared to multithreaded servers. Mention a few.


Q6
-

Is a server that maintains a TCP/IP connection to a client stateful or stateless?




IMPORTANT

RULES


-

Lab attendance is

a

MUST
.

-

You
should solve the assignments yourself.

-

Submission:

-

You should submit the Lab assignment
ONLY
.

-

W
rite your complete information:

N
ame, ID, Section number and
S
erial
number.

-

Assignments should be submitted
Sunday before 10:00 a.m.

in Room
# 814
,
Level 3,
Building 9
.

-

Late submissions will not be accepted
.

-

Evaluation:

a
student

will be chosen
randomly

and you'll be evaluated based on your
a
nswer
.


Q7
-

Imagine a Web server that maintains a table in which client IP addresses

are mapped to
the most recently accessed W
eb pages. When a client connects

to the server, the server looks
up the client in its table, and if found, returns the

registered page. Is this server stateful or
stateless?


Q8
-

Consider a process P that requires access to

fi
le F which is locally
available

on the
machine where P is currently running. When P moves to another

machine, it still requires
access to F. If the

file
-
to
-
machine binding is fi
xed
,

how could the systemwide reference to F
be implemented?


Lab Assignment


A distributed system is proposed for each group, each
group

has to submit two pages
document that describe the system arch
it
ecture

of their system

in which there is a
mapping of functionality onto hardware and software components, a mapping of the
software

architecture onto the hardware architecture, and human interaction with
these components.

Also you have to present your work in the lab (ten minutes for the
presentation and five minutes for
the
dissection).


-

List your
reference
s.


Section

Group #

Propose
d system

27418

1

Blackberry

Messenger

2

Span
-

Saudi Payment Network

3

Facebook

27422

1

Twitter

2

Sadad
-

Saudi Payment System

3

YouTube

4

Em
ail server ex. hotmail

5

W
ikipedia

6

flicker

7

eBay