🎓 BookMCQ
← Back to 24. Transport Layer Protocols

📝 TCP error control retransmission fast recovery (21 MCQs)

Detecting Loss and Recovering Missing Stream Bytes

TCP error control uses checksums, sequence numbers, acknowledgments, and retransmission to recover from segment loss or corruption. A receiver acknowledges contiguous bytes and may report gaps through duplicate acknowledgments or SACK information. The sender retransmits missing data after a retransmission timeout or a loss indication such as multiple duplicate acknowledgments, depending on the recovery algorithm. It defines the boundary between application processes and packet delivery.

Why Detection and Recovery Are Separate Functions

A checksum can reveal corruption but cannot repair a segment, and an acknowledgment can expose missing sequence space but does not itself resend data. TCP therefore combines error detection with feedback and retransmission. Fast retransmit improves response when duplicate ACKs indicate a gap, avoiding the wait for a long retransmission timeout in suitable conditions.

Timeout, Duplicate ACK and Recovery Processing

The sender maintains a retransmission timer for outstanding data. Expiry triggers retransmission of the oldest unacknowledged segment. In classic fast retransmit, three duplicate ACKs for the same acknowledgment point indicate a likely loss, prompting immediate retransmission. Fast recovery then adjusts the congestion window according to the TCP variant rather than treating every duplicate ACK as a separate timeout.

Fast Retransmit After a Missing Middle Segment

Suppose segments carry byte ranges 1000–1999, 2000–2999, and 3000–3999. If the middle segment is lost but later data arrives, the receiver repeatedly acknowledges 2000. After three duplicate ACKs, a classic TCP sender fast-retransmits the missing range without waiting for its retransmission timer. This example makes the sequence and resulting decision explicit.

Recovery Efficiency and Variant-Specific Behaviour

Fast retransmit reduces loss-recovery delay when later segments generate duplicate ACKs. Tahoe responds to detected loss by reducing cwnd to one MSS and returning to slow start; Reno uses fast recovery for a single loss after fast retransmit. Multiple losses, reordering, and delayed feedback can complicate recovery, while an RTO remains necessary for cases without sufficient duplicate ACKs.

Misconceptions About Checksums and Fast Recovery

'A checksum automatically repairs corrupted data' is false: it detects corruption, while retransmission restores missing bytes. 'Three duplicate ACKs mean exactly three packets were lost' is false: they indicate later data arrived beyond a gap. 'Fast recovery eliminates the retransmission timer' is false: timeout recovery is still required. These distinctions separate similar mechanisms that are often confused.

Exam Focus: Loss Traces and Tahoe-Reno Reactions

Trace byte ranges, cumulative acknowledgments, duplicate ACK counts, and timeout events. Explain why three duplicate ACKs can trigger fast retransmit, then compare Tahoe's return to slow start with Reno's fast recovery for a single loss. Keep checksum detection, loss inference, retransmission, and congestion-window response as separate steps. Use the assumptions stated in each question when calculating.

Key Terms for TCP Error Control, Retransmission and Fast Recovery

  • RTO - Timeout used to trigger retransmission.
  • Duplicate ACK - Repeats the same next-byte acknowledgment.
  • Fast retransmit - Resends suspected missing data quickly.
  • Fast recovery - Adjusts cwnd after fast retransmit.
  • MSS - Maximum TCP data bytes per segment.
  • Cumulative ACK - Reports contiguous progress.
5
Easy
10
Medium
6
Hard

📝 All TCP error control retransmission fast recovery MCQs

Q1. What is the valid range of TCP/UDP port numbers used to identify processes on a host?

A.0 to 1023
B.0 to 65535 ✅
C.1024 to 49151
D.49152 to 65535
💡 Difficulty: easy | ✅ Correct: B

📖 Explanation: Port numbers are 16‑bit unsigned integers, so the full range is from 00 to 216−1=655352^{16}-1 = 65535. Values 00–10231023 are reserved for well‑known services, 10241024–4915149151 for registered applications, and 4915249152–6553565535 for dynamic or private use. Hence the complete valid range is 00 to 6553565535.

