CS447_Spring2004_Mid..

advertisement
CS447 – Network and Data Communication
Midterm Exam No. 2 (SOLUTIONS)
Spring, 2004
4:30 – 5:45 P.M.
April 6, 2004
This exam is a closed-book and close note exam. There are 7 questions in this exam. You have 75
minutes to finish the 7 questions. Write your answers on separated pieces of papers. To avoid
grading problem, staple your papers in the ascending order in the question numbers. In this exam,
timing will be strictly enforced, and when exam is over, please do not write anything on your
paper. If you need to write anything after exam is over, you need to get permission from the
instructor.
Please do NOT open this exam until you are told you can.
Student ID (Last 6 Digits): ________________________
Notice 1: For each question in this exam, recommended time is specified. It is not necessary for
you to follow each recommendation, but it is advised that you pace yourself in such a way that
you do not spend too much time on a particular question. Recommended time implies the amount
of details you are expected to answer. For example, if 2 minutes are recommended, you are NOT
expected to write a long paragraph for your solution and what is expected is a brief (but correct)
answer (you may be able to answer even by correct keywords for such questions). Although
recommended time is specified, it is essentially your responsibility to pace yourself. Time may
not be enough for everyone, but an exam is fair if everyone is given the same amount of time and
the same questions.
Notice 2: The instructor will be willing to answer any question if there is anything wrong in the
questions. However, the instructor will NOT answer any question regarding the interpretation of
the questions. Understanding what a question is asking you is also a part of this exam and it is a
part of evaluation this exam is making.
I understand the above suggestion: ____ (please put a check mark if the above suggestion is
clear. Otherwise, ask the instructor for any question). If this is not clear, please do NOT start your
exam and ask your question to the instructor.
1
QUESTION #1 (10 minutes)
(1) What is a non-blocking switch (2 points) ?
A non-blocking switch is the one that can block only when the target output port is busy.
Note: The concept specified by the underline must be included in a correct solution
(expression could be different as long as the idea is present).
+2 points: if the concept is clearly present
+1 point: if the concept is tried but not very clear
+0 point: if the concept is not present properly
(2) Show where application-level protocols (HTTP, FTP, TELNET, POP, etc), TCP, UDP, IP and
network hardware are located in OSI 7-layer model (you can show your solution by drawing a
picture).
CS 447 Network and Data Communication
Phase 2
Application Layer
NFS
(Network File Server)
Presentation Layer
XDR
(External Data Rep.)
Session Layer
RPC
(Remote Proc. Call)
Transport Layer
Applicationlayer protocol
TCP
Network Layer
Datalink Layer
Telnet, FTP, SMTP, rlogin,
DNS, HTTP, rcp, finger, etc.
UDP
IP
ARP
RARP
Network Hardware
Phyisical Layer
CS447_Phase2/003
Socket
+2 points: if a solution is the same as shown above or quite similar
+1 point: if a solution is somewhat similar (but not quite)
+0 point: anything other than above
2
Transportlayer protocol
Networklayer protocol
(3) Show the procedure in CSMA.
CS 447 Networks and Data Communication
Contention-based MAC:
1. Listen to the shared transmission medium
2. If some station is transmitting data, go back to 1
3. Start transmission and start local timer
4. After transmitting data, wait for ACK
5. If ACK arrives before timer expires, it’s completed
6. Otherwise, go back to 1 and start it over again
This is called “Carrier Sense Multiple Access (CSMA)”
MAC/007
+2 points: if a solution is the same as shown above
+1 point: if a solution misses any activity (any one of the six actvities)
+0 point: anything other than above
(4) Somebody says, “Packet switching requires control and address bits to be added to each
packet. This introduces considerable overhead in packet switching. In circuit switching, a
transparent circuit is established. No extra bits are needed. Therefore, circuit switching will
be much faster to transmit data.” How do you think?
Not necessarily (disagree). Circuit switching may take longer time than datagram, which is a
packet switching data transmission for small data transmission because of the call set-up
delay in circuit switching.
(5) What are the three different types of switches used in a circuit switching network (you do NOT
have to describe them, just name the three)? Which one(s) could be non-blocking switches?
(a) Cross-bar switches
(b) TDM switches
(c) Bus switches
All of them could be a non-blocking switch.
QUESTION #2 (10 minutes)
Find the shortest distance to every other nodes using Dijkstra’s algorithm.
3
A
You are currently at node D and your task is to find the shortest distance
to all the other nodes in the network (right).

