Cmu Cmidterm2005fallsoln

Embed Size (px)

Citation preview

  • 8/10/2019 Cmu Cmidterm2005fallsoln

    1/13

    Carnegie MellonComputer Science Department.

    15-441 Fall 2005Midterm

    Name:

    Andrew ID:

    INSTRUCTIONS :

    There are 13 pages (numbered at the bottom). Make sure you have all of them.

    Please write your name on this cover and at the top of each page in this booklet except the last.

    If you nd a question ambiguous, be sure to write down any assumptions you make.

    It is better to partially answer a question than to not attempt it at all.

    Be clear and concise. Limit your answers to the space provided.

    Question A B C D E FPoints / 42 / 30 / 9 / 18 / 9 / 2

  • 8/10/2019 Cmu Cmidterm2005fallsoln

    2/13

    A Multiple Choice (CIRCLE ALL CHOICES THAT APPLY)1. Which of the following is true about different unicast routing protocols:

    A. BGP prevents routing loops common in distance vector protocols by having routers informtheir neighbors about the path used for each of their routing table entries.

    B. The use of split-horizon and poison-reverse in a distance-vector protocol like RIP always pre-vents the count-to-innity problem when a network partition occurs.

    C. Link-state protocols do not suffer from the count-to-innity problem.D. BGP always uses the shortest path (in terms of router hops) between two nodes.

    Solution: Total: 6 pts

    (A)( 3 pts ) and (C)( 3 pts ) are correct answers

    (B)( -3 pts ) Split horizon and poison reverse x single hop loops, but multiple hop loops canstill remain.

    (D)( -3 pts ) BGP uses the shortest number of AS path hops, not router hops.

    2. A network C advertises the network number 192.3.124/22 (and no other numbers). What networknumbers (all 24 bits) could AS C own?

    A. 192.3.123B. 192.3.124C. 192.3.125D. 192.3.128E. 192.3.10F. 192.4.124

    Solution: Total: 6 pts

    (B)( 3 pts ) and (C)( 3 pts ) are correct answers

    -3 pts for each incorrect answer

    3. In a high-performance router, copies of the forwarding table are kept in:A. The switching fabric.B. The output ports.C. The input ports.

    D. High-performance routers dont use forwarding tables.

    Solution: Total: 6 pts

    (C)( 6 pts ) is the correct answer

    -6 pts for any incorrect answers

    Page 2

  • 8/10/2019 Cmu Cmidterm2005fallsoln

    3/13

    4. Suppose you have a client C, a local name server L, and authoritative name servers A root, A com, andA foo.com, where A x is the name server that knows about the name zone x (and A root is a root nameserver). C wants to lookup the address for www.foo.com. Assuming that all name servers initially havenothing in their cache, which of the following order of events is correct?

    A. C asks L, L asks A root, A root tells L to ask A com, L asks A com, A com tells L to askA foo.com, L asks A foo.com, A foo.com answers to L, L answers to C.

    B. C asks A root, A root tells C to ask A com, C asks A com, A com tells C to ask A foo.com,C asks A foo.com, A foo.com answers to C, C tells L the address.

    C. C asks L, L asks A root, A root asks A com, A com asks A foo.com, A foo.com answers to C.D. C asks L, L asks A foo.com, A foo.com answers to L, L answers to C.E. C asks L, L asks A root, A root tells L to ask A com, L asks A com, A com tells L to ask

    A foo.com, L asks A foo.com, A foo.com answers to C.

    Solution: Total: 6 pts

    (A)( 6 pts ) is the correct answer

    -6 pts for any incorrect answers

    5. Client C performs a lookup for ftp.foo.com immediately after the previous request. Assuming allrecords have long TTLs, which of the above order of events is correct?

    Solution: Total: 6 pts

    (D)( 6 pts ) is the correct answer - NS record for foo.com cached

    -6 pts for any incorrect answers

    Page 3

  • 8/10/2019 Cmu Cmidterm2005fallsoln

    4/13

    6. In the network depicted below, circle all of the paths that packets may take under valley free routingbetween a pair of clients.

    A. Client ISP X ISP Z ClientB. Client ISP X ISP B ISP Z ClientC. Client ISP Y ISP Z ISP X ClientD. Client ISP X ISP A ISP X ClientE. Client ISP D ISP Z ISP X Client

    Solution: Total: 6 pts

    (A)( 3 pts ) and (E) ( 3 pts ) are the correct answers.

    -3 pts for each incorrect answer

    7. Local DNS name servers...A. Cache resource records and never discard them.B. Must be congured with a list of root name servers.C. Never perform recursive queries on behalf of clients.

    D. Always contacts the root name servers as part of every lookup.

    Solution: Total: 6 pts

    (B)( 6 pts ) is the correct answer.

    -6 pts for any incorrect answers

    Page 4

  • 8/10/2019 Cmu Cmidterm2005fallsoln

    5/13

    B Short Answer

    8. Intel Architecture lab is evaluating a new wireless transmission scheme called Ultra-Wideband. One of the advantages of Ultra-Wideband is that it has an extremely wide bandwidth of 1.5GHz. You are askedby the engineers at Intel Architecture lab to nd the maximum channel capacity of this new wirelesstransmission scheme. What is Ultra-Widebands maximum theoretical channel capacity given that there

    is no noise in the channel? Please explain your answer.

    Solution: Total: 6 pts

    6pts because of you can amplitude encode an arbitrary set of symbols when there is nonoise. This is a direct result of Shannons theorem: C = B x log2 (1 + S/N) N = 0 C = .

    -2 pts for misapplying shannon.

    -4 pts for using nyquist instead of shannon.

    -4 pts for using nyquist instead of shannon and misusing it.

    9. An ex-441 student is designing a network link using the Ethernet MAC protocol. He/She decides thatthe minimum packet size should be 1000 bits, that at most 200 machines can be connected at a timeand that the transmission rate will be 100Mbps. Assuming that electrical signals travel at 2 x108 m/s,what should be the maximum wire length of the link? Please explain your answer.

    Solution: Total: 6 pts

    6pts RTT= transmission time = 1000 bits / 100 Mbps = 1 10 5 to ensure collision detection.So, 0.5 10 5 is the max one way delay. The max length of the link is delay signal speed= (0 .5 10 5 )sec (2 108 )m/sec = 1000 m.

    -1 pts for each calculation error

    -2 pts for using delay instead of RTT

    -4 pts for awed calculation

    -5 pts for badly awed calculation

    Page 5

  • 8/10/2019 Cmu Cmidterm2005fallsoln

    6/13

    10. Explain the difference between a repeater and an amplier.

    Solution: Total: 6 pts

    6pts The repeater is a digital device while the amplier is an analog one. The repeater

    regenerates the signal by evaluating the digital values and re-sending on the output. Theamplier multiplies the analog signal received (including noise) and sends out the result.

    11. Compare and contrast Manchester encoding with Non-Return to Zero Inverted encoding. Also, whatare the advantages and disadvantages of each encoding?

    Solution: Total: 6 pts

    6pts Manchester encoding provides better clock recovery and DC bias but requires a highersignal transition rate (2x worse) - get two of these for full credit.

    -3pts For each comparison point missed

    12. The largest IP router can hold 200,000 entries in its forwarding table while the largest Ethernet switchcan hold 1,000,000 entries in its forwarding table. Yet, a large IP network can support many more hoststhan a large Ethernet network. Why?

    Solution: Total: 6 pts

    6 pts Due to hierarchical addressing, IP routing entries can be aggregated effectively. As aresult, each entry corresponds to and address/prex collections of hosts. Ethernet addressesare factory assigned/static and table entries map to exactly on host each.

    -3 pts Vague answer.

    Page 6

  • 8/10/2019 Cmu Cmidterm2005fallsoln

    7/13

    C Communication Delays

    13. An intelligent group of super speedy ants decide to set up a point-to-point link between two ant holes,denoted hole A and hole B. Suppose the bandwidth of this link is 1000bps, or bread crumbs per second,(you can imagine that each ant holds a bread crumb, and they leave hole A at a rate of 1000 ants persecond).

    The distance from hole A to hole B is 100 meters, and the ants walk at a speed of 1 m/s.(a) Calculate the minimum RTT for the link, in seconds.

    Solution: Total: 2 pts

    2 pts Propagation delay = 100 m / 1 m/s = 100 s.Latency = Propagation + Transmit + Queue.Since there are no routers between the end points and we are only sending 1 bit, there isno Transmit and Queue delay. Since we need to send bits back, RTT = 2 x propagationdelay = 200 s.

    -1 pt minor error

    (b) Using the delay as half the RTT (i.e. just going from A to B, not going back), calculate the delayx bandwidth product for the link, in bread crumbs.

    Solution: Total: 2 pts

    2pts 100s x 1000bps = 100000b.

    -1 pt minor error

    (c) Supposed the queen ant in hole A sends a messenger ant to hole B to request 10,000 bread crumbs(remember, each ant holds exactly one bread crumb). Assume the 10,000 ants are ready to leavewhen the messenger arrives. What is the minimum amount of time that will elapse between whenthe messenger departed the queen and all 10,000 ants have arrived at hole A?

    Solution: Total: 5 pts

    5 pts First the messenger must get to B, which takes 1 propagation delay = 100 s. Second,the 10,000 ants must come back which takes 10,000 / 1000 bps + 1 prop delay = 110 s.So the total time is 210 seconds.

    -1 pt minor error

    Page 7

  • 8/10/2019 Cmu Cmidterm2005fallsoln

    8/13

    D A Bridged and Routed Network

    Above is a picture of a network with 2 bridges (B1 and B2) and 1 router (R2). Each interface is labeled withboth an IP address and an MAC address. Imagine that a host (SRC/H1) is sending a packet to anotherhost (DST/H2). Please answer the following questions about this gure:

    H2.mac

    SRC DST

    B1

    R2

    B2

    H1.ipH1.mac

    B1.ip

    B1b.mac

    B1.ipB1a.mac B1.ip

    B1c.mac

    R2a.ipR2a.mac

    R2b.ipR2b.mac

    R2c.ipR2c.mac

    B2.ipB2a.mac

    B2.ipB2b.mac

    H2.ip

    14. How many (datalink) networks are shown above?

    Solution: Total: 3 pts

    3pts 3 networks

    15. Just before the packet reaches bridge B1, what is its layer 2 destination?

    Solution: Total: 3 pts

    3pts R2a.mac

    16. When H1 sends out an ARP query, what is the reply to that query?

    Solution: Total: 3 pts

    3pts ARP reply says that R2a.mac == R2a.ip

    17. Just before the packet reaches bridge B2, what is its layer 2 source?

    Solution: Total: 3 pts

    3pts R2c.mac

    Page 8

  • 8/10/2019 Cmu Cmidterm2005fallsoln

    9/13

    18. Just after the packet leaves router R2, what is its layer 3 source?

    Solution: Total: 3 pts

    3pts H1.ip

    19. Does the entry B2a.mac appear in B1s forwarding table?

    Solution: Total: 3 pts

    3pts No

    Page 9

  • 8/10/2019 Cmu Cmidterm2005fallsoln

    10/13

  • 8/10/2019 Cmu Cmidterm2005fallsoln

    11/13

  • 8/10/2019 Cmu Cmidterm2005fallsoln

    12/13

    (this page deliberately left blank)

    Page 12

  • 8/10/2019 Cmu Cmidterm2005fallsoln

    13/13

    The End!F 2 Free Points for Tearing Off Page: Anonymous Feeback

    List one thing you liked about the class and would like to see more of or seecontinued (any topic - lectures, homework, projects, bboards, topics coveredor not covered, etc., etc.):

    List one thing you would like to have changed or have improved about theclass:

    Page 13