Midterm Exam Revision Material

Revision for Midterm Exam

  • Suggested students to review Lectures in Modules 1 to 4 prior to answering questions.

  • Solutions or keys to solutions are provided to help with understanding the material covered.

Revision Questions - Part A (Modules 1 and 2, including Lab 1 and Homework 1)

  • Contains various questions focusing on key concepts from the modules.

Revision Questions Part A

  1. Application Layer Applications and Protocols
       - Examples include:
         - Email – SMTP (Simple Mail Transfer Protocol)
         - Web-browsing – HTTP (Hypertext Transfer Protocol)
         - BitTorrent file sharing – BitTorrent protocol

  2. Client-Server Communication
       - The process that initiates communication is the client.
       - The process that provides service or responds is the server.

  3. Identifying Application Layer Processes
       - Identified by the IP address of the host and the port number of the process.

  4. Communications Protocols
       - An HTTP client uses TCP (Transmission Control Protocol) for web communication, whereas DNS (Domain Name System) typically uses UDP (User Datagram Protocol).
       - Ports used: HTTP port 80, DNS port 53.

  5. Network Edge vs. Edge Network
       - Edge Network is where access/aggregation networks connect with services.
       - Network Edge refers to the clients and hosts at the periphery of the network.

  6. Main Function of the Internet’s Core Network
       - Comprises high-speed routers and links to efficiently carry traffic over long distances.

  7. Peering vs. Transit among ISPs
       - Peering: Direct exchange of traffic between ISPs without payment.
       - Transit: Traffic routed through another ISP, typically involving a payment.

  8. Web-Cache Server
       - Helps reduce latency by storing copies of frequently accessed content closer to users.

  9. Data Sharing in BitTorrent
       - No, Bob does not need to provide chunks to Alice; he must be among Alice's top 4 neighbors.

  10. Email Sending and Receiving Protocols
        - SMTP for sending messages.
        - IMAP (Internet Message Access Protocol) or POP3 (Post Office Protocol) for receiving messages.

  11. CDN Architectures
        - Distributed: Smaller servers at the edge reducing delays and bandwidth usage.
        - Centralized: Large central server, generally resulting in lower maintenance costs.

  12. VDSL vs. Optical Fiber
        - VDSL (Very High Bitrate Digital Subscriber Line) has a shorter range compared to optical fiber but can provide similar speeds (100 Mbps).

  13. Packet Switching vs. Circuit Switching
        - Packet Switching: Less setup time, efficient for bursty traffic; can have congestion, overheads, and out-of-order packets; utilizes bandwidth better.
        - Circuit Switching: Longer setup time, reserves a circuit for the duration of communication, sequential communication.

  14. Transmission Delay vs. Propagation Delay
        - Transmission Delay: Time required to push all the packet bits onto the wire.
        - Propagation Delay: Time taken for a signal to travel from sender to receiver.

  15. HTTP Statelessness
        - HTTP lacks statefulness across sessions; server does not retain memory of past sessions.
        - Cookies do not make HTTP stateful as they only store data for the client.

  16. Cookie Management
        - Cookie files are stored on the client’s computer and managed by the website's cookie server.

  17. DNS Activation When Accessing a Website
        - Activated when an HTTP client requests a website.

  18. DNS Load Distribution
        - DNS can rotate IP addresses among servers to manage load effectively when a website has multiple addresses.

  19. Handshaking in Communication Protocols
        - Refers to the initial control packet exchange to establish a connection before data exchange; HTTP does not require handshaking.

  20. Traffic Intensity Approaching 1
        - As traffic intensity nears 1, delays in the network become unbounded.

  21. Keep-Alive Connection in HTTP
        - Keeps the connection open for multiple requests/responses between the client and server.

  22. Conditional HTTP Request Response
        - Server responds with a 304 Not Modified status if the page has not changed since the last visit.

  23. Root DNS Information
        - Contains global Top-Level Domains (gTLDs) and country code Top-Level Domains (ccTLDs).

  24. Non-Authoritative Answer
        - Response that is derived from cached information rather than being retrieved from the original DNS server.

  25. DASH
        - Dynamic Adaptive Streaming over HTTP, used for optimizing video streaming based on device capability and network conditions.

  26. Collision Domains and Switch Ports
        - A switch with 8 ports creates 8 collision domains; connecting a hub adds extra domains based on the port connected to the switch.

  27. Advantages of Packetizing
        - Increases the chances of successful data transmission through various paths; allows interleaving packets from different data streams.

  28. Wi-Fi Range Determinants
        - Factors include interference, obstructions (buildings, foliage), mast height, and frequencies used.

  29. Queueing Delays
        - Occurs when the incoming data rate surpasses processing speed; may result from slower outgoing rates from nodes.

  30. NOC
        - Network Operations Center, responsible for monitoring and managing a network.

