What is out of order packets?

What is out of order?

IP can choose another path for traffic (e.g., that is faster) without having to worry about the consequences that doing so may cause traffic freshly injected into the network to pass ahead of older traffic, resulting in the order of packet arrivals at the receiver not matching the order of transmission at the sender.

The reason of reordering:

TCP is a robust protocol to depend on, even the application will rely on it. So for the prevention of the data corruption caused by out-of-order issue, TCP packets should be marked with number and reordering.


Packet out of order reason:

  1. Asymmetric Routing
  2. Router internal process related (parallel computing, some packet might take longer time to process compared with other packets)


The different effect on TCP as does reordering of ACK packets:

  • If reordering takes place in reverse(ACK) direction, it causes the sending TCP to receive some ACKs that move the window significantly forward followed by some evidently old redundant ACKs that are discarded. This can lead to an unwanted burstiness (instantaneous high-speed sending) behavior in the sending pattern of TCP and also trouble in taking advantage of available network bandwidth, because of the behavior of TCP’s congestion control.
  • If reordering occurs in the forward direction, TCP may have trouble distinguishing this condition from loss. Both loss and reordering result in the receiver receiving out-of-order packets that create holes between the next expected packet and the other packets received so far. When reordering is moderate (e.g., two adjacent packets switch order), the situation can be handled fairly quickly. When reorderings are more severe, TCP can be tricked into believing that data has been lost even though it has not. This can result in spurious retransmissions, primarily from the fast retransmit algorithm.


Recall from previous discussions that the fast retransmit algorithm relies on observing duplicate acknowledgments from a TCP receiver in order to infer the loss of a packet and to initiate a retransmission without having to wait for a retransmission timer to expire. Because a TCP receiver is supposed to immediately ACK any out-of-sequence data it receives in order to help induce fast retransmit to be triggered on packet loss, any packet that is reordered within the network causes a receiver to produce a duplicate ACK. If fast retransmit were to be invoked whenever any duplicate ACK is received at the sender, a large number of unnecessary retransmissions would occur on network paths where a small amount of reordering is common. To handle this situation, fast retransmit is triggered only after the duplicate threshold (dupthresh) has been reached.



The left portion of the figure indicates how TCP behaves with light reordering, where dupthresh is set to 3. In this case, the single duplicate ACK does not affect TCP. It is effectively ignored and TCP overcomes the reordering.

The right-hand side indicates what happens when a packet has been more severely reordered. Because it is three positions out of sequence, three duplicate ACKs are generated. This invokes the fast retransmit procedure in the sending TCP, producing a duplicate segment at the receiver.

The problem of distinguishing loss from reordering is not trivial. Dealing with it involves trying to decide when a sender has waited long enough to try to fill apparent holes at the receiver. Fortunately, severe reordering on the Internet is not common, so setting dupthresh to a relatively small number (such as the default of 3) handles most circumstances. That said, there are a number of research projects that modify TCP to handle more severe reordering. Some of these adjust dupthresh dynamically, as does the Linux TCP implementation.


Packet analysis for the out of order scenario:

Out of order issue happens when the sender sent the next frame to the receiver contains a Seq number not match previous frame’s Seq plus Len number the sender sent.






Referenced Links and documents:


  • TCP.IP.Illustrated.Volume.1.2nd.Edition
  • TCP/IP Analysis and Troubleshooting Toolkit

3 thoughts on “What is out of order packets?

Leave a Reply

Your email address will not be published. Required fields are marked *