[ Pobierz całość w formacie PDF ]
Counting heads
Remember Another form of error-checking is the checksum. In this method, the oneÇs complement is
summed for all of the 16-bit words that make up the TCP segment or UDP datagram. If the segment has an
odd number of bytes, a padding byte of zeroes is added to the end of the segment. This padding byte is not
transmitted with the segment, itÇs only used for the calculation. The oneÇs complement of the calculated sum
becomes the checksum that is stored in the header and sent with the segment. At the receiving end, this same
calculation is performed and compared to the checksum value in the segment header. If the totals are unequal,
a request is sent back to the sending device to retransmit the segment.
Checking for math errors
Some protocols use the CRC number calculated on the Data Link layer (see Chapter 3) using a mathematical
calculation to create a bit profile. If the CRC calculated on the sending end of the transmission is different
from that calculated on the receiving end (using the exact same calculation), then a request is sent back asking
for retransmission of the data.
ItÇs 100 milliseconds, do you know where your data is?
In addition to the calculated error-checking methods, thereÇs another method called time-out. This method
is almost a no-brainer in that itÇs simple in its actions. After transmitting a packet, the sending device waits a
reasonable amount of time for an acknowledgment. If it doesnÇt get an acknowledgment, the packet is
69
considered lost and is retransmitted automatically. The amount of Ýwait timeÛ is determined by the time-out
mechanisms embedded into the protocol.
Going with the Flow and Staying in Control
Remember Flow control is a technique used to prevent a receiving node from getting data so fast that its
buffers overfill and data is lost. If the sending station is transmitting data faster than the receiving station can
process it, a backlog begins to grow until the storage buffers fill up and overflow. This causes new incoming
segments to be lost because there is nowhere to store them. This condition is called congestion and must be
controlled to ensure the integrity of the message being transmitted.
To prevent congestion from happening, the receiving node sends a control message to the sending node when
its buffers are almost full, telling the sending device to stop sending data. After the receiving device is able to
clear its buffers by processing some of the data, it sends a control signal to the sending node that it can begin
sending data again.
Instant Answer The three basic forms of flow control are:
" Buffering
"
Congestion avoidance
"
Windowing
Smoothing out the bumps
In the buffering method of flow control, the receiver allocates sufficient buffer (memory) space to store any
occasional bursts of excess data until it can be processed. However, in this flow control method, no attempt is
made to interrupt or slow down the data flow. If the buffers become full, any subsequent data has no place to
be stored and is discarded, resulting in the loss of data. The buffering method expands and contracts much like
a balloon, and just like the balloon, if too much is pumped in, it bursts.
Avoiding the congestion
The congestion avoidance flow control technique is similar to the buffering method, except that it uses a
more precautionary approach to managing its buffers. Under a congestion avoidance method, the receiving
device monitors its buffers to determine if theyÇre about to fill up. When the receiver notices that its buffers
are getting full, it sends a control message back to the sending device that tells it to stop sending information.
After the receiving computer has emptied its buffers, it sends another control message telling the sender that it
can start sending data again.
The advantage that the congestion avoidance technique has over the buffering method is that it prevents data
from being lost. It also helps conserve memory space by requiring smaller buffer size. Of course, the smaller
the buffers, the more often that flow will be interrupted.
Flowing through the windows
The windowing flow control method establishes a window, not like the Windows 98 kind, but a window that
allows a certain number of packets to flow through it before the receiving device must reply with an
acknowledgment. The sending device waits for acknowledgment from the receiving device after it sends out a
certain number of packets.
70
Remember The windowing methodÇs window is actually a number that represents the maximum amount of
data that can be sent until an acknowledgment is received from the destination node. The size of the window
can directly affect throughput. If an acknowledgment is required after every packet, throughput suffers
because of the amount of time used to send each acknowledgment. By increasing the size of the window,
throughput is improved and reliability is still maintained.
Quenching the source
Another flow control method used in Cisco equipment is the source-quench message, which is a kind of
hybrid technique. When the receiving nodeÇs buffer fills up and data is starting to be lost, the receiving node
sends a source-quench request to the sending node for each packet that is lost. The sending node responds by
slowing down its transmission rate until it no longer is receiving source-quench messages. The sending node
then begins to slowly increase its transmission rate until it reaches its normal speed or another source-quench
message is received.
[ Pobierz całość w formacie PDF ]