Show all your work. Credit will be given to a correct work
(show the procedure to find the shortest distances, as we
did in the classroom).
1
E
Links are connected only to nodes (i.e., two links
can not be connected without a node).
9
D
 Show the resulting shortest-path tree graph (in a
separate piece of paper).
B
6
3

2
1
2
2
5
G
2
F
A




8
8
B


7
7
7
7
C

9
9
7
7
7
E
3
3
3
3
3
3
F

5
5
5
5
5
G
5
5
5
5
5
5
CONNECTED
D, E
D, E, F
D, E, F, G
D, E, F, G, C
D, E, F, G, C,
D, E, F, F, C, A
Note: Different solutions are possible.
QUESTION #3 (10 minutes)
Suppose we are going to use a TDM switch (as shown in the picture below). In the statistical
TDM, there are 110 links connected (i.e., 110 input and output lines). The peak transmission rate
for each input line is 8.5Mbps (assume 1M = 106). Assume that utilization =100%. Five-byte
interleave is used for frame encoding. Ignore any other overhead.
Question: In order for this TDM switch to be a non-blocking switch, what is the minimum link
bandwidth (the shared link between the multiplexer and de-multiplexer) required for this TDM
switch?
Multiplexer
De-Multiplexer
Input Line #2
Output Line #2

Output Line #1

Input Line #1
Input Line #110
Output Line #110
?Mbps multiplexed shared link
Input lines, 8.5Mbps each
4
C
Solution:
First, calculate the total input rate. 110 lines × 8.5Mbps = 935Mbps.
Next, we need to find the header overhead. Since we have 110 input lines, we need:
Ceiling (log2(110)) = 7 bits
Since the payload size = 5 bytes (= 40bits), the frame size is 47bits.
Assuming that the required bandwidth in the multiplexed shared link is x bps, then the following
equation should hold:
935Mbps:x = 40:47
Solving the above equation, we will get:
x = 1098.625Mbps
QUESTION #4 (up to 7.5 minutes)
Complete the following table (*: how bandwidth will be assigned to a connection that uses one of
the three transmission methods):
Factors
Link Bandwidth
Shared?
Type of signal
transmission
Path-setup
Required?
Blocking?
How bandwidth will
be allocated? *
Any overhead
During transmission?
Circuit Switching
Datagram
Packet Switching
Virtual-Circuit
Packet Switching
No
Yes
Yes
Bit Stream
Packets
Packet
Yes
No
Yes
Yes
No
Yes
Static (Beginning)
Dynamic
Static
No
Yes
5
Yes
QUESTION #5 (12.5 minutes) For these questions, a long solution is NOT expected. If
know the correct idea, you answer could be very short.
(1) There are four combinations of virtual circuit and datagram packet switching for the external
and internal operations. Give example for each combination (as types of network).
(a) Virtual-circuit External + Virtual-circuit Internal: ISDN (Integrated Service Digital
Network)
(b) Virtual-circuit External + Datagram Internal: TCP
(c) Datagram External + Virtual-circuit Internal: None
(d) Datagram External + Datagram Internal: UDP
(2) What are the two Ethernet standards (those we discussed in the classroom, please)?
(a) IEEE 802.3
(b) Ethernet 2.0
(3) What is the significance in LAN compared to WAN and Internet?
It is a network that provides direct connectivity for host computers.
(4) Classify major MACs.
Centralized MAC
MAC
Token-Based MAC
Distributed MAC
Contention-Based MAC
(5) What is the essential difference between bridges and routers?
Bridges perform packet forwarding for two directly connected LAN segments, while routers
perform packet forwarding for networks (network domains) that are multiple-hops away.
(6) What are the types of routing in which routing table is not same for every node in a network?
Distributed Routing
(7) Which layer(s) in OSI 7-layer model belong to the external operations (name all that apply)?
Application, presentation, session and transport layers (the top four layers).
6
(8) What are the two types of “hub”? Describe the difference.
(a) Repeater Hub – multi-port repeater – packets will be broadcast, one transmission at a
time
(b) Switching Hub – multi-port bridge – packets will not be broadcast, multiple
transmissions at a time is possible
(9) What is an internet? Answer this question using up to five words (yes, you have read this
correctly, only up to 5 words). Any solution that contains more than five words is considered
wrong, even though the idea is correct.
A network of networks (4 words)
QUESTION #6 (up to 10 minutes)
Consider a simple telephone network consisting of two end offices and one intermediate switch
with a 3.2MHz full duplex trunk between each end office and the intermediate switch. Assume a
4KHz (1M = 1,000K) channel for each voice call. The average telephone is used to make twelve
calls per 8-hour workday, with a mean call duration of ten minutes. Five percent of the calls are
long distance (i.e., inter-office calls). What is the maximum number of telephones an end office
can support? All telephones in an end office are directly connected to a telephone switching hub
in an office (as shown in the figure below). Switching hubs and inter-office hub are never
bottleneck.
4KHz
4KHz

