NAME

  FastRetranFirstData.seq - Restart T3-rtx timer if the endpoint is retransmitting the first outstanding DATA chunk


PURPOSE

  To chech that the endpoint should restart the T3-rtx timer if the
  endpoint is retransmitting the first outstanding DATA chunk sent
  to that address.


SYNOPSIS

  ./FastRetranFirstData.seq [-tooloption ...] -pkt ./FastRetranFirstData.def
    -tooloption : v6eval tool option
  See Also: ../common/STD_PKT_COMMON.def
            ../common/SCTP_COMMON.def


PRE-TEST CONDITION

  Association is established between endpoint A and B. Arrange data 
  in endpoint B such that messages is sent to endpoint A.


TEST PROCEDURE

  Endpoint A                           Endpoint B 
  (ESTABLISHED)                        (ESTABLISHED)
                <----------------       DATA 1
                <----------------       DATA 2
                <----------------       DATA 3
                <----------------       DATA 4
  SACK          ----------------->
  (For DATA 2)
  SACK          ----------------->
  (For DATA 2 and DATA 3)
  SACK          ----------------->
  (For DATA 2 to DATA 4)
                <----------------       DATA 1
  SACK          ----------------->
  (For DATA 1 to DATA 4)
                <----------------       DATA 5
  SACK          ----------------->
  TEST DESCRIPTION:
  1. Check A: the initial cwnd before DATA transmission is set to 4380.
  2. From endpoint B, send valid DATA message 4 times to endpoint A,
     when there is association between them.
  3. From endpoint A, receive DATA message 4 times.
  4. From endpoint A, send SACK of the 2nd DATA messages to endpoint 
     B, report the 1st message is missing.
  5. From endpoint A, send SACK of the 2nd, 3rd DATA messages to 
     endpoint B, report the 1st message is missing.
  6. From endpoint A, send SACK of the 2nd, 3rd and 4th DATA messages
     to endpoint B, report the 1st message is missing.
  7. Check B: The 1st DATA messages is send again immediately.
  8. Check C: Congestion control window is 6000 now.


NOTE

  None


REFERENCE

  RFC 4960
  7.2.4.  Fast Retransmit on Gap Reports
    In the absence of data loss, an endpoint performs delayed
    acknowledgement.  However, whenever an endpoint notices a hole in the
    arriving TSN sequence, it SHOULD start sending a SACK back every time
    a packet arrives carrying data until the hole is filled.
    Whenever an endpoint receives a SACK that indicates that some TSNs
    are missing, it SHOULD wait for two further miss indications (via
    subsequent SACKs for a total of three missing reports) on the same
    TSNs before taking action with regard to Fast Retransmit.
    Miss indications SHOULD follow the HTNA (Highest TSN Newly
    Acknowledged) algorithm.  For each incoming SACK, miss indications
    are incremented only for missing TSNs prior to the highest TSN newly
    acknowledged in the SACK.  A newly acknowledged DATA chunk is one not
    previously acknowledged in a SACK.  If an endpoint is in Fast
    Recovery and a SACK arrives that advances the Cumulative TSN Ack
    Point, the miss indications are incremented for all TSNs reported
    missing in the SACK.
    When the third consecutive miss indication is received for a TSN(s),
    the data sender shall do the following:
    1)  Mark the DATA chunk(s) with three miss indications for
        retransmission.
    2)  If not in Fast Recovery, adjust the ssthresh and cwnd of the
        destination address(es) to which the missing DATA chunks were
        last sent, according to the formula described in Section 7.2.3.
    3)  Determine how many of the earliest (i.e., lowest TSN) DATA chunks
        marked for retransmission will fit into a single packet, subject
        to constraint of the path MTU of the destination transport
        address to which the packet is being sent.  Call this value K.
        Retransmit those K DATA chunks in a single packet.  When a Fast
        Retransmit is being performed, the sender SHOULD ignore the value
        of cwnd and SHOULD NOT delay retransmission for this single
        packet.
    4)  Restart the T3-rtx timer only if the last SACK acknowledged the
        lowest outstanding TSN number sent to that address, or the
        endpoint is retransmitting the first outstanding DATA chunk sent
        to that address.
    5)  Mark the DATA chunk(s) as being fast retransmitted and thus
        ineligible for a subsequent Fast Retransmit.  Those TSNs marked
        for retransmission due to the Fast-Retransmit algorithm that did
        not fit in the sent datagram carrying K other TSNs are also
        marked as ineligible for a subsequent Fast Retransmit.  However,
        as they are marked for retransmission they will be retransmitted
        later on as soon as cwnd allows.
    6)  If not in Fast Recovery, enter Fast Recovery and mark the highest
        outstanding TSN as the Fast Recovery exit point.  When a SACK
        acknowledges all TSNs up to and including this exit point, Fast
        Recovery is exited.  While in Fast Recovery, the ssthresh and
        cwnd SHOULD NOT change for any destinations due to a subsequent
        Fast Recovery event (i.e., one SHOULD NOT reduce the cwnd further
        due to a subsequent Fast Retransmit).
    Note: Before the above adjustments, if the received SACK also
    acknowledges new DATA chunks and advances the Cumulative TSN Ack
    Point, the cwnd adjustment rules defined in Section 7.2.1 and Section
    7.2.2 must be applied first.
    A straightforward implementation of the above keeps a counter for
    each TSN hole reported by a SACK.  The counter increments for each
    consecutive SACK reporting the TSN hole.  After reaching 3 and
    starting the Fast-Retransmit procedure, the counter resets to 0.
    Because cwnd in SCTP indirectly bounds the number of outstanding
    TSN's, the effect of TCP Fast Recovery is achieved automatically with
    no adjustment to the congestion control window size.