Theory-of-Computation
October 9, 2023
Data-Structures
October 9, 2023
Theory-of-Computation
October 9, 2023
Data-Structures
October 9, 2023

Computer-Networks

Question 4
A TCP server application is programmed to listen on port number P on host S. A TCP client is connected to the TCP server over the network.

Consider that while the TCP connection was active, the server machine S crashed and rebooted. Assume that the client does not use the TCP keepalive timer.

Which of the following behaviours is/are possible?

A
If the client was waiting to receive a packet, it may wait indefinitely.
B
If the client sends a packet after the server reboot, it will receive a RST segment.
C
The TCP server application on S can listen on P after reboot.
D
If the client sends a packet after the server reboot, it will receive a FIN segment.
Question 4 Explanation: 
  1. True
    Since broken connections can only be detected by sending data, the receiving side will wait forever. This scenario is called a “half-open connection” because one side realizes the connection was lost but the other side believes it is still active.
  2. True
    The situation resolves itself when client tries to send data to server over the dead connection, and server replies with an RST packet (not FIN).
  3. True
    Yes, a TCP Server can listen to the same port number even after reboot.  For example, the SMTP service application usually listens on TCP port 25 for incoming requests. So, even after reboot the port 25 is assigned to SMTP.
  4. False
    The situation resolves itself when client tries to send data to server over the dead connection, and server replies with an RST packet (not FIN), causing client to finally to close the connection forcibly.
    FIN is used to close TCP connections gracefully in each direction (normal close of connection), while TCP RST is used in a scenario where TCP connections cannot recover from errors and the connection needs to reset forcibly.
Correct Answer: C
Question 4 Explanation: 
  1. True
    Since broken connections can only be detected by sending data, the receiving side will wait forever. This scenario is called a “half-open connection” because one side realizes the connection was lost but the other side believes it is still active.
  2. True
    The situation resolves itself when client tries to send data to server over the dead connection, and server replies with an RST packet (not FIN).
  3. True
    Yes, a TCP Server can listen to the same port number even after reboot.  For example, the SMTP service application usually listens on TCP port 25 for incoming requests. So, even after reboot the port 25 is assigned to SMTP.
  4. False
    The situation resolves itself when client tries to send data to server over the dead connection, and server replies with an RST packet (not FIN), causing client to finally to close the connection forcibly.
    FIN is used to close TCP connections gracefully in each direction (normal close of connection), while TCP RST is used in a scenario where TCP connections cannot recover from errors and the connection needs to reset forcibly.
0 0 votes
Article Rating
Subscribe
Notify of
0 Comments
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x