Question:

Suppose in a web browser you click on www.gate-2023.in. The browser cache is empty. The DNS address is not cached, so an iterative DNS lookup across 3 tiers is required. Let RTT denote the round trip time between your host and either a DNS server or the web server. RTT between local host and web server is also equal to RTT. The HTML page is very small and references 10 small objects from the same server. Neglect transmission and rendering time. Which of the following statements is/are CORRECT about the minimum elapsed time between clicking the URL and full rendering?

Show Hint

Total page time = DNS RTTs $+$ (TCP handshake $+$ first request/response) $+$ embedded-object phase, where the last term depends on non-persistent vs persistent and whether pipelining/parallelism is used.
Updated On: Aug 26, 2025
  • 7 RTTs, in case of non-persistent HTTP with 5 parallel TCP connections.
  • 5 RTTs, in case of persistent HTTP with pipelining.
  • 9 RTTs, in case of non-persistent HTTP with 5 parallel TCP connections.
  • 6 RTTs, in case of persistent HTTP with pipelining.
Hide Solution
collegedunia
Verified By Collegedunia

The Correct Option is C

Solution and Explanation

Step 1: DNS lookup.
Iterative DNS resolution across the 3 tiers (root, TLD, authoritative) takes 3 RTTs.
Step 2: Fetch the base HTML file.
Open TCP connection (3-way handshake): 1 RTT.
Send HTTP request and receive the small HTML response: 1 RTT.
Total before parsing embedded objects: $3+1+1=5$ RTTs.
Step 3: Fetch 10 small embedded objects.
\underline{Case (C): Non-persistent HTTP with 5 parallel TCP connections.}
Each object requires a fresh connection: 1 RTT for handshake $+$ 1 RTT for request/response $\Rightarrow$ 2 RTTs per connection.
With 5 parallel connections, 5 objects finish in 2 RTTs; the remaining 5 objects finish in another 2 RTTs.
Extra time for objects = 4 RTTs; overall time = $5+4=9$ RTTs.
\underline{Case (D): Persistent HTTP with pipelining.}
Reuse the already-open connection; after HTML arrives, pipeline all 10 GETs back-to-back.
All responses return in 1 RTT (neglecting transmission time).
Overall time = $5+1=6$ RTTs.
Step 4: Eliminate the other options.
(A) 7 RTTs is too small for non-persistent with 5 parallel TCP connections (needs 4 RTTs for the 10 objects after the initial 5 RTTs).
(B) 5 RTTs ignores the extra RTT needed to get the embedded objects even with persistent pipelining.
\[ \boxed{\text{Correct statements: (C) and (D)}} \]
Was this answer helpful?
0
0

Questions Asked in GATE CS exam

View More Questions