Key Concepts in Computer Networking and Internet Protocols

Frequently Asked Questions

  1. “The term for an internet connection is the amount of data that can be transferred in 1 second, measured in bits per second (bps):”

    Answer: B. Throughput

  2. “If  (throughput of the server  is greater than the throughput of the client ), then the average end-to-end throughput is:”

    Answer: C. Min 

  3. “Identify the correct order in which the following steps take place in an interaction between a browser and a web server to establish a TCP connection. (Assume RTT = 2):”

    Answer: A. 5, 1, 2, 3, 4

  4. “Internet access by transmitting digital data over the wires of a local telephone network is provided by:”

    Answer: D. Digital Subscriber Line (DSL)

  5. “When creating datagram to send into UDP socket, must specify:”

    Answer: C. Source IP-Port, Destination IP-Port

  6. “The domain name system (DNS) is maintained by:”

    Answer: C. A distributed database system

  7. “The TCP protocol can deliver ___ out of order segments to the process:”

    Answer: A. Some

  8. “Which is not an application layer protocol?”

    Answer: D. IP and ICMP

  9. “DNS is an acronym for:”

    Answer: A. Domain Name Service

  10. “Application layer offers ___ service”

    Answer: A) Process to process

  11. “Internet works on?”

    Answer: B) Packet switching

  12. “What is the keyword used to define a domain alias in DNS?”

    Answer: A) CName

  13. “Which is a time-sensitive service?”

    Answer: Internet telephony

  14. “Consider different activities related to email: m1: Send an email from a mail client to a mail server, m2: Download an email from mailbox server to a mail client, m3: Checking email in a web browser:”

    Answer: m1: SMTP, m2: IMAP, m3: HTTP

  15. “Who determines source-destination paths taken by packets?”

    Answer: Routing algorithm

Image Transmission Time Calculations

Problem Description:

An image has a size of 1200×1800 pixels (Full HD) with true color, which means that 2 Bytes per pixel are used for the color information. Calculate how long it takes to transmit the uncompressed image via different connection speeds:

  1. 56 kbps Modem connection
  2. 10 Mbps DSL connection
  3. 100 Mbps Ethernet connection
  4. 1 Gbps Ethernet connection

Given:

  • 1 Byte = 8 Bits
  • 1 kbps = 1,000 Bits per second
  • 1 Mbps = 1,000,000 Bits per second
  • 1 Gbps = 1,000,000,000 Bits per second

Calculations and Results:

  1. Total Pixels = 1200 x 1800 = 2,160,000 pixels
  2. Total Image Size = 2,160,000 pixels x 2 Bytes/pixel = 4,320,000 Bytes
  3. Total Image Size in Bits = 4,320,000 Bytes x 8 = 34,560,000 Bits

Transmission Times:

  • (a) 56 kbps Modem:
    • Time = 34,560,000 / 56,000 = 617.14 seconds
  • (b) 10 Mbps DSL:
    • Time = 34,560,000 / 10,000,000 = 3.46 seconds
  • (c) 100 Mbps Ethernet:
    • Time = 34,560,000 / 100,000,000 = 0.346 seconds
  • (d) 1 Gbps Ethernet:
    • Time = 34,560,000 / 1,000,000,000 = 0.0346 seconds

Difference between HTTP and SMTP

  1. HTTP (Hypertext Transfer Protocol):

    • Used to transfer hypertext (web pages) between a client (browser) and a server.
    • Stateless and request-response protocol.
    • Operates on port 80 (by default).
  2. SMTP (Simple Mail Transfer Protocol):

    • Used to send emails between mail servers or from a client to a mail server.
    • Primarily focuses on email delivery.
    • Operates on port 25 (by default).

Three Major Components of E-Mail

  1. User Agents (UA):

    • Examples: Microsoft Outlook, Gmail, Thunderbird.
    • Applications that allow users to send, read, and organize emails.
  2. Mail Servers:

    • Store and manage incoming and outgoing emails.
    • Examples: SMTP server for outgoing mail, POP3/IMAP server for incoming mail.
  3. Protocols:

    • Rules used for sending and receiving emails.
    • Examples: SMTP (sending), POP3, IMAP (receiving).

Difference between Application Layer and Network Layer

  1. Application Layer:

    • Topmost layer in the OSI model.
    • Focuses on providing network services to end users (e.g., email, file transfer, web browsing).
    • Examples of protocols: HTTP, SMTP, FTP.
  2. Network Layer:

    • Third layer in the OSI model.
    • Responsible for data routing, packet forwarding, and logical addressing (IP addresses).
    • Examples of protocols: IP, ICMP.

Difference between Forwarding and Routing

  1. Forwarding:

    • Process of moving packets from an input interface to the appropriate output interface within a router.
    • A local, per-router process based on the forwarding table.
  2. Routing:

    • Process of determining the optimal path a packet should take across the network.
    • Involves creating and updating the routing table using algorithms like Dijkstra or Bellman-Ford.

Difference between Encapsulation and Decapsulation

  1. Encapsulation:

    • Process of adding headers (and sometimes trailers) to data as it moves down the OSI layers.
    • Happens at the sender’s side.
    • Ensures data is properly formatted for transmission.
  2. Decapsulation:

    • Process of removing headers (and trailers) as data moves up the OSI layers.
    • Happens at the receiver’s side.
    • Ensures the original message is retrieved.

