Fandom

Scratchpad

CSC645/745

216,258pages on
this wiki
Add New Page
Discuss this page0 Share

Ad blocker interference detected!


Wikia is a free-to-use site that makes money from advertising. We have a modified experience for viewers using ad blockers

Wikia is not accessible if you’ve made further modifications. Remove the custom ad blocker rule(s) and the page will load as expected.

Template:Murphy's 645/745 We're gona ACE this quiz and the rest of the quizzes! :p


Review #1

Question 1 - Define networking terms

1. Define the following terms: protocol, network, network structure, internetwork, network architecture, protocol hierarchy, layer, level-n protocol, level n-1 interface, physical medium, service primitives.

  • Protocol: A protocol defines the format and the order of messages exchanged between two or more communicating entities, as well as the actions taken on the transmission and/or receipt of a message or other event. It defines peer-to-peer communications.
  • Network: 1 distributed system where communications are connected, means to transfer messages (data) between components in a single distributed system
  • Network Structure: How components are physically connected. Example media: twisted pair wire, fiber optic cable, microwave channel. Two flavors: Point-to-point and multiple access
  • Internetwork: Take any networks of any sort and combine it to become bigger networks where routers are used to configure these networks. Means to transfer messages (data) between networks (i.e. between components in different distributed systems). A specific set of networks connected by routers that are configured to pass traffic among any computers attached to networks in the set. Most internets use TCP/IP protocols.
  • Network architecture: The design of a computer network. A set of layers and corresponding protocols
  • Protocol hierarchy: We have different layers on top of the physical media for the client and server that are connected via peer to peer protocols.
  • Layer: Well defined collection of functions. Run-time entities perform the functions defined by each layer.
  • Level-n protocol: Peer-to-peer communication on the same level n. Logical description of what peer is doing.
  • Level n-1 interface: Communication connection between level n and level n-1 protocol.
  • Physical medium: Physical material capable of holding data (i.e. wire, magnetic tape).
  • Service primitives: Communication operations that steps through a transfer of data.

Question 2 - point-to-point vs. multiple access

2. What is the difference between point-to-point and multiple access networks?

  • Point-to-Point Networks:
    • A collection of links that are connected by nodes.
    • Able to send a transmition (data) from links to links from the source to the destination
    • Developed in 1960s~1970s
    • OSI/ISO standards
    • Have dedicated links between pairs of components.
    • Types: star, ring, tree, complete, irregular (most common)-> Impossible to do math analysis. Least discussed
    • ISSUE: Network topology (which pairs of components have links)
  • Multiple access networks:
    • Single shared communication channel
    • Types: Satellite/radio, ethernet, token ring
    • Ethernet: more for LAN. 1 to aparnet and 1 connected to ethernet
    • ARPANET: connection out of the network in Europe
    • TCP/IP Protocols
    • ISSUE: Channel allocation (who's turn it is to use the media).

Question 3 - internetwork vs. network

3. How is an internetwork different from a network? Why are both necessary?

  • Internetwork
    • Consists of various kinds of networks but connected using a router.
    • Uses the TCP/IP
    • Not ISO protocols.
    • Last 10yrs are ISO compliants.
    • Means to transfer messages (data) between networks (i.e. between components in different distributed systems). A set of networks connected by routers that are configured to pass traffic among any computers attached to networks in the set. Most internets use TCP/IP protocols.
  • Network:
    • A single distributed system where communications are connected.
    • means to transfer messages (data) between components in a single distributed system


  • why both are necessary
    • An internetworks allows for communication between two or more networks that can be of different infrustructures. It also allows for LANs to become WANs.

Question 4 - level n-1 interfaces

4. Why don't network architectures specify the level n-1 interfaces?

The network architectures do not specify the level n-1 interfaces because these are not visible "outside" of the computer executing the protocol code.

Question 5 - communication between levels

5. Why isn't communication between peers on different levels allowed?

Communication isn't allowed between peers on different levels to avoid the mix up of code (spaghetti code). Make the programming for each level a much simplier task for the programmer and to allow each level to work more efficiently.

Each of the layer in the architecture have a peer-to-peer protocol to communicate with the same layer level. Each of this layers have APIs and interfaces that separates them. A change on a lower level of the network stack should not affect the APIs that are defined higher and thus does not need the developer to rewrite the calls to the APIs. The change should be seemless.



Quiz #1



Question 6 - purpose of the interface control information

6. What is the purpose of the interface control information (ICI) added by the level n entity. Does this information get delivered to the remote level-n peer?

Interface control infromation is control information added by a peer (service user) for the peer on the layer immediately below (service provider) and is removed by that peer.

This infromation does not get delivered to the remote level n peer but the level immediately below that.


Question 7 - purpose of the header information

7. What is the purpose of the header information added by the level n entity? Does this information get delivered to the remote level n peer?

The header contains control information added by the level n peer for the corresponding peer on the same peer on the same level.

The information does get delievered to the remote level n peer.


Question 8 - level N PDU and the level N+1 PDU

8. What is the relationship between the level N PDU and the level N+1 PDU?

  • PDU (Protocol Data Unit)
    • Message locally sent between 2 peers on the same level.
    • Consists of a header and a SDU (Service Data Unit).
  • SDU (Service Data Unit)
    • Message that is passed down the protocol stack via a service access point from an upper layer peer for delivery to a remote peer.


NPDU

Question 9 - Protocol

9. What is a protocol? How is it defined?

A protocol is defined by the format of messages exchanged and the legal exchange of sequences. It defines peer-to-peer communication, logical description of what the peer is doing.


Question 10 - 4 classes of service primitives

10. What are the four classes of service primitives?

  1. Request a service
  2. Indicate that request has arrived
  3. give Response to request
  4. Confirm that request arrived


Question 11 - service primitives and ISO/OSI standards

11. How are service primitives used in the ISO/OSI standards?

Upper layer (service user) asks for service and lower layer (service provider) provides service. Both are connected through a service access point.

ServicePrimitives


Question 12 - confirmed message delivery vs. unconfirmed message delivery

12. What is the difference between confirmed message delivery and unconfirmed message delivery?

  • Confirmed Message Delivery
    • Request + Indication + Response + Confirmation
  • Unconfirmed Message Delivery
    • Request + Indication


Question 13 - sequence of service primitives for delivery of confirmed message

13. Describe the sequence of service primitives used to implement delivery of a confirmed message.

A picture paints a thousand words ;)

ConfimedMsg


Question 14 - sequence of service primitives for delivery of unconfirmed message

14. Describe the sequence of service primitives used to implement delivery of an unconfirmed message.

Another 10,000 words ;)

UncofirmedMsg



Quiz #2



Question 15 - ISO/OSI Layers

15. What are the seven ISO/OSI layers? Give a one sentence description of each layer.

"All People Seem To Need Data Processing." :p remember that sentence.

  1. Physical Layer: Transmission of bits on a single link.
  2. Data Link Layer: Error free transmission of packets on a single link
  3. Network Layer: End-to-End transmission of packets
  4. Transport Layer: End-to-End delivery of messages flow control
  5. Session Layer: Setup and manage end-to-end conversation between users, provide enhance data transport and dialog control
  6. Presentation Layer: Control syntax and semantics of information transmitted
  7. Application Layer: High level user services as well as high level generic services

Question 16 - Physical Layer