Key to Revision Part A

  • Detailed responses are provided for all questions for students to review their understanding and prepare for the midterm exam.

Revision Questions Part B (Modules 3 and 4)

  • Contain questions relevant to the transport layer.

Transport Layer – Question Set 1

  1. Reliable Service Over Best Effort Network Layer
       - Yes, the transport layer can provide reliable service by utilizing protocols such as TCP.

  2. UDP Reliability
       - UDP is not considered reliable since it does not perform error recovery and does not guarantee packet order or delivery.

  3. Achieving Reliability with UDP
       - Application developers can build functionalities like error checking and acknowledgments to handle reliability, despite using UDP.

  4. Necessity of UDP
       - UDP is required for applications needing low latency, like video streaming or online gaming, despite its lack of reliability.

  5. Creating a UDP Socket
       - Example code:
    python clientSocket = socket(AF_INET, SOCK_DGRAM)      
       - UDP socket addresses defined by a tuple: (destination IP address, destination port).

  6. Header Sizes
       - TCP header size is typically 20-60 bytes.
       - UDP header size is always 8 bytes.

  7. Bandwidth Allocation
       - The transport layer does not guarantee equal bandwidth distribution; it is subject to the network's capabilities and current loads.

  8. Channel Utilization
       - No, utilization cannot exceed 1 (100%); it represents the theoretical maximum capacity.

Transport Layer Techniques for Reliable Data Transfer

  • Overview of functionalities provided by TCP, which include:
       - Multiplexing and demultiplexing of packets.
       - Error detection mechanisms.
       - Acknowledgments through ARQ (Automatic Repeat reQuest).
       - Flow control to prevent overwhelming the receiver.
       - Congestion control for traffic regulation.
       - UDP offers only multiplexing and error detection.

Socket Programming Overview

  • Client Socket Creation:

    python clientSocket = socket(AF_INET, SOCK_DGRAM)   

  • Example address assignment:
       - address = (“134.124.1.234”, 51628).
       - Transport layer auto-assigns an unused port or can be set manually with socket.bind(address).

UDP Datagram Structure (RFC 768)

  • Defines structure comprising:
       - Source Port: 16 bits
       - Destination Port: 16 bits
       - Length: 16 bits (header + payload)
       - Checksum: 16 bits (optional for error checking)

  • Maximum Transmission Unit (MTU): 65,53565,535 bytes.

TCP Segment Structure

  • Header sizes are between 20 and 60 bytes, typically 20 bytes with optional fields contributing to maximum size.

GBN vs. SR Comparison

  • GBN (Go-Back-N):
       - Retransmits all frames after a lost packet.
       - Less complex, often preferred for simplicity.

  • SR (Selective Repeat):
       - Only lost packets are retransmitted; it requires more complex storage and processing.
       - Generally provides better bandwidth utilization compared to GBN.

Congestion Management in Transport Layer

  • Outgoing and incoming data rates observed based on retransmissions, resulting in unique congestion patterns.

  • Bandwidth and data processing rates may cause varying delays.

  • Packet drops at the last stage can lead to wasted bandwidth.