Q2. In the TCP/IP suite, what does the acronym ARQ stand for?

A.Automatic Repeat Query
B.Automatic Repeat Queue
C.Automatic Repeat Request ✅
D.Automatic Retransmission Query
💡 Difficulty: easy | ✅ Correct: C

📖 Explanation: ARQ stands for Automatic Repeat Request. It describes a family of error‑control protocols where the receiver detects missing or corrupted packets and asks the sender to retransmit them. The mechanism underlies protocols such as Stop‑and‑Wait, Go‑Back‑N, and Selective Repeat, providing reliability over unreliable networks.

Q3. If a client receives three duplicate ACKs for the same segment, what can be logically inferred about the network condition?

A.The network is experiencing high latency
B.The segment was successfully delivered
C.A packet loss has likely occurred ✅
D.The sender’s window size is too large
💡 Difficulty: medium | ✅ Correct: C

📖 Explanation: Three duplicate ACKs indicate that the receiver got a later segment but is still missing an earlier one, which suggests that the earlier packet was lost or corrupted. TCP interprets this pattern as a sign of packet loss and typically triggers fast retransmit, bypassing the normal timeout mechanism.

Q4. Setting the retransmission timeout (RTO) too low in a high‑delay network most directly impacts which performance metric?

A.Packet loss rate
B.Throughput ✅
C.Connection establishment time
D.Security of the data
💡 Difficulty: hard | ✅ Correct: B

📖 Explanation: A timeout that expires before an ACK can return causes unnecessary retransmissions, inflating the number of packets sent without delivering new data. This waste reduces the effective throughput because the sender spends time resending already‑sent segments rather than advancing the transmission window, especially detrimental in high‑delay environments.

Q5. Compare Stop‑and‑Wait ARQ with Go‑Back‑N ARQ in terms of channel utilization when the round‑trip time (RTT) is much larger than the packet transmission time. Which statement is most accurate?

A.Stop‑and‑Wait achieves higher utilization
B.Go‑Back‑N achieves higher utilization ✅
C.Both achieve equal utilization
D.Utilization depends only on error rate
💡 Difficulty: medium | ✅ Correct: B

📖 Explanation: When RTT ≫ transmission time, Stop‑and‑Wait must wait for an ACK before sending the next packet, leaving the channel idle for most of the RTT. Go‑Back‑N allows multiple packets to be in flight up to the window size, keeping the channel busy and thus achieving higher utilization despite occasional retransmissions.

Q6. Evaluating the effect of increasing the checksum size from 16 bits to 32 bits on error‑detection probability, which outcome is most likely?

A.Detection of all errors becomes guaranteed
B.Probability of undetected errors decreases exponentially ✅
C.Transmission overhead doubles, negating benefits
D.Checksum computation time becomes negligible
💡 Difficulty: hard | ✅ Correct: B

📖 Explanation: A larger checksum provides more distinct values, reducing the chance that a random error pattern maps to the same checksum. The probability of an undetected error roughly halves with each additional bit, leading to an exponential decrease, though the overhead of extra bits and computation must also be considered.

Q7. A sliding‑window protocol uses a window size of 5 and sequence numbers modulo 8. After sending packets 0‑4, which sequence number will be used for the next new packet if all acknowledgments are received?

A.5 ✅
B.6
C.0
D.1
💡 Difficulty: medium | ✅ Correct: A

📖 Explanation: With a window size of 5, the sender can have five unacknowledged packets. After ACKs for packets 0‑4 arrive, the base advances to 5, so the next new packet uses sequence number 5. Modulo‑8 arithmetic ensures the numbers wrap after 7, but in this case the next number is simply 5.

Q8. How does Selective Repeat ARQ improve performance over Go‑Back‑N ARQ when multiple packet losses occur within a window?

A.It retransmits the entire window each time
B.It only retransmits the lost packets ✅
C.It reduces the sequence number space
D.It eliminates the need for acknowledgments
💡 Difficulty: hard | ✅ Correct: B