16. Describe the major functions of the ISO/OSI physical layer.

  • Transmission of bits on a single link.
  • DTE-DCE Data Transfer.
  • Control Signal between devices.
  • Clocking signals: suncrhonize data flow and regulate bit rate.
  • Electrical Ground
  • Mechanical connectors (sockets and plugs).

Question 17 - Data Link Layer

17. Describe the major functions of the ISO/OSI data link layer.

Error free transmission of packets on a single link (flow control, line coordination).

Question 18 - Network Layer

18. Describe the major functions of the ISO/OSI network layer.

End-to-End transmission of packets (subnet control, routing, congestion control, accoounting, network interface/gateway).

Question 19 - Transport Layer

19. Describe the major functions of the ISO/OSI transport layer.

End-to-End delivery of messages (manage communication bit pipes between process) flow control.

Question 20 - Session Layer

20. Describe the major functions of the ISO/OSI session layer.

Setup and manage end-to-end conversation between users, provide enhance data transport and dialog control.

Question 21 - Presentation Layer

21. Describe the major functions of the ISO/OSI presentation layer.

Control syntax and semantics of information transmitted (formatting, compression, encryption).

Question 22 - Application Layer

22. Describe the major functions of the ISO/OSI application layer.

High level user services (virtual terminals, file transfer, email, etc) as well as high level generic services (remote operations, reliable delivery, etc).

Question 23 - TCP/IP Layers

23. What are the four (five) TCP/IP layers? Give a one sentence description of each layer.

  1. Hardware Layer: Physical bit transport
  2. Hardware Interface Layer: Transmit datagrams over specific network using physical address to identify hosts
  3. Transport Layer: Provide communication from one machine to another.
  4. User Services Layer: Provide communication between users (processes).
  5. Application Layer: Choose style of tranport and transfer data. Messages of streams of data are exchanged between peers

Question 24 - Hardware Layer

24. Describe the major functions of the TCP/IP hardware and hardware interface layers (0 and 1).

  • Layer 0: Physical bit transport
  • Layer 1: Transmit datagrams over a specific network using physical addresses to identify hosts.
  • Not Part of TCP/IP protocols

Question 25 - Transport Layer

25. Describe the major functions of the TCP/IP transport (IP) layer.

  • Provide communication from 1 machine to another.
  • IP datagrams are exchanged between peers.
    • IP (Internet Protocol): Datagram delivery service.
    • ICMP (Internet Control Message Protocol): Handle Error and control information.
    • ARP (Address Resolution Protocol): Translate IP addresses into physical addresses.
    • RARP (Reverse Address Resolution Protocol): Translate physical addresses into IP Addresses.

Question 26 - User Services Layer

26. Describe the major functions of the TCP/IP user services (TCP/UDP) layer.

  • Provide communication between users (processes).
  • Transport protocol packets are exchanged between peers.
    • TCP (Transfer Control Protocol) Layer
      • Reliable
      • Full-duplex
      • Stream connection between processes
      • Connection oriented.
    • UDP (User Datagram) Layer
      • Connectionless protocol between processes
      • Messages are not guranteed to arrive.

Question 27 - Application Layer

27. Describe the major functions of the TCP/IP application layer. Why is this layer usually not included as part of the TCP/IP protocol stack?

  • Choose style of transport and tranfer of data.
  • Messages or streams of data exchanged between peers (user application processes).


  • Why is the application layer not part of TCP/IP protocol stack?
    • The application layer is the top layer of the TCP/IP protocol ----I don't know :p

Question 28 - TCP/IP Layer Vs. ISO/OSI Layering

28. How is TCP/IP layering different from ISO/OSI layering?

  • TCP/IP
    • End-to-End Reliability
    • Locus of intelligent decision making
      • Hosts
    • Layering = Description of Functionality
  • ISO/OSI
    • Link level Reliability
    • Locus of intelligent decision making
      • Network IMP's
    • Layering = Blueprint for implementation

Question 29 - connectionless vs. connection-oriented service

29. What is the difference between connectionless and connection-oriented service?

  • Connectionless service
    • No logical connection established between peers before data exchange.
    • Message may arrive in any order (may not arrive at all).
    • Difficult to account for network resource utilization.
  • Connection-oriented service
    • Peer entities set up logical connection before data transfer.
    • During data transfer, all messages are delivered in order (usually guranteed to be delivered).

Question 30 - Define "-plex" terms

30. Define the following terms: full duplex, half duplex, simplex

  • Full duplex : Data transfer in both directions at the same time.
  • Half Duplex : Data transfer is both directions, but only 1 direction at a time.
  • Simplex : Data transfer in only 1 direction.

Question 31 - Protocols

31. Which protocols of TCP/IP are connectionless? Connection-oriented? Which layers of the ISO/OSI protocol are connectionless? Connection-oriented?

  • TCP/IP
    • Connectionless
      • Hardware (Layer 0) -- Service must be provided or emulated
      • Hardware Interface (Layer 1) -- Service must be provided or emulated
      • Layer 2 IP & Friends (ARP, ICMP, RARP)
      • Layer 3 UDP
    • Connection-Oriented
      • Layer 3 TCP


  • ISO/OSI Protocol Layers
    • Connectionless
      • MAC Layer
      • LLC Layer (Pass through MAC)
      • Transport Layer (Pass through MAC)
      • Session Layer
      • Presentation Layer
      • Application Layer
    • Connection-Oriented
      • Physical Layer
      • Data Link Layer
      • Network Layer
      • LLC Layer (Pass through MAC)
      • Transport Layer (Pass through MAC)


Review #2 - Physical & Mac Layers

Question 1 - major functions of physical layer

1. What are the major functions of the physical layer?

  • DTE-DCE Data Transfer
  • Control signals between devices
  • clocking signals: synchronize data flow & regulate bit rate
  • electical ground
  • mecanical connectors (sockets & plugs)

Question 2 - functionality of physical layer

2. How is the functionality of the physical layer defined?

  • The physical layer is connection-oriented and uses unconfirmed messages.

Question 3 - physical layer services

3. Are the physical layer services confirmed or unconfirmed? Explain your answer.

  • It is unconfirmed. There is only request and indication. No response or confirmation.

Question 4 - service primitives - data link layer

4. Describe the sequence of service primitives that the (data link) sender uses to transfer a sequence of packets. Describe the sequence of primitives that the (data link) receiver uses.

Answer: Since data link layer is connection oriented, we can conclude that both sender and receiver uses confirmed service i.e. request + indication + response + confirmation.

Question 5 - state changes of simplex - duplex communication

5. How are the state changes exhibited by the sender and receiver different for simplex and duplex communication?

With simplex, communication is one-directional. E.g. Television. That is, it goes one way and cannot come back to the original state. With duplex, you can return to the original state since the communication is bi-directional. Half Duplex e.g. Walkie talkie. Full Duplex e.g. Phone.

Question 6 - manchester encoding

6. Why is Manchester Encoding useful?

Manchester code is a form of data communication line code in which each bit of data is signified by at least 1 voltage level transition. It is used by the physical layer.

Machester encoding is useful because the signal synchronizes itself. This minimizes the error rate and optimizes reliability.

Question 7 - manchester encoding

7. Give the manchester encoding for the following bit string: 0000011111010101111

Machestercode


Supplementary Questions on Physical Layer