TCP Flow Control and Channel Utilization

  • Describes the relationship between propagation delay and transmission delay.

  • Utilization formula:
    Utilization=N2α+1Utilization = \frac{N}{2\alpha + 1}
       - where α=tpropttrans\alpha = \frac{t_{prop}}{t_{trans}}.

Revision Questions Part 2

  1. Connection Management and importance of sequence numbers in TCP.

  2. TCP Vulnerability to Denial of Service (DoS) attacks.

  3. The effects of flow control on data sender behavior and its impact on throughput.

  4. The role of congestion control in sender throttling actions.

Review of TCP Connection Management

  • Connection Setup, illustrated through packet exchanges, including managing buffers and maintaining sequence numbers.

  • Risks involved in connection setup imply that flooding SYN requests could lead to resource exhaustion by the server, making it susceptible to DoS.

Flow Control Mechanisms in TCP

  • Sender utilizes a receive window (rwnd) to limit unacknowledged data to maintain efficient data flow and prevent buffer overflow.

  • Utilization metrics explored through round-trip times and transmission rates.

Reasons for TCP Congestion

  • Explains causes such as excessive sources, unsynchronized sending patterns, and higher transmission rates than acceptable by receivers.

  • Discusses congestion control mechanisms and related algorithms that regulate sender rates depending on network conditions.

Network Layer - Question Set 1

  1. Differences between routing and forwarding functions.

  2. Main functions of the control plane.

  3. Main functions of the data plane.

  4. Performance monitoring roles within routing frameworks.

  5. Disparity between software-defined networking (SDN) and traditional networking approaches.

Routing vs. Forwarding**

  • Routing is the global action to determine the path through the network. It infrequently updates routing tables based on network changes.

  • Forwarding is a local function that frequently directs packets through the appropriate output link based on table lookups.

Control Plane Functions

  • Software services that enable decision-making processes, share topology info with routers, and manage traffic loads while constructing routing tables.

Data Plane Functions

  • Executes packet movement through the network with an emphasis on quality of service (QoS), efficient filtering, and encapsulation of packets at high speeds using dedicated hardware (ASICs).