📖 Explanation: Selective Repeat maintains a buffer of out‑of‑order packets and acknowledges each correctly received segment. When losses occur, only the missing packets are retransmitted, avoiding the wasteful retransmission of already‑received packets that Go‑Back‑N would perform. This targeted approach significantly improves throughput, especially on lossy links.

Q9. If the probability of losing a packet is pp, what is the expected number of transmissions required to successfully deliver a single packet using Stop‑and‑Wait ARQ?

A.1/p1/p
B.1/(1−p)1/(1-p) ✅
C.p/(1−p)p/(1-p)
D.1−p1-p
💡 Difficulty: medium | ✅ Correct: B

📖 Explanation: Stop‑and‑Wait repeats a packet until it is acknowledged. The probability of a successful transmission on any attempt is 1−p1-p. The expected number of attempts follows a geometric distribution with mean 1/(1−p)1/(1-p). Thus, on average 1/(1−p)1/(1-p) transmissions are needed to achieve one successful delivery.

Q10. Which of the following best differentiates a simple parity check from a CRC in detecting burst errors?

A.Parity checks detect all burst errors, CRC does not
B.CRC can detect longer burst errors than parity ✅
C.Parity uses polynomial division, CRC uses XOR
D.Both use the same detection capability
💡 Difficulty: easy | ✅ Correct: B

📖 Explanation: A parity bit only indicates whether the number of 1’s is even or odd, so it can miss many multi‑bit errors. A Cyclic Redundancy Check (CRC) employs polynomial division, allowing it to detect burst errors up to a length related to the degree of the generator polynomial, making it far more robust than simple parity.

Q11. Explain why sequence numbers are essential for detecting duplicate packets in a reliable transport protocol. Which statement captures this role?

A.They provide timing information for packets
B.They identify the sender’s IP address
C.They allow the receiver to match ACKs to specific data ✅
D.They encrypt the payload for security
💡 Difficulty: medium | ✅ Correct: C

📖 Explanation: Sequence numbers uniquely label each transmitted segment within a flow. When a receiver gets a segment, it compares the sequence number to the expected value. If the number matches a previously received segment, the packet is identified as a duplicate and discarded, preventing data corruption and ensuring ordered delivery.

Q12. When an ACK arrives at the sender before the corresponding data segment due to asymmetric paths, what can be deduced about the relative round‑trip times of the forward and reverse directions?

A.Forward path is faster than reverse
B.Reverse path is faster than forward ✅
C.Both paths have equal latency
D.ACKs are generated without data
💡 Difficulty: hard | ✅ Correct: B

📖 Explanation: If the acknowledgment reaches the sender earlier than the data segment, the reverse (ACK) path must have a shorter propagation delay than the forward (data) path. This asymmetry indicates that the reverse direction experiences lower latency, which can affect timeout calculations and congestion control strategies.

Q13. Compare TCP and UDP regarding reliability in the presence of a 5% packet loss rate. Which statement is most accurate?

A.TCP will lose the same number of packets as UDP
B.UDP provides automatic retransmission
C.TCP ensures delivery through retransmission and ordering ✅
D.Both protocols guarantee in‑order delivery
💡 Difficulty: medium | ✅ Correct: C

📖 Explanation: TCP incorporates acknowledgment, timeout, and retransmission mechanisms, so it can recover from lost packets and present data in order. UDP lacks these features; with a 5% loss rate, UDP simply discards lost packets, leading to gaps in the received data. Therefore, TCP offers higher reliability under loss conditions.

Q14. Can a 16‑bit checksum detect all single‑bit errors in a transmitted segment?

A.Yes, because any single‑bit change alters the checksum ✅
B.No, because checksum only detects even‑bit errors
C.Only if the segment length is less than 16 bits
D.It depends on the data pattern
💡 Difficulty: easy | ✅ Correct: A

📖 Explanation: A checksum is computed as the sum of all 16‑bit words, and any single‑bit flip changes the sum, resulting in a different checksum. Therefore, a 16‑bit checksum will always detect a single‑bit error, guaranteeing detection for that specific error type.

Q15. Given a sliding‑window size W=4W = 4, what is the maximum number of unacknowledged packets that can be in transit simultaneously?

