Final answer:
The rdt 2.1 sender retransmits the last packet when it encounters a garbled ACK/NAK, ensuring the integrity of the data transfer in the face of possible transmission errors.
Step-by-step explanation:
When dealing with garbled ACK/NAK, the rdt 2.1 sender retransmits the last packet. This protocol is designed under the assumption that errors may occur in the transmission or acknowledgment (ACK/NAK) packets. Rather than simply waiting for the next ACK/NAK or terminating the connection, the sender assumes that an error has occurred and takes action to maintain the integrity of the data transfer.
The protocol works as follows: When the rdt 2.1 sender sends a packet, it starts a timer and waits for an acknowledgment. If an ACK is received and it is not garbled, the sender knows that the packet has been successfully received and will continue to the next packet. However, if a NAK is received or the ACK/NAK is garbled (meaning it has been corrupted in transit), the sender cannot know if the previous packet was received correctly. To ensure reliable transmission, the rdt 2.1 will retransmit the last packet, starting the process again and ensuring that data is not mistakenly thought to have been transmitted successfully.