Revision Questions Part A 1. Application Layer Applications and Protocols
  • Examples include:

  • Email – SMTP (Simple Mail Transfer Protocol)

  • Web-browsing – HTTP (Hypertext Transfer Protocol)

  • BitTorrent file sharing – BitTorrent protocol

  1. Client-Server Communication

  • The process that initiates communication is the client.

  • The process that provides service or responds is the server.

  1. Identifying Application Layer Processes

  • Identified by the IP address of the host and the port number of the process.

  1. Communications Protocols

  • An HTTP client uses TCP (Transmission Control Protocol) for web communication, whereas DNS (Domain Name System) typically uses UDP (User Datagram Protocol).

  • Ports used: HTTP port 80, DNS port 53.

  1. Network Edge vs. Edge Network

  • Edge Network is where access/aggregation networks connect with services.

  • Network Edge refers to the clients and hosts at the periphery of the network.

  1. Main Function of the Internet’s Core Network

  • Comprises high-speed routers and links to efficiently carry traffic over long distances.

  1. Peering vs. Transit among ISPs

  • Peering: Direct exchange of traffic between ISPs without payment.

  • Transit: Traffic routed through another ISP, typically involving a payment.

  1. Web-Cache Server

  • Helps reduce latency by storing copies of frequently accessed content closer to users.

  1. Data Sharing in BitTorrent

  • No, Bob does not need to provide chunks to Alice; he must be among Alice's top 4 neighbors.

  1. Email Sending and Receiving Protocols

  • SMTP for sending messages.

  • IMAP (Internet Message Access Protocol) or POP3 (Post Office Protocol) for receiving messages.

  1. CDN Architectures

  • Distributed: Smaller servers at the edge reducing delays and bandwidth usage.

  • Centralized: Large central server, generally resulting in lower maintenance costs.

  1. VDSL vs. Optical Fiber

  • VDSL (Very High Bitrate Digital Subscriber Line) has a shorter range compared to optical fiber but can provide similar speeds (100 Mbps).

  1. Packet Switching vs. Circuit Switching

  • Packet Switching: Less setup time, efficient for bursty traffic; can have congestion, overheads, and out-of-order packets; utilizes bandwidth better.

  • Circuit Switching: Longer setup time, reserves a circuit for the duration of communication, sequential communication.

  1. Transmission Delay vs. Propagation Delay

  • Transmission Delay: Time required to push all the packet bits onto the wire.

  • Propagation Delay: Time taken for a signal to travel from sender to receiver.

  1. HTTP Statelessness

  • HTTP lacks statefulness across sessions; server does not retain memory of past sessions.

  • Cookies do not make HTTP stateful as they only store data for the client.

  1. Cookie Management

  • Cookie files are stored on the client’s computer and managed by the website's cookie server.

  1. DNS Activation When Accessing a Website

  • Activated when an HTTP client requests a website.

  1. DNS Load Distribution

  • DNS can rotate IP addresses among servers to manage load effectively when a website has multiple addresses.

  1. Handshaking in Communication Protocols

  • Refers to the initial control packet exchange to establish a connection before data exchange; HTTP does not require handshaking.

  1. Traffic Intensity Approaching 1

  • As traffic intensity nears 1, delays in the network become unbounded.

  1. Keep-Alive Connection in HTTP

  • Keeps the connection open for multiple requests/responses between the client and server.

  1. Conditional HTTP Request Response

  • Server responds with a 304 Not Modified status if the page has not changed since the last visit.

  1. Root DNS Information

  • Contains global Top-Level Domains (gTLDs) and country code Top-Level Domains (ccTLDs).

  1. Non-Authoritative Answer

  • Response that is derived from cached information rather than being retrieved from the original DNS server.

  1. DASH

  • Dynamic Adaptive Streaming over HTTP, used for optimizing video streaming based on device capability and network conditions.

  1. Collision Domains and Switch Ports

  • A switch with 8 ports creates 8 collision domains; connecting a hub adds extra domains based on the port connected to the switch.

  1. Advantages of Packetizing

  • Increases the chances of successful data transmission through various paths; allows interleaving packets from different data streams.

  1. Wi-Fi Range Determinants

  • Factors include interference, obstructions (buildings, foliage), mast height, and frequencies used.

  1. Queueing Delays

  • Occurs when the incoming data rate surpasses processing speed; may result from slower outgoing rates from nodes.

  1. NOC

  • Network Operations Center, responsible for monitoring and managing a network.

Key to Revision Part A - Detailed responses are provided for all questions for students to review their understanding and prepare for the midterm exam.

Revision Questions Part B (Modules 3 and 4)

  • Contain questions relevant to the transport layer.

Transport Layer – Question Set 1
  1. Reliable Service Over Best Effort Network Layer

  • Yes, the transport layer can provide reliable service by utilizing protocols such as TCP.

  1. UDP Reliability

  • UDP is not considered reliable since it does not perform error recovery and does not guarantee packet order or delivery.

  1. Achieving Reliability with UDP

  • Application developers can build functionalities like error checking and acknowledgments to handle reliability, despite using UDP.

  1. Necessity of UDP

  • UDP is required for applications needing low latency, like video streaming or online gaming, despite its lack of reliability.

  1. Creating a UDP Socket

  • Example code:
    python clientSocket = socket(AF_INET, SOCK_DGRAM)

  • UDP socket addresses defined by a tuple: (destination IP address, destination port).

  1. Header Sizes

  • TCP header size is typically 20-60 bytes.

  • UDP header size is always 8 bytes.

  1. Bandwidth Allocation

  • The transport layer does not guarantee equal bandwidth distribution; it is subject to the network's capabilities and current loads.

  1. Channel Utilization

  • No, utilization cannot exceed 1 (100%); it represents the theoretical maximum capacity.