Question 1 - State Diagram

1. In the state diagram given in the class notes all legal state transitions are specified. If a state transition is not specified then it is not legal. Another way to represent this information is to have another state (the "error" state) with transitions labeled with each of the out-of-sequence primitives. Add this state to the state diagram.

Physicallayerstatediagram

Question 2 - State Diagram(Duplex)

2.The state diagram as given allows full duplex communication. Modify the state diagram from question 1 so that it only allows half-duplex communication. Modify the state diagram so that it only allows simplex communication (note: you will need one state diagram for the sender and another for the receiver).

This diagram applies for half-duplex for each of the arrow representing 1 directional communication happening only 1 at a time.


Sender

??


Receiver

??

Question 3 - Sequence of primitives

3.Which of the following sequences of primitives are legal? (Assume that one site is executing the sequence and that peer is initially in state 1.) Explain your answer clearly!

  • a. PH-Data.request
    • PH-Data.request
    • PH-Data.request

Illegal! It dies after PH-data.request


  • b. PH-Activate.request
    • PH-Activate.indication

Legal. It finishes up at state 3


  • c. PH-Activate.request
    • PH-Deactivate.request

Legal. It finishes at state 3


  • d.PH-Activate.indication
    • PH-Data.indication
    • PH-Data.indication
    • PH-Deactivate.indication

Legal. Ends at state 1.

Question 4 - Sequence of primitives

4.Given the following (legal) sequences of primitives, list the sequence of primitives that the corresponding peer will execute, assuming it is initially in state 1. What is the final state of both peers?

  • a. PH-activate.request
    • PH-data.request
    • PH-data.request
    • PH-deactivate.request

Ends at State 1 where both channels are inactive.

  • b. PH-activate.request
    • PH-activate.indication
    • PH-data.indication
    • PH-data.request
    • PH-deactivate.indication
    • PH-deactivate.request

Ends at State 1 where both channels are inactive.



QUIZ 3



Question 8 - mac layer service primitives

8. What are the service primitives supported by the MAC layer

  • connection activation
    • PH-activate.request
    • PH-activate.indication
  • data transfer
    • PH-data.request
    • PH-data.indication
  • connection de-activation
    • PH-deactivation.request
    • PH-deactivation.indication

Question 9 - 1 persistent"

9. What does "1 persistent" mean? Under what circumstances is this a reasonable policy to use?

1 persistent mean that a host transmit with probability of 1 (always) when the media is free.

It is reasonable when there is large bandwidth and many available resources.

Question 10 - CSMA/CD

10. Define CSMA/CD (explain all terms clearly)

  • CS: carrier sense
    • All hosts wait until the media is idle before transmitting.


  • MA: Multiple access
    • All hosts share the same media


  • CD: Collision Detection
    • As hosts transmit, then monitor the media for collisions (2 hosts transmitting at the same time). If collision is detected, host stops transmitting, sends a noise burst, then try again later.

Question 11 - random exponential backoff policy for collision resolution

11. Describe the random exponential backoff policy for collision resolution. What happens if the media is unable to deliver packets due to excessively heavy load (or a failure in the network interface)?

  1. With the first collision, wait 0-1 slot times.
  2. After second collision, wait 0-1-2-3 slot times.
  3. After ith collision, wait 0-1-...(2**i)-1 slot times until i=10
  4. Freeze maximum wait at 1023 slots until 16 collisions.
  5. After 16 collisions, return failure.

If the media is unable to deliver packets due to excessively heavy load, it returns a failure.

Question 12 - host sending message to another host

12. Explain in your own words what happens when a single host attempts to send a message to another host on an ethernet.

  • The sender host sends the message. All other hosts check the data that is transmitted. If the Checksum is incorrect, they discard the message. If it is ok, then they check if the destination address is correct, then they keep the message. If it is not correct, they discard the message.
  • If data in != data out, raise burst, try again later

Question 13 - ethernet transmission

13. Explain in your own words what happens if two ethernet hosts attempt to transmit at EXACTLY the same time.

If two hosts start speaking at the same time, both stop and wait for short, random periods of time (in Ethernet, this time is generally measured in microseconds). The hope is that by each choosing a random period of time, both hosts will not choose the same time to try to speak again, thus avoiding another collision. Exponentially increasing back-off times (determined using the truncated binary exponential backoff algorithm) are used when there is more than one failed attempt to transmit.

Question 14 - tau

14. What is tau? How is it used in designing the ethernet protocol?

The 19th letter of the Greek alphabet =P ;)

The maximum delay between hosts.

It is used to help hosts delay after collison

Question 15 - ethernet hosts

15. Explain in your own words what happens if two ethernet hosts attempt to transmit at an interval of slightly greater than two tau time units.

If a collision happens in time more than tau, then when the collision message comes back, it will not reach the sender host within 2tau. That means that the sender will think that the message got delivered correctly and will continue transmission.

                              tau
|------------------------------|---------->X
         |<--------------------------------
       2tau

Question 16 - min msg size ethernet hosts

16. How is the minimum message size determined in the ethernet protocol?

Each message require at least 2*tau time units for transmission (otherwise the collision detection mechanism might fail).

Question 17 - ethernet hosts

17. Why is it necessary to fix the maximum message size in the ethernet protocol?

  • Signal gets degraded with distance
  • Timing issues
  • Depends on medium used

Question 18 - ethernet error

18. How does the ethernet hardware detect errors in transmission?

  • If data in != data out, raise burst and try again later.
  • Check CRC. If jumbled throw away. If ok, check dest same as controller and if same keep, otherwise throw away.
  • Detect that a collision has occured.

Question 19 - ethernet hosts

19. Why are ethernets generally considered to be unsecure media?

Because even if data is encrypted, we can still see who is communicating with whom.

Question 20 - ethernet, real time application

20. Is ethernet technology appropriate for real time applications? Explain your answer clearly.

No because the wait to communicate with other hosts will be too long for the user.

Question 21 - ethernet parts

21. How does the system programmer access the Ethernet? What parts of the Ethernet protocol are visible to the programmer?

The programmer communicates with the controller that is installed on the computer. The application, Transport, and Network layers are available to the programmer.

Question 22 - ethernet frame

22. Describe the fields in an Ethernet frame.


| MAC Header (Source Address (6 bytes), Dest Address (6 bytes), EtherType (2 bytes)) | Data (Payload (46-1500)) | CRC Checksum (4 bytes) |


Examples of EtherType: 0x0800 Internet Protocol, Version 4 (IPv4), 0x0806 Address Resolution Protocol (ARP), 0x8035 Reverse Address Resolution Protocol (RARP), 0x809b AppleTalk (Ethertalk), 0x80f3 AppleTalk Address Resolution Protocol (AARP)

Question 23 - ethernet hosts

23. How does thin wire ethernet differ from standard ethernet?

  • Uses coaxial cable
  • Requires Transceivers using BNC T-Connector
  • Requires Terminators
  • Have to be very careful that all T-connectors have cables and terminators are installed

Question 24 - ethernet wire

24. How are connections made to a thin wire ethernet? Is this more or less difficult than connecting taps/T-junctions to a standard ethernet?

More difficult - Requires terminators + Have to have cables on both ends of T-junction.

Question 25 - ethernet 10base-T

