Skip to main content

GATE CSE 2024Computer Networks › Data Link Layer, MAC Protocols & Error DetectionVerified

GATE CSE 2024 PYQ: ​Node X \text{X} X has a TCP \text{TCP} TCP connection open to node Y \text{Y} Y . The packets from X…

​Node X\text{X} has a TCP\text{TCP} connection open to node Y\text{Y}. The packets from X\text{X} to Y\text{Y} go through an intermediate IP\text{IP} router R\mathrm{R}. Ethernet switch S\mathrm{S} is the first switch on the network path between X\mathrm{X} and R\mathrm{R}. Consider a packet sent from X\mathrm{X} to Y\mathrm{Y} over this connection.

Which of the following statements is/are TRUE about the destination IP\text{IP} and MAC\text{MAC} addresses on this packet at the time it leaves X\mathrm{X}?

  1. A
    The destination IP\text{IP} address is the IP\text{IP} address of R\text{R}
  2. B
    The destination IP\text{IP} address is the IP\text{IP} address of Y\text{Y}
    Correct answer
  3. C
    The destination MAC\text{MAC} address is the MAC\text{MAC} address of S\mathrm{S}
  4. D
    The destination MAC\text{MAC} address is the MAC\text{MAC} address of Y\mathrm{Y}

Answer

(B) The destination IP \text{IP} IP address is the IP \text{IP} IP address of Y \text{Y} Y

Approach

At the network layer, the IP destination address is end-to-end and therefore remains Y's IP address throughout the journey. At the data-link layer, the destination MAC address is hop-by-hop and identifies the next device that should receive the frame, which on X's local link is the default gateway/router R, not switch S and not end host Y.

Only the destination IP address is preserved end-to-end and equals Y's IP address. The destination MAC address on the first hop is the MAC address of the router R, not the switch S or the final host Y. Hence option B alone is correct.

Reviewed by GateIQ Editorial Team: IIT & IISc Alumni.