Transport Layer Techniques for Reliable Data Transfer
  • Overview of functionalities provided by TCP, which include:

  • Multiplexing and demultiplexing of packets.

  • Error detection mechanisms.

  • Acknowledgments through ARQ (Automatic Repeat reQuest).

  • Flow control to prevent overwhelming the receiver.

  • Congestion control for traffic regulation.

  • UDP offers only multiplexing and error detection.

Socket Programming Overview
  • Client Socket Creation:
    python clientSocket = socket(AF_INET, SOCK_DGRAM) - Example address assignment:

  • address = (“134.124.1.234”, 51628).

  • Transport layer auto-assigns an unused port or can be set manually with socket.bind(address).

UDP Datagram Structure (RFC 768)
  • Defines structure comprising:

  • Source Port: 16 bits

  • Destination Port: 16 bits

  • Length: 16 bits (header + payload)

  • Checksum: 16 bits (optional for error checking) - Maximum Transmission Unit (MTU): 65,53565,535 bytes.

TCP Segment Structure
  • Header sizes are between 20 and 60 bytes, typically 20 bytes with optional fields contributing to maximum size.

GBN vs. SR Comparison
  • GBN (Go-Back-N):

  • Retransmits all frames after a lost packet.

  • Less complex, often preferred for simplicity.

  • SR (Selective Repeat):

  • Only lost packets are retransmitted; it requires more complex storage and processing.

  • Generally provides better bandwidth utilization compared to GBN.

Congestion Management in Transport Layer
  • Outgoing and incoming data rates observed based on retransmissions, resulting in unique congestion patterns.

  • Bandwidth and data processing rates may cause varying delays.

  • Packet drops at the last stage can lead to wasted bandwidth.

TCP Flow Control and Channel Utilization
  • Describes the relationship between propagation delay and transmission delay.

  • Utilization formula:
    Utilization=N2α+1Utilization = \frac{N}{2\alpha + 1}

  • where α=t<em>propt</em>trans\alpha = \frac{t<em>{prop}}{t</em>{trans}}.

Revision Questions Part 2

  1. Connection Management and importance of sequence numbers in TCP.

  2. TCP Vulnerability to Denial of Service (DoS) attacks.

  3. The effects of flow control on data sender behavior and its impact on throughput.

  4. The role of congestion control in sender throttling actions.

Review of TCP Connection Management
  • Connection Setup, illustrated through packet exchanges, including managing buffers and maintaining sequence numbers.

  • Risks involved in connection setup imply that flooding SYN requests could lead to resource exhaustion by the server, making it susceptible to DoS.

Flow Control Mechanisms in TCP
  • Sender utilizes a receive window (rwnd) to limit unacknowledged data to maintain efficient data flow and prevent buffer overflow.

  • Utilization metrics explored through round-trip times and transmission rates.

Reasons for TCP Congestion
  • Explains causes such as excessive sources, unsynchronized sending patterns, and higher transmission rates than acceptable by receivers.

  • Discusses congestion control mechanisms and related algorithms that regulate sender rates depending on network conditions.

Little's Theorem, often referred to in the context of probability and queueing theory, states that for a stable system, the long-term average number of items in a queuing system (L) is equal to the long-term average arrival rate (λ) multiplied by the average time a customer spends in the system (W). The formula is represented as:

L=λWL = \lambda W

Key Concepts:
  • L (Average Number of Items in the System): The expected number of items (customers, tasks, etc.) present in a queuing system at any given time.

  • λ (Arrival Rate): The average number of items arriving in the system per time unit.

  • W (Average Time in the System): The expected total time that an item spends in the system, from arrival to departure.

Applications:
  • This theorem is pivotal in performance analysis of queueing systems, allowing analysts to predict traffic behavior.

  • Applicable to various fields such as telecommunications, computing, and operations management to optimize resource use and manage congestion.