25. What is 10base-T ethernet?

  • Twisted Pair Ethernet.
  • Used with RJ-45 connectors in star topology (all computers connect to a central computer).
  • 10Mbps
  • Uses baseband connection
  • 100 meters

Question 26 - ethernet and local networks

26. What are some examples of networking technologies OTHER than ethernet that have been used to build local networks?

  • Token Ring
  • Fiber Distributed Data Interface (FDDI)
  • Asynchronous Transfer Mode (ATM)
  • Others

Question 27 - ethernet hosts

27. How does gigabit ethernet technology differ from slower ethernet variants?

  • Minimum carrier time and Ethernet slot time have been extended from 64 byts to 512 bytes (minimum packet size is still 64 bytes, small packets use carrier extension).
  • Packet bursting allows servers, switches and other devices to send bursts of small packets



Review # 3 -- Windowing Protocols

Question 1- Data Link Mechanism

1. What are the two mechanisms used by the data link layer for error detection?

CRC (Checksum) & Sequence Number.

Question 2- Error Recovery

2. How is windowing used for error recovery?

It buffers the packets that have been send out from the sender to receiver and receiver to sender. The sender advances the BOT (Bottom of the Window) when an ACK corresponding to the packet in the window arrives, sliding the window over.

Question 3- ABP

3. Describe the alternating bit windowing protocol. Explain how messages are sent with and without errors occurring.

  • Number packets: 0-1-0-1
  • Sender sends a packet, then waits for an ACK from the receiver before sending the next packet (or possibly resending the current one). If timer expires before the ACK arrives, the last packet is retransmitted.
  • If jumbled bits received by sender (jumbled ACK) then resend the last packet. If jumbled bits received by receiver (jumbled original packet), receiver re-requests the same packet.

Question 4- ABP Sender

4. Write very high level pseudocode for the alternating bit protocol sender.

  • Initialize SN = 0
  • Send first packet
  • for (;;) {
    • receive ack
    • if (ackno == SN) {resend packet; continue}
    • if (no-more-data-to-send) return;
    • set SN = ackno
    • send next packet
  • } on timeout, resend packet

Question 5- ABP Receiver

5. Write very high level pseudocode for the alternating bit protocol receiver.

  • Initialize RN = 0;
  • for (;;) {
  • receive packet //(if checksum is ok then process. else retransmit)
    • if(seqno == RN) {
      • pass data up
      • set RN = (RN + 1)%2
    • } send ackno = RN
  • }

Question 6- GBP Protocol

6. Describe the go-back-n protocol. Explain how messages are sent with and without errors occurring.

  • Sender transmits an entire window of W pacekts at the same time, receiver only accepts the next packet expected.
  • Number packets 0, 1, 2, ..., W, 0, 1, ... (i.e. +1 mod W+1). Note that there are W+1 different sequence numbres.
  • Receiver is identical to Stop and Wait receiver (except for sequence numbers)
  • Sender tramsits up to W unacknowledged packets (and buffers them until they are acknowledged)
  • Sender advances the bottom of the window when an ack corresponding to a packet in the window arrives

(indicating that all packets up to the sequence numbrer in the ack have safely arrived). When the bottom of the window advances, more packets can be sent at the top of the window.

  • On sender timeout, retransmit some packets in the widnow. Typically all packets in the widnow are retransmitted in order.
  • If jumbled bits received by sender (jumbled ACK) then resend the packet at the BOT. If jumbled bits received by receiver (jumbled original packet), receiver re-requests the same packet.

Question 7- GBP Sender