NASA Mars Communication Link

  1. (a) Round Trip Time (RTT):

    • Distance = 55,000,000 km = 55 x 109 meters.
    • Speed of light = 299,792,458 m/s.
    • RTT = 2 x (Distance / Speed) = 2 x (55 x 109 / 299,792,458) seconds
    • RTT ≈ 366.18 seconds.
  2. (b) Bandwidth-Delay Product:

    • Bandwidth = 128 kbps = 128 x 103 bps.
    • Delay = RTT / 2 = 366.18 / 2 seconds = 183.09 seconds.
    • Bandwidth-delay product = Bandwidth x Delay = 128 x 103 x 183.09 bits.
    • Bandwidth-delay product = 23,426,880 bits.
  3. (d) 1 Gbps Ethernet Connection:

    • Distance = 100 meters.
    • RTT = 2 x (Distance / Speed of Light in Fiber (2/3 of c)).
    • c = 299,792,458 m/s
    • RTT = 1 microsecond.

Network Configuration Problem

  1. Determine the bottleneck link:

    • The bottleneck is the link with the lowest transmission rate, which is Link1 (2 Mbps).
  2. Time to transfer an 8 Mb file:

    • File size = 8 Mb = 8 x 106 bits.
    • Transfer rate = 2 Mbps = 2 x 106 bits/second.
    • Time = File Size / Transfer Rate = 8 x 106 / 2 x 106 = 4 seconds
  3. Total delay with RTTs:

    • RTT for the bottleneck link = 4 ms = 0.004 seconds.
    • Considering HTTP request-response cycles:
    • Assume 1 RTT for the request and an additional RTT for starting the download. Total RTT delay = 0.004 + 0.004 = 0.008 seconds.
    • Total time = File transfer time + RTTs = 4 + 0.008 = 4.008 seconds.

Exercise 1: Network Layers, Protocols, and Units

  • Application Layer

    • Protocols: HTTP, SMTP, FTP, DNS
    • Protocol Data Unit (PDU): Messages
    • Addressing: Domain names (e.g., www.example.com)
  • Transport Layer

    • Protocols: TCP, UDP
    • Protocol Data Unit (PDU): Segments
    • Addressing: Port numbers (e.g., 80 for HTTP, 25 for SMTP)
  • Network Layer

    • Protocols: IP (IPv4, IPv6), ICMP
    • Protocol Data Unit (PDU): Packets
    • Addressing: IP addresses (e.g., 192.168.1.1)
  • Link Layer

    • Protocols: Ethernet, Wi-Fi, PPP
    • Protocol Data Unit (PDU): Frames
    • Addressing: MAC addresses
  • Physical Layer

    • Protocols: IEEE 802.3 (Ethernet), IEEE 802.11 (Wi-Fi)
    • Protocol Data Unit (PDU): Bits
    • Addressing: None (transmission of raw data)

Exercise 2: Email Protocols and Mechanisms

  • (a) At point 6 in the diagram, what protocol is being used?
    • The protocol at point 6 is HTTP or IMAP (depending on whether the user is retrieving the email from a web-based service or a mail client).
  • (b) At point 4 in the diagram, what protocol is being used?
    • The protocol at point 4 is SMTP (Simple Mail Transfer Protocol).
  • (c) At point 2 in the diagram, what protocol is being used?
    • The protocol at point 2 is SMTP.
  • (d) Does SMTP use TCP or UDP?
    • SMTP uses TCP, typically on port 25, 465, or 587.
  • (e) Is SMTP a ‘push’ or ‘pull’ protocol? Is IMAP a ‘push’ or ‘pull’ protocol?
    • SMTP is a push protocol because it actively sends (pushes) mail to the receiving server.
    • IMAP is a pull protocol because it retrieves (pulls) emails from the server to the client.
  • (f) What is the difference between HTTP and SMTP?
    • HTTP (Hypertext Transfer Protocol):
      • Used for transferring web pages and related data over the internet.
      • Works in a client-server model, primarily for browsing websites.
    • SMTP (Simple Mail Transfer Protocol):
      • Used for transferring emails between mail servers and sending emails from clients to servers.
      • Specifically designed for email communication.
  • (g) Three major components of email:
    1. User Agent (UA): Allows users to compose, send, and read emails (e.g., Outlook, Gmail).
    2. Mail Transfer Agent (MTA): Transfers emails between servers using SMTP.
    3. Mail Delivery Agent (MDA): Delivers email to the recipient’s mailbox (e.g., using IMAP or POP3).

Exercise 3: Packet Retransmission

(a) Calculate how many packets will be re-transmitted using Go-Back-N (GB3)?

Given:

  • Total packets: 10
  • Every 5th packet is lost.

In Go-Back-N, if a packet is lost, all subsequent packets in the window are retransmitted. Assuming a window size of 3 (GB3):

  1. Packets 1–5 are sent. Packet 5 is lost, so packets 5, 6, and 7 will be retransmitted.
  2. Packets 8–10 are sent after retransmission of packet 5. No further losses occur.

Answer:

  • Packets 5, 6, and 7 are retransmitted.
  • Total retransmissions = 3.

(c) Calculate how many packets will be re-transmitted using Selective Repeat (SR) with Ws = 3.

In Selective Repeat, only the lost packet is retransmitted. Given that only the 5th packet is lost:

  • Only Packet 5 will be retransmitted.

Answer:

  • Total retransmissions = 1.