ch03 IP Addressing.pdf - The Cisco Learning Network
ch03 IP Addressing.pdf - The Cisco Learning Network
ch03 IP Addressing.pdf - The Cisco Learning Network
Create successful ePaper yourself
Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.
6 Chapter 3: <strong>IP</strong> <strong>Addressing</strong><br />
2. Destination responds with a SYN/ACK: sequence number = 10,<br />
acknowledgement = 2<br />
3. Source responds with an ACK segment: sequence number = 2,<br />
acknowledgement = 11<br />
TCP uses a three-way<br />
handshake to set up a reliable connection:<br />
SYN, SYN/ACK, and ACK.<br />
In this example, the destination’s<br />
acknowledgment (step 2) is one greater than<br />
the source’s sequence number, indicating to the<br />
source that the next segment expected is 2.<br />
In the third step, the source sends the second<br />
segment, and, within the same segment in the<br />
Acknowledgement field, indicates the receipt<br />
of the destination’s segment with an acknowledgment of 11--one greater than<br />
the sequence number in the destination’s SYN/ACK segment. This process was<br />
described in Chapter 2.<br />
Windowing TCP allows the regulation of the flow of segments, ensuring that<br />
one device doesn’t flood another device with too many segments. TCP uses a sliding<br />
windowing mechanism to assist with flow control. For example, if you have a window<br />
size of 1, a device can send only one segment, and then must wait for a corresponding<br />
acknowledgement before sending the next segment. If the window size is 20, a device<br />
can send 20 segments and then has to wait for an acknowledgment before sending 20<br />
additional segments.<br />
<strong>The</strong> larger the window size is for a connection, the less acknowledgments that<br />
are sent, thus making the connection more efficient. Too small a window size can<br />
affect throughput, since a device has to send a small number of segments, wait for an<br />
acknowledgment, send another bunch of small segments, and wait again. <strong>The</strong> trick<br />
is to figure out an optimal window size: one that allows for the best efficiency based<br />
on the current conditions in the network and on the two devices.<br />
TCP employs a positive<br />
acknowledgement with retransmission (PAR)<br />
mechanism to recover from lost segments.<br />
<strong>The</strong> same segment will be repeatedly resent,<br />
with a delay between each segment, until<br />
an acknowledgement is received from the<br />
destination. <strong>The</strong> acknowledgement<br />
contains the sequence number of the<br />
segment received and verifies receipt of<br />
all sent prior segments. This eliminates the<br />
need for multiple acknowledgements and<br />
resending acknowledgements.