7. Write very high level pseudocode for the go-back-n protocol sender.


  • Initalize BOT = 0;
  • send first window of W packets
  • for (;;) {
    • receive ack
    • if (ackno not the current window) continue;
    • if (ackno == BOT) {resend window, continue}
    • if (no-more-data-to-send) {
      • if (all ack's received) return
      • send BOT = ackno, continue
    • } set BOT = ackno; continue
    • send any packet new packet at top of window
  • } on timeout, resend window

Question 8- GBP Receiver

8. Write very high level pseudocode for the go-back-n protocol receiver.

  • initialize RN = 0;
  • for (;;) {
    • receive packet
    • if (seqno == RN) {
      • pass data up
      • set RN = (RN + 1) % W+1
    • } send ackno = RN
  • }

Question 9- SRP Protocol

9. Describe the selective repeat protocol. Explain how messages are sent with and without errors occurring.

  • Sender tramsits an entire window of W packets at the same time, Receiver buffers up to W out of order packets
  • Number packets 0, 1, 2, ... , 2W-1,0,1,... (i.e. +1 mod 2W). Note that there are 2W different sequence numbers!
  • Sender is dentical to go-back-n sender (except for sequence numbers)
  • Receiver buffers up to W packets --i.e. pacekts between BOT and (BOT + (W-1)) % (2W). BOT is the sequence number of the first missing packet and is the bottom of the receiver window.
  • When one or more packets at the bottom of the window have been correctly received, they are packet up and BOT is set to the first missing packet.
  • Receiver sends ack's as in the other sliding window protocols, using BOT as the ack number. Information about which packets are currently buffered may also be send with each ack.
  • If jumbled bits received by sender (jumbled ACK) then resend the packet at BOT. If jumbled bits received by receiver (jumbled original packet), receiver re-requests the packet at BOT.

Question 10- SRP Sender

10. Write very high level pseudocode for the selective repeat protocol sender.

Same as GBN.

Question 11- SRP Receiver

11. Write very high level pseudocode for the selective repeat protocol receiver.

  • initialize BOT = 0;
  • for (;;) {
    • receive packet
    • if (packet is in window) store in receiver buffer
    • if (bottom of window is full) {
      • pass packets up in order
      • set BOT to sequence number of first missing packet
    • }
    • send ackno = BOT
  • }

Question 12- ABP missing Packets

12. Describe how the alternating bit protocol handles missing packets and acknowledgements. Can this protocol send duplicate packets or acknowledgements?

  • On timeout, sender resends the last packet.
  • If jumbled bits received by sender (jumbled ACK) then resend the last packet. If jumbled bits received by receiver (jumbled original packet), receiver re-requests the same packet.
  • No to both (?)

Question 13- GBP missing Packets

13. Describe how the go-back-n protocol handles missing packets and acknowledgements. Can this protocol send duplicate packets or acknowledgements?

  • On timeout, sender resends the packet at BOT.
  • If jumbled bits received by sender (jumbled ACK) then resend the packet at BOT. If jumbled bits received by receiver (jumbled original packet), receiver re-requests the packet at BOT.
  • We can have duplicate acknowledgements, but not duplicate packets sent from sender at the same window transmission.

Question 14- SRP missing Packets

14. Describe how the selective repeat protocol handles missing packets and acknowledgements. Can this protocol send duplicate packets or acknowledgements?

  • On timeout, sender resends the packet at BOT.
  • If jumbled bits received by sender (jumbled ACK) then resend the packet at BOT. If jumbled bits received by receiver (jumbled original packet), receiver re-requests the packet at BOT.
  • No to both (?)

Question 15- ABP buffer space

15. How much buffer space is required for the alternating bit protocol?

2 for sender, 2 for receiver(, same for full duplex) Answer = 4

Question 16- GBP buffer space

16. How much buffer space is required for the go-back-n protocol?

Sender=W+1, Receiver=2+1 (full duplex=2W+2) Answer = W+4 (?)

Question 17- SRP buffer space

17. How much buffer space is required for the selective repeat protocol?

Sender=W+1, Receiver=W+1(, full duplex =2W+2)

Answer=2W+2 (?)

Question 18- Piggybacking

18. What is piggybacking? Why is it useful?

Piggybacking is used with full duplex communication to send with acknowledgment tbe next data packet going in the right direction, and waits a limited amount of time if no data packets are ready to go.

It is useful because it improves the efficiency in which data gets transmitted.

Question 19- Positive Acknowledgement

19. What is a positive acknowledgement? How is it used?

the receiver explicitly notifies the sender which packets, messages, or segments were received correctly which may implicitly inform the sender which packets were not received even though they were sent and thus may need to be retransmitted.

Question 20- Negative Acknowledgement

20. What is a negative acknowledgement? How is it used?

The receiver explicitly notifies the sender which packets, messages, or segments were received incorrectly and thus may need to be retransmitted.

Question 21- Cummulative Acknowledgement

21. What is a cumulative acknowledgement? How is it used?

The receiver acknowledges that it correctly received a packet, message, or segment in a stream which implicitly informs the sender that the previous packets were received correctly. TCP uses cumulative acknowledgement with its TCP sliding window

Question 22- ISO support

22. Why does ISO support BOTH the standard physical/data link protocols and the MAC protocol suite?





QUIZ #4


Review #4: Internetworking and Addressing, Network Layer

Question 1 - Internet

1. What are the major functions provided by the internet?

  • To hide underlying network architecture.
  • Provide access to all networks (without direct connections).
  • Provide standard network interface that is independent of network topology.


Question 2 - IP Addresses

2. What is the format of IP (DARPA) addresses? Why are IP addresses needed in addition to network physical addresses?

All machine share a global space of identifiers.

  • Format of IP DARPA addresses
    • Name:What an object is.
    • Address: Where an object is.
    • Route: How to get to an object.
  • IP addresses are needed in addition to network physical addresses is because the physical address only identify the object (i.e. router, computer) while the IP address gives the location of where the object is and how to get to it.

The internet maps identifier to a machine location.


Question 3 - IP Addresses

3. What are the different classes of IP addresses? Why are multiple classes needed?

IPv4 address: (netid, hostid) netid: network identifier hostid: host identifier

  • 3 Primary Different classes of IP addresses:
    • Class A: 0 + netid(1-7) + hostid(3-31)
    • Class B: 10 + netid(2-15) + hostid(16-31)
    • Class C: 110 + netid(3-23) + hostid(24-31)

Multiple classes are needed because different machines have different conventions of storing integer values.

Question 4 - Binary Notation

4. Give dotted decimal notation for the following binary number: 00010101 11001010 00011111 01010101.

21.202.21.85

using the bit notation with base 2 128 64 32 16 8 4 2 1



Question 5 - Standard Byte Order

5. Why is it important to have a standard byte order for integer data sent over the internet?

It is important to have a standard byte order for integer data sent over the internet because different machines uses different conventions for storing integer values.




QUIZ #5



Question 6 - RARP

6. What is RARP used for?

RARP: Reverse Address Resolution Protocol. It Translate physical address to IP address RARP is used to respond to ARP messages. The recepient of te ARP message after sending a ARP reply, sends an RARP request to the original sender and once it gets a reply, then transmission of packets can occur.

Question 7 - RARP

7. Describe the sequence of events that occur when RARP is invoked.

Diskless host broadcasts ARP request (giving physical address) and waits for server to respond with UP address (with timeout). On receipt of response, hose verifies physical address and stores IP address in a local table.

Question 8 - ARP

8. What is ARP used for?

ARP is the address resolution protocol. It translate IP addresses into physical addresses.

Question 9 - ARP

9. Describe the sequence of events that occur when ARP is invoked.

ARP's packets are send over the next hop using the underlying network. The source and destination machines are identifies by their physical addresses.

When an ARP is involved, it broadcast a request (giving IP address) and wait for host to respond with physical address (with timeout).

Question 10 ARP Protocol

10. Under what circumstances is ARP NOT an appropriate protocol to use for address mapping?

Two machines on a given physical network can communicate only if they know each other's physical network address. ARP not appropriate when the physical networks don't know each other's physical network address(?).

Question 11 ARP Cache

11. What is the purpose of the ARP cache? What does it contain?

ARP maintains the mapping between IP address and MAC address in a table in memory called ARP cache. The ntries in this table are dynamically added and removed.

It contains recently translated (IP physical address) pairs.

Question 12 LAN

12. What address is used to forward packets over the local network?

The IPv4 address is used to forward packets in the local network.

Question 13 Routers

13. How do routers (gateways) know where to sent packets?

Each router (and hosts) are identified by IP address associated with it. The IP address is decided by the controller board. Each controller have a unique hardware address. Each router will decide where the packet packet is sent through the next router until its destination. Each packet sent will contain the source IP, destination IP and the message. The hosts will know where to send the next packet using the ARP protocol.

Question 14 IP Router

14. Explain the sequence of steps that occur at each IP router when a packet is forwarded through that router.

Hosts send packets to local routers, routers forward packets on to another router towards the final destination. The IP routers forward packets based on information stored in a routing table. IP assumes that routing table exists. The routing table entries consist of network ID,router IP address pairs. Each entry indicates that packets directed towards that network should be sent to the associated router (IP address)


  • IP Routing Algorithm*
    • Extract destination address
    • Computre destination netid
    • if net is difrectly connect, send, datagram oer that network (using physical address)
    • else if host specific route, route to that gateway
    • else if network appears in table, send to that gateway
    • else if default in table, send to that gateway
    • else error

Question 15 IP Packets, Physical Layer

15. Explain how IP packets are encapsulated within physical layer (say ethernet) packets.

The Physical layer is responsible for encoding and transmission of data over network communications media. It operates with data in the form of bits that are sent from the Physical layer of the sending (source) device and received at the Physical layer of the destination device.

Question 16 IP router

15. What happens when an IP router receives more packets than it has buffer space to store them (i.e. when packets arrive faster than they can be forwarded)?


When this buffer space is filled, the router starts to discard packets at random from its queue. Packet queue data buffers are 256 bytes in length. Therefore, the value of this parameter must be a multiple of 256. Multiple buffers are chained together for larger packets. The IP header for a packet is stored separately. This parameter is ignored and no buffers are allocated if the IP router is not enabled.

Question 17 - Round Trip Delivery

17. Why is it difficult to estimate the round trip latency for messages sent over the internet using IP?

Latency (or delay) is the round-trip time for a small data packet to travel between two end points (source and destination city-pairs) in the network. Latency affects one's perception of the response time of the network. It is difficult to estimate the latency because of the irregular congestion and routings there are with the different networks.

Question 18 - Time to live in IP header

18. What is the time-to-live field in the IP header used for? What happens if the internet becomes “too big” for this field?

It is the timeout time (delay time) it takes for one hop of the network. If a timeout occurs, then the packet is discarded and a timeout is sent back to the sender. This field used to contain hops, but now it contains actual time it takes.

Question 19 - Datagram Fragmentation

19. Why is datagram fragmentation sometimes necessary? How does IP fragment datagrams?

As a datagram moves from network to network it may be necessary for a router to divide the datagram into smaller pieces. This occurs if a gateway connects two networks that use different physical media, such as ethernet and a serial modem line. Each type of network has a maximum transmission unit (MTU) parameter that defines the largest packet it can transfer. If a datagram is larger than the MTU for the network then the IP module breaks the datagram into smaller parts. This process is called fragmentation.

In the following example, an IP datagram is fragmented into two. This same algorithm can be used to fragment the datagram into 'n' fragments.

  • 1. The IP layer creates two new IP datagrams, whose length satisfies the requirements of the network in which the original datagram is going to be sent.
  • 2. The IP header from the original IP datagram is copied to the two new datagrams.
  • 3. The data in the original IP datagram is divided into two on an 8 byte boundary. The number of 8 byte blocks in the first portion is called Number of Fragment Blocks (NFB).
  • 4. The first portion of the data is placed in the first new IP datagram.
  • 5. The length field in the first new IP datagram is set to the length of the first datagram.
  • 6. The fragment offset field in the first IP datagram is set to the value of that field in the original datagram.
  • 7. The "more fragments" field in the first IP datagram is set to one.
  • 8. The second portion of the data is placed in the second new IP datagram.
  • 9. The length field in the second new IP datagram is set to the length of the second datagram.
  • 10. The "more fragments" field in the second IP datagram is set to the same value as the original IP datagram.
  • 11. The fragment offset field in the second IP datagram is set to the value of that field in the original datagram plus NFB.

Question 20 - IP Header Checksum

20. What is included in the IP header checksum? Why isn't more of the packet included?


Only the header of the message is computed on the checksum. This is done to streamline the message transfer. (?)

A checksum is a simple error-detection scheme in which each transmitted message that results in a numerical value based on the value of the bytes in a message. The sender places the calculated value in the message (usually in the message header) and sends the value with the message. The receiver applies the same formula to each received message and checks to make sure the accompanying numerical value is the same. If not, the receiver can assume that the message has been corrupted in transmission.

Question 21 - IP Options

21. What are the IP options? Why is their use problematic in today’s Internet?

Several options, such as Record Route and Timestamp, contain slots into which a router inserts its address when forwarding the packet. However, each such option has a finite number of slots, and therefore a router may find that there is not free slot into which it can insert its address. No requirement listed below should be construed as requiring a router to insert its address into an option that has no remaining slot to insert it into. Section [5.2.5] discusses how a router must choose which of its addresses to insert into an option.



QUIZ #6


Review #5: Routing

1. Why does IP routing use IP addresses instead of physical addresses?

(sl 144)

  • Keeps IP independent of network architecture.
  • Because we need to check if the packet is at the correct network and then we forward to the correct device within the network. Otherwise it would have to keep a log of all hardware ids. Physical addresses do not tell you anything about the network (only tell you about the host).


2. What is contained in the IP routing tables?

  • Network ID, Router IP address pairs.
  • Each entry indicates that packets directed towards that network should be sent to the associated router (IP address).


3. Explain how local and remote packets are handled by IP.

  • extract destination address
  • compute destination netid
  • if net is directly connected, send datagram over that network (using physical addresses)
  • else if host specific route, route to that gateway
  • else if network appears in table, send to that gateway
  • else if default in table, send to that gateway
  • else error


4. Why do gateways route on partial information only?

  • Because they only need to look at the header of the message to see the destination.

5. Describe vector-distance route propagation. What happens if a link or site crashes?

  • Each gateway keeps a distance table giving the shortest known distance to each destination
  • Periodically each gateway sends a copy of its distance table to all neighbors.
    • k receives distance table from j
    • if j knows a shorter way to destination N, k updates its table to go trough j
  • All changes propagate, but slowly
  • If network topology changes (i.e. router crashes), some sites will have incorrect routing tables, at least for some time.



6. Describe link-state routing. What happens if a link or site crashes?

  • Each gateway has full topology information
  • All gateways test status of neighbors & periodically broadcast status information to all gateways
  • On receipt of link-status information, all gateways update their topology information & recalculate routing table using e.g. all-pairs-shortest-path.
  • Probe packets for 30 seconds. After 3-4 errors, broadcast that host is down -> within one cycle all routing tables updated.



7. Which algorithm scales better to very large internetworks?

  • Link-State Routing (Shortest Path First-SPF Routing). E.g. Open SPF Protocol.
    • Load balancing (not restricted to one path)
    • Autonomous areas with hidden topologies (network you do not want to distribute outside the network)
    • Host specific & Network specific routes
    • Ability to exchange external routing information (i.e. links between autonomous systems)

8. Why is the internet divided into autonomous systems?

  • Because we do not want to transmit to a backbone every time.
  • If not autonomous and the backbone goes down, a very large number of networks will die.
  • Core Gateways did not scale. Peer backbones can bottleneck and create inefficient routing/loops.
  • Autonomous allow for interior routing protocol to communicate within the autonomous system (i.e. by core gateway & routers within autonomous system).


9. Describe the EGP protocol.

(from wikipedia, searchsmb.com, sl. 217)

  • Exterior Gateway Protocol
  • Used to transfer information about routing tables.
  • The first protocol used for Autonomous systems -> Obsolete now (we have Border GP - BGP)
  • It polls it's neighbours for their routing table every 120-480 seconds.

10. Why does EGP use reachability rather than transmission time as a metric?

  • Because the networks were very unreliable back when it was designed.
  • They weren't concerned at the time with how long it would take a message to arive, but rather if it would arrive at all.

11. What is the difficulty of using static routing within an autonomous system?

  • Not fault tollerant
    • When change in network or failure between two nodes, no rerouting. -> Wait for repair, or wait for admin to update tables

12. How does the RIP protocol handle the slow convergence problem?

RIP

  • Vectoring using hop counts, implemented in routed BSD code (uses broadcast)

Heuristics (answer to how):

  • Split Horizon: do not propagate information over the interface it came in over
  • Hold Down: ignore reachability information until after hold down period (give bad news time to propagate)
  • Poison Reverse: Broadcast information that a link is down immediately. This should trigger updates to all routing tables (and may cascade unpredictably)

13. What are two problems with using RIP in relatively slow networks with many hosts?

  • Not taking into consideration network delays
  • Maximum distance = 16 which for many host and slow network, might not reach destination

14. How does the Hello protocol differ from RIP?

  • Synchronize clocks and use to provide estimates of delays on paths between gateways
  • Each site keeps estimate of current clock on neighbors. Senders timestamp packes, receivers compute delay (& periodically resynchronize clocks by polling neighbors)
  • Gated: combines RIP, hello and EGP + rules for advertising routes to exterior gateways

15. What is the most significant difference between the Open SPF protocol and both RIP and Hello protocols?

  • Ability to exchange external routing information (i.e. Links between autonomous systems).

16. Why are authenticated gateway exchanges and autonomous areas necessary?

  • Because you do not want to distribute information outside the network.

Sup 1: Given the small internet shown below, give a possible sequence of actions that the Vector Distance algorithm might use to initially generate routing tables on each of the sites (you should assume that events do not occur simultaneously and that all gateways participate in the algorithm). Your answer should show each message sent to distribute routing information, and the contents of all of the routing tables after the messages are processed. After the routing tables have stabilized, show what happens if gateway G1 crashes (that is, show a possible sequence of messages and routing tables leading to another steady state).

Snapshot 2007-05-23 20-11-34 Author: MCM

G1 |
- - - |- - - -
G2 | DD | 0
G3 | G2 | 1
G4 | DD | 0

G2 |
- - -|- - - -
G1 | DD | 0
G3 | DD | 0
G4 | DD | 0

G3 |
- - -|- - - -
G1 | G2 | 1
G2 | DD | 0
G4 | DD | 0

G4 |
- - -|- - - -
G2 | DD | 0
G3 | DD | 0
G4 | DD | 0

NOW ASSUME G1 DEAD (it should affect much, other than the 0 or 1 becomes infinity):
G1 | (stays the same)
- - -|- - - -
G2 | DD | 0
G3 | G2 | 1
G4 | DD | 0

G2 |
- - -|- - - -
G1 | DD | INF
G3 | DD | 0
G4 | DD | 0

G3 |
- - -|- - - -
G1 | G2 | INF
G2 | DD | 0
G4 | DD | 0

G4 |
- - -|- - - -
G1 | DD | INF
G2 | DD | 0
G3 | DD | 0

sup 2

Review #6: UDP & TCP

Question 1 - Difference between UDP and TCP

1. What is the difference between UDP and TCP service over the internet?

  • UDP is connectionless (gets priority over TCP on congested network, unreliable delivery:maybe lost, duplicated, delayed or out of order)
  • TCP is connection-oriented (stream, reliable delivery: in order, guaranteed delivery).

Question 2 - UDP and TCP service over internet

2. Why are both UDP and TCP service provided by the internet?

Because sometimes we just want to send out packets and do not care about delivery, or in-order delivery (i.e. streaming music/video).

Question 3 - UDP packet checksum

3. Explain in your own words how UDP computes packet checksums.

  • Construct pseudoheader consisting of
    • source/destination IP addresses
    • IP protocol type code
    • length of packet (not including pseudoheader)
  • UDP checksum is calculated over the pseudoheader & UDP packet. Receiver reconstructs pseudoheader (based on local information) & revives checksum. Match -> bits correctly delivered AND reconstructed pseudoheader is correct

Question 4 - UDP packet checksum

4. Since IP uses checksums, why does UDP use checksums also?

Because UDP is computing the checksum for the pseudoheader which is added by the UDP layer. The IP checksum is based on the IP header.

Question 5 - Protocol port

5. What is a protocol port? How is it used?

A protocol port is a part of a data structure defined by the operating system that allows applications to exchange information. It also allows remote applications to communicate with local applications and vice versa.

Question 6 - UDP port number

6. Is UDP port number 4555 the same as TCP port number 4555?

No. A TCP client cannot connect to a UDP server. As far as the port itself, either a TCP or UDP server can bind to it.

Question 7 - UDP pseudoheader checksum

7. How are pseudoheaders used to compute UDP and TCP checksums?

They are reconstructed upon receipt of the packet using local information and verified with the pseudoheader attached.

Question 8 - Pseudoheaders

8. Are the pseudoheaders sent with UDP or TCP packets?

Yes, pseudoheaders are sent with both.

Question 9 - UDP, TCP checksum calculation

9. How does the UDP/TCP receiver recompute the data checksum?

It reconstructs the pseudoheader and recalculates the checksum. The checksum is a one's complement of the sum of one's complements of 16 bit fragments.

Question 10 - TCP transmission

10. Does TCP support transmission of structured data? Does TCP allow transmission of structured data?

TCP treats the data as an unstructured stream of octets (bytes)--no record boundaries.

Question 11 - TCP connection

11. How does TCP define a connection?


Connection

TCP uses the connection, not the protocol port, as its fundamental abstraction; connection are identified by a pair of endpoints. TCP defines an endpoint to be a pair of integers (host, port), where host is the IP address for a host and port is a TCP port on that host.

Question 12 - TCP port sharing

12. Under what circumstances can processes on a single machine share a TCP port?

Under No circumstances that processes on a single machine share the same port.


Question 13 - TCP push option

13. What is the purpose of the push option in TCP?

The push option is TCP is to send data immediately in a padded segment. Most BSD systems do it automatically withe PUSH flag.

Question 14 - space advertisement with TCP acknowledgement

14. What is the purpose of the space advertisement sent with each TCP acknowledgment?

The purpose of the space advertisement is to notify the receiver's remaining/availability buffer space for incoming messages. A space advertisement of '0' signals to the sender that the receiver's incoming buffer space is full and that the sender should NOT be sending more packets until the sender receive a non-zero space advertisement.

Question 15 - TCP acknowledgment lost

15. If a TCP acknowledgment is lost, is the data packet always transmitted?

On a packet loss, a timeout is thrown on the sender and everything in the packet is retransmitted.

Question 16 - TCP timeout

16. When a TCP timeout is sent, which packets are resent? Are all of these packets always resent? Explain your answer.


When a TCP timeout is sent, all the lost data will be transmitted.

All these packets are always resent -- behaves like GBN protocol although it is Selective Repeat.

Question 17 - Flow Control

17. What does flow control prevent? How is flow control provided by TCP?

Flow control prevents network congestion, when there are too many packets on the network.

TCP permit multiple data packets to be in simultaneous transit, making more efficient use of network bandwidth.

Flow control is provided by TCP by using the following algorithms:

  • Slow-start used by Sender
  • Congestion avoidance used by receiver.

When TCP detects a possible congestion, they stop sending packets using the congestion window. The senders window is bounded by the smaller of the receiver buffer-space available and congestion window size.

Question 18 - Urgent Data, TCP

18. What is the purpose of urgent data? How does TCP support this?

The purpose of urgent data is to notify the receiving program immediately. System will be in TCP urgent mode until the urgent data is gone.

The only information sent across the connection by TCP is that urgent mode has begun and the pointer to the last byte of urgent data. Everything else is left to the application. The notification from one end to the other that urgent data has exists in the data stream is done by setting two fields in the TCP header.


Question 19 - Timeout values

19. What are some of the difficulties with setting timeout values for TCP?

Round trip transmission times varies depending on the destination host and system load.

Due to different RFC implementations it is difficult to specify the "real delay" of an acknowledge timeout (guessing 200..500ms depending on OS and RFC implementation), because features like Nagle algorithm, delayed acknowledge etc. will have some influences when and if an acknowledge will be sent immediately (which depends also on window sizes).

Question 20 - ALPHA and sensitivity

20. Explain how the value of ALPHA determines sensitivity to change in the following formula: RTT = (ALPHA * OLD_RTT) + (1 - ALPHA) * NEW_RTT.

record time packet was sent and time ack arrives. compute sample round trip time (srtt) and used to compute a moving average.

α is smaller when SRTT(i) < S(i), allowing the SRTT to adapt more swiftly to sudden increase in network delay.

  • α near 1: immune to transient changes
  • α near 0: respond quickly to changes
  • α =.9 typically

Question 21 - BETA and retransmissions

21. Explain how the value of BETA affects the number of unnecessary retransmissions in the following formula: Timeout = BETA * RTT


To minimize retransmissions, β should be chosen such that the RTO will be a high upper limit on the round-trip times. The TCP specification recommends a value of β=2 as a reasonable balance.

  • β near 1:detect lost packets quickly.
  • β > 1: avoid unnecessary retransmission.
  • β = 2: typically.

Question 22 - Estimates

22. What is the problem with using estimates of round trip delay based on acknowledgments for retransmitted packets?


Acknowledgments are cumulative and refer to data received, not to a particular packet sent. If a packet is retransmitted, can't tell which packet acknowledgment belongs to. Guessing oldest and most recent will both fail and cause estimate to be consistently wrong.


Solution to Problem: Don't update round trip delay for retransmitted packets.

Question 23 - Exponential timer backoff

23. What is exponential timer backoff? What is it used for?

Exponential timer backoff refers to the Karn's Algorithm. Exponential backoff is an algorithm that uses feedback to multiplicatively decrease the rate of some process, in order to gradually find an acceptable rate. It is often used in network congestion avoidance to help determine the correct sending rate.


It is used to when computing the round trip estimate. Samples corresponding to the retransmitted segments are ignored. The backoff strategy is used and to retain the timeout value from a retransmitted packet for subsequent packets until a valid sample is obtained.

Question 24 - variability in TCP

24. How is variability in round trip times handled in TCP?

Use Karn's Algorithm. When computing the roundtrip time estimate, ignore samples that correspond to retransmitted segments, but use a backoff strategy, and retain the timeout value from a retransmitted packet for subsequent packets until a valid sample is obtained.


QUIZ #7


Question 25 - congestion

25. What is congestion? How does TCP handle possible congestion?

  • Problem: Too many packets in the network = congestion
  • Solution: Whent TCP senders detect possible congestion, they stop sending packets using a congestion window
  • The senders window is bounded by the smaller of the receiver-buffer-space-available and congestion-window size

Question 26 - handshaking in TCP

26. Why is handshaking necessary when TCP connections are initiated or terminated? (sl. 263-264)

  • 3-way handshake - So that TCP can ignore additional requests for connection after a connection has been established

Review Questions #7. ISO Network, Transport, Session, Presentation and Application Layer; TCP/IP Applications

Question 1 - Difference between congestion and flow control

1. What is the difference between congestion control and flow control? Why are both necessary?

Congestion Control: Limit number of packets in network.
Flow Control: Limit transfer rate at which packets ente3r network.

Both are necessary because datagrams potentially travels from high speed network to slow dial-up network where datagrams may arrive faster than they can be sent.

Question 2 - Virtual Circuit Delivery and Datagram Delivery

2. What is the difference between virtual circuit delivery and datagram delivery?

Virtual Circuit: route is established at the time the circuit is created.
Datagram: packets routed individually.

Question 3 - Virtual Circuit buffers

3. Explain how buffers can be preallocated for virtual circuits.

To make transfer more efficient and to minimize network traffic, buffers can be preallocated for virtual circuits by filling up the buffers with large datagram before transmitting it across an internet.

Question 4 - Virtual Circuit delivery, recovery

4. With virtual circuit delivery, can packets be discarded if no buffers are available? If so, how is recovery handled.

Yes, packets can be discarded if no buffers are available so long as it keep one buffer free for ACK's. Recovery can be handled through a technique known as positive acknowledgment with retransmission where virtual circuit will timeout and retransmit.

Question 5 - Datagram Delivery recovery

5. With datagram delivery, can packets be discarded if no buffers are available? If so, how is recovery handled?

Packets can be discarded with datagram delivery if no buffers are available. The recovery is handled by virtual circuit timing out and retransmitting.

Question 6 - Internet datagrams Vs Virtual Circuits

6. Explain the difference between internetworking based on internet datagrams (IP) and internetworking based on concatenated virtual circuits (X.75).

IP based: Each packet is routed independently, packets can get lost, arrive out of order, and jumbled up during network transmission.

X.75 Concatenated VC based: Routing done at time VC is established.

Question 7 - ISO Differences

7. In ISO terminology, what is the difference between a repeater, a bridge, a gateway and a protocol converter?

Repeater: Copies bits between cable segments.
Bridge: Store and forward frames between LAN's.
Gateway: Store and forward packet between dissimilar networks.

    • OSI Gateways: connection oriented or datagram based.
    • TCP/IP Gateways: datagram based (only).

Protocol Converter: Higher lever interface between networks, i.e. email forwarding service.

Question 8 - connection-oriented vs connectionless gateway

8. What is the difference between a connection-oriented and a connectionless gateway?

Question 9 - ISO, connection-oriented or connectionless gateway

9. Does ISO support connection-oriented or connectionless gateways?

NOT COVERED.

Question 10 - TCP/IP, connection-oriented or connectionless gateway

10. Does TCP/IP support connection-oriented or connectionless gateways?

TCP/IP support both connection-oriented and connectionless gateway.

Question 11 - Networks based on ISO transport protocol

11. What are the three types of networks addressed by the ISO transport protocol?

NOT COVERED.

Question 12 - 4 classes of services by ISO transport protocol

12. What are the four classes of service provided by the ISO transport protocol? Which is most like TCP/IP?


Question 13 - purpose of quality of service parameters

13. What is the purpose of quality of service parameters? When are they set?


Question 14 - quality of service parameters

14. What quality of service parameters does TCP/IP provide?


Question 15 - data transfer functions of ISO transport layer

15. Give some examples of data transfer functions that might be provided by an ISO tranport layer entity.


Question 16 - transport layer entities functions

16. Do all transport layer entities support all possible functions? How are the functions for a particular connection chosen?


Question 17 - multiplexing/demultiplexing, plitting/recombining

17. Define the following concepts for dealing with connections: multiplexing/demultiplexing, plitting/recombining.


Question 18 - segmenting/reassembling, blocking/deblocking, concatenation/separation.

18. Define the following concepts for dealing with data units: segmenting/reassembling, blocking/deblocking, concatenation/separation.


Question 19 - client-server action procedure calls

19. How does client-server action correspond to a procedure call?


Question 20 - server fork off child

20. What are the advantages and disadvantages of having the server fork off a child process to handle each client request?


Question 21 - caching

21. How can caching increase the performance of client-server applications?


Question 22 - server fork off child

22. Under what circumstances will caching lead to decreased overall performance?


Question 23 - talk command and caching

23. Why is caching unsuitable for implementing applications like the talk command?


Question 24 - Socket calls for client-server interaction

24. What socket calls support client-server interaction? How is this support provided?


Question 25 - network byte order in client-server applications

25. Why is network byte order significant in programming client-server applications?



Question 26 - applications, IP address of the machine

26. How do applications determine the IP address of the machine they happen to be running on?


Question 27 - Port numbers allocated

27. How are port numbers allocated to application client and server programs?


Question 28 - Client-Server IP Address

28. How does a client know the address (IP address and port number) of a server?


Question 29 - Domain Name Server

29. What is the purpose of the Domain Name Server?


Question 30 - IP address

30. Why aren't IP addresses used directly by users and applications?


Question 31 - TCP/IP use a hierarchical namespace

31. Why does TCP/IP use a hierarchical namespace? Do TCP/IP names correspond to physical network topology?


Question 32 - Internet sites registration

32. Do sites register on the Internet by geographic location or organization?


Question 33 - caching and name translation

33. Why is caching used for name translation?


Question 34 - outdated cached name

34. How are out of date cached name translation entries handled?


Question 35 - distributed name server

35. Why is a distributed name server used rather than a single centralized server?

Also on Fandom

Random wikia