A.W−1=3W-1 = 3
B.W=4W = 4 ✅
C.2W=82W = 8
D.Unlimited
💡 Difficulty: medium | ✅ Correct: B

📖 Explanation: The window size WW directly limits the number of packets that may be sent without waiting for acknowledgments. With W=4W = 4, the sender can have up to four outstanding packets in flight at any time, after which it must wait for an ACK before transmitting additional data.

Q16. Increasing the receiver’s window size improves throughput but also raises which type of resource consumption?

A.CPU cycles
B.Network latency
C.Buffer memory usage ✅
D.Encryption overhead
💡 Difficulty: hard | ✅ Correct: C

📖 Explanation: A larger window allows more packets to be sent before acknowledgments are required, boosting throughput. However, the receiver must store all out‑of‑order packets until they can be delivered in sequence, increasing the amount of buffer memory needed to hold these pending segments.

Q17. How is the TCP timeout interval typically calculated using the estimated round‑trip time (RTT) and its deviation?

A.Timeout=RTT+4×Deviation\text{Timeout} = \text{RTT} + 4 \times \text{Deviation} ✅
B.Timeout=2×RTT\text{Timeout} = 2 \times \text{RTT}
C.Timeout=RTT−Deviation\text{Timeout} = \text{RTT} - \text{Deviation}
D.Timeout=RTT/2\text{Timeout} = \text{RTT} / 2
💡 Difficulty: medium | ✅ Correct: A

📖 Explanation: TCP uses Jacobson’s algorithm: Timeout = EstimatedRTT + 4·DevRTT. The deviation captures variability in RTT measurements, and multiplying by four provides a safety margin to accommodate fluctuations, reducing premature timeouts while still reacting promptly to genuine delays.

Q18. If a cumulative ACK acknowledges up to packet 100, what can be inferred about the status of packets 101‑105?

A.They have all been received successfully
B.They are still pending or lost ✅
C.They have been discarded intentionally
D.They are being retransmitted
💡 Difficulty: easy | ✅ Correct: B

📖 Explanation: A cumulative acknowledgment indicates that all data up to the acknowledged sequence number (100) has been received in order. Packets beyond that point, such as 101‑105, have not yet been acknowledged, implying they are either still in transit, lost, or awaiting receipt.

Q19. Distinguish between positive acknowledgment (ACK) and negative acknowledgment (NACK) in error‑control protocols. Which statement correctly describes a NACK?

A.It confirms successful receipt of data
B.It requests retransmission of a specific missing segment ✅
C.It signals the end of a connection
D.It increases the sender’s window size
💡 Difficulty: medium | ✅ Correct: B

📖 Explanation: A negative acknowledgment explicitly informs the sender that a particular segment was not received or was corrupted, prompting immediate retransmission of that segment. In contrast, a positive ACK confirms successful receipt, and the sender proceeds without retransmitting the acknowledged data.

Q20. What is the primary advantage of piggybacking ACKs onto data packets in a bidirectional TCP connection?

A.It reduces the total number of packets transmitted ✅
B.It increases the size of each packet for better security
C.It eliminates the need for sequence numbers
D.It guarantees error‑free delivery
💡 Difficulty: hard | ✅ Correct: A

📖 Explanation: Piggybacking combines acknowledgment information with outgoing data, so the receiver does not need to send a separate ACK‑only segment. This consolidation reduces the overall packet count, lowers header overhead, and improves bandwidth efficiency, especially when both directions are actively transmitting data.

Q21. In a symmetric‑bandwidth network, using Selective Repeat ARQ instead of Go‑Back‑N ARQ most directly reduces which performance metric?

A.Packet loss probability
B.Round‑trip latency for lost packets ✅
C.Overall bandwidth capacity
D.Header size of packets
💡 Difficulty: medium | ✅ Correct: B

📖 Explanation: Selective Repeat allows the receiver to acknowledge correctly received packets out of order, so only the missing packets are retransmitted. This avoids the need to wait for the entire window to be resent, thereby decreasing the round‑trip latency associated with recovering from losses compared to Go‑Back‑N, which resends the whole window.

🔗 Related Topics (MCQs)