Solution:
Telephone
Hub
Switch
Office Location 1
Telephone
Hub

3.2MHz
3.2MHz
Office Location 2
First, the utilization for each telephone should be calculated. Since each telephone makes 12 calls
in eight hours, each of which lasts ten minutes, the average utilization for each telephone set is:
(12calls × 10minutes) / 8 hours = 120 minutes / 480minutes = 0.25 (= 25%)
Next, try to find out how many phone calls a 3.2MHz trunk can support. Since the bandwidth of
the trunk is 3.2MHz, dividing 3.2MHz by 4KHz (3200/4), we get 800. This means that a 3.2MHz
7
trunk can support up to 800 simultaneous connections (from 4KHz telephone sets). However,
since the average utilization of telephone is 25%, this trunk will support up to 800 × 4 = 3,200
channels.
Finally, try to identify the total number of telephones that can be supported in an end office from
the capacity of the trunk. We know the 3.2MHz inter-office trunk can support up to 3,200
telephones. This should be 5% of all the calls in an end office.
Assuming x to be the number of telephones that can be supported in an end office, we have the
following equation:
3,200:x = 0.05:1.00
Simplifying this equation, we will get:
x = (3,200 × 100)/5
Solving this equation for x, we have a solution:
x = 64,000 (up to 64,000 telephones can be supported in an end office)
QUESTION #7 (up to 10 minutes)
A datagram network allows routers to drop packets whenever they need to do. The probability of
a router to drop a packet is P (0.0 < P < 1.0, theoretically both 0.0 and 1.0 can be included, but
either one is not realistic, so they are excluded in this question). A sender and a receiver are
connected by a path that goes through three intermediate routers (thus there are four link = four
hops). Any router on the path could drop a packet at probability of P and there is no coordination
between the three routers for their packet drops.
Question: What is the average number of hops a packet makes per transmission?
Assumptions:
(1) If a packet is dropped at the first router after the sender, we count it “1” (one hop has been
made and then dropped).
(2) Packets can be dropped only at a router (but not either at the sender or the receiver).
Hint: We did something similar for one of the subjects covered in our first midterm exam.
8
Solution:
Sender
Router1
Router2
Router3
Receiver
Probability to reach:
P
(1-P)×P
(1-P)2×P

Number of hops made:
1
2
3
4
 = 1 – (P + (1-P)×P + (1-P)2×P)
The average number of hops made by a packet transmission is:
= (P × 1) + ((1-P) × P × 2) + ((1-P)2 × P × 3) + (1-(P + (1-P) × P + (1-P)2 × P )) × 4
__________________________________________________________________________
CS447 – Network and Data Communication, Midterm Exam #2, Spring 2004, April 6, 2004.
9
Download