Subject: RE: [rddp] How can we detect FPDU boundary using MPA markers?

From: "Culley, Paul" <[email-masked]>
Date: Thu, 19 Dec 2002 09:25:18 -0600

If I understand your figures correctly, you are not correctly setting the FPDUPTRs to point back to the beginning of the FPDUs.  
The 1st is FPDUPTR=400                    at seqnum=113+400=513
The 2nd is FPDUPTR=512+400-800=112        at seqnum=113+400+512=1025
The 3rd is FPDUPTR=512+512+400-800=624    at seqnum=113+400+512+512=1537

Each FPDU starts at seqnum=MarkerSeqNum-FPDUPTR so
1st FPDU starts at 513-400=113 by 1st Marker
2nd FPDU starts at 1025-112=913 by 2nd Marker
2nd FPDU starts at 1537-624=913 by 3rd Marker

I can find out the 2nd FPDU start without knowing anything about the 1st FPDU at the receiver!

Paul R. Culley (Sr. Fellow)
Hewlett-Packard Company
281-514-5543

-----Original Message-----
From: Kohta NAKASHIMA [mailto:[email-masked]]
Sent: Thursday, December 19, 2002 4:41 AM
To: [email-masked]
Cc: Kohta NAKASHIMA
Subject: [rddp] How can we detect FPDU boundary using MPA markers?

Hello,

I've heard, in order to find boundary of FPDUs or DDP header though TCP 
segments are re-segmented, the MPA markers which have a 512 octets periodic 
interval are inserted into TCP stream. I realized this is the main purpose 
of MPA marker.

As the mailing list archive before several days, if we use MPA-aware TCP and 
there is no middle box which may re-segment TCP segments, we don't need MPA 
markers, and if non-MPA-aware TCP or middle boxes which may re-segment TCP 
segments, some people say that we can detect nearest DDP header using MPA 
markers though some TCP segments are lost.

But I cannot understand how we can detect DDP header when TCP segments are 
re-segmented and some TCP segments are lost.

Please look at following 2 figures. These figures show some TCP segments, 
and show locations and values of TCP headers, MPA headers, MPA markers, and 
DDP headers into TCP segments. 

   ULPDU_Length=790(800-2-4-4)   ULPDU_Length=786(800-2-4-4-4)
               |                           |
               V                          ||
              |<-          800          ->||
            +-+-+-+----//----+-+---//---+-+|
Segment 1   |T|M|D|          |m|        |C|V
            +-+-+-+----//----+-+---//---+-|<-            800             ->|
             A|<-   400    ->|A         +-+-+-+/+-+-------//-------+-+//-+-+
Segment 2    |               ||         |T|M|D| |m|                |m|   |C|
             |               ||         +-+-+-+/+-+-------//-------+-+//-+-+
             |               |<-     512  |   ->|<-     512      ->|<-176->|
             |                |          A|      A                  A
             |                |          ||      |                  |  
     SeqNum =113(1+112)       |  SeqNum=913(113+800)                |
                              |           |      |                  |
            FPDUPTR=513(1+512*1)  FPDUPTR=1025(1+512*2)  FPDUPTR=1537(1+512*3)
                                          |
                         FPDU 1           |            FPDU 2
                                 boundary of FPDUs

  T: TCP header  M: MPA header  D: DDP header  m: Marker  C: CRC for MPA

                        Figure 1. Original TCP segments

   ULPDU_Length=790              ULPDU_Length=786
               |                           |
               V                          ||
              |<-       600         ->|   ||
            +-+-+-+----//----+-+--//--+   ||
Segment 1'  |T|M|D|          |m|      |   ||
            +-+-+-+----//----+-+--//--|<- |V    600        ->|
             A|<-   400    ->|A     +-+/+-+-+-+/+-+----//----+
Segment 2'   |               ||     |T| |C|M|D| |m|          |
             |               ||     +-+/+-+-+-+/+-+----//----|<-   400   ->|
             |               |<-     512  |   ->|A         +-+-//--+-+//-+-+
Segment 3'   |                |      A    |     ||         |T|     |m|   |C|
             |                |      |    |     ||         +-+-//--+-+//-+-+
             |                |      |    |     |<-     512      ->|<-176->| 
             |                |      |    |      |          A       A
             |                |      |    |      |          |       |  
     SeqNum =113(1+112)       |SeqNum=713(113+600) SeqNum=1313(713+600)
                              |           |      |                  |
            FPDUPTR=513(1+512*1)  FPDUPTR=1025(1+512*2)  FPDUPTR=1537(1+512*3)
                                          |
                        FPDU 1            |          FPDU 2
                                 boundary of FPDUs

  T: TCP header  M: MPA header  D: DDP header  m: Marker  C: CRC for MPA

                      Figure 2. Modified TCP segments

In Figure 1, I show that original TCP 
segments before re-segmented by middle boxes. There two TCP segments, 
the length of first segment is 800, and the length of second segment is 800.
Segment 1 has 1 MPA header (2 octets), 1 MPA marker (4 octets), and 
1 MPA CRC (4 octets), so that ULPDU_Length of Segment 1 is 790.
Segment 2 has 1 MPA header, 2 MPA markers, and 1 MPA CRC, so that ULPDU_Length 
of Segment 2 is 786.

In Figure 2, the original TCP segments in Figure 1 are re-segmented by 
middle boxes, then the original 2 TCP segments are modified to 3 TCP segments.
But the TCP stream isn't modified. Please notice that Figure 1 and Figure 2 
are different in TCP segmentation, but they have same TCP stream, so that 
location of MPA headers, DDP headers, MPA markers, and MPA CRCs aren't 
modified. (In order to notify it, I draw these figure very carefully.)

In these figures, I assumed that the MPA connection was started at TCP 
sequence number 1, and length of previous TCP segment was 112, 
thus TCP sequence number of Segment 1 is 113, and value of FPDUPTR 
in Segment 1 is 513.

In Figure 1, we can find boundary of FPDUs and DDP header 
using MPA markers, because subtracting TCP segment number(913) from 
FPDUPTR(1025), we can find that the locate of boundary is 112 octets 
before the marker. Please notice that we can find only the TCP segment 
boundary in this way. In this case, we can find it because the TCP boundary
accords with the boundary of FPDUs.

In Figure 2, I think we cannot find boundary of FPDUs and DDP header 
using MPA markers. The FPDUPTRs point to the TCP segment boundary, 
do not point to FPDU boundary in this way. In this case, if Segment 1' 
is not lost, we can find boundary of FPDUs because we find it from 
the length information which MPA header in Segment 1' has. But if Segment 1' 
is lost, we cannot find boundary of FPDUs. I think we need some information 
of location of the FPDU boundary in TCP sequence number space in this case.

If you know the way how to detect FPDU boundary using MPA markers 
without information of location of FPDU boundary, or if you find that I 
misread or misunderstand the MPA draft, please tell me it.

Thank you,

Kohta
--
Kohta NAKASHIMA, Grid Computing and Bioinformatics Laboratory,
Fujitsu Laboratories, Ltd.

_______________________________________________
rddp mailing list
[email-masked]
https://www1.ietf.org/mailman/listinfo/rddp
_______________________________________________
rddp mailing list
[email-masked]
https://www1.ietf.org/mailman/listinfo/rddp

---

From: Kohta NAKASHIMA <[email-masked]>
Date: Fri, 20 Dec 2002 10:11:27 +0900

Dear Paul,

I appreciate your replies for my questions.
I understood that I have some mistakes for calculating FPDUPTRs and I 
realized that FPDUPTR must be calculated in your way, and I found 
it in the MPA draft by re-reading it deeply.

Concluding this Q & A, we can find boundary of FPDUs in following way:

  1) The MPA markers are inserted at 512 octets periodic interval in 
     TCP sequence number space. For example, if the MPA connection was 
     started at TCP sequence number 1, the MPA markers are inserted at 
     1, 513, 1025, and 1537 in TCP sequence number space.

  2) Each marker has FPDUPTR whose value is relative sequence number 
     from the boundary of the FPDU, so that value of FPDUPTR is 
     calculated by subtracting the sequence number of the FPDUs boundary 
     from the sequence number of the marker. For example, if a MPA marker 
     in a FPDU which start at 913 in TCP sequence number space and the 
     MPA marker is at 1025, the FPDUPTR of the marker is 112(=1025-913).

  3) We can easily find MPA markers because they are located at 512 octets 
     periodic interval, and we can find the boundary of FPDU by subtracting 
     the FPDUPTR from the location of MPA. For example, If a MPA marker 
     whose FPDUPTR is 112 is located at 1025, the FPDU includes the marker 
     starts at 913(=1025-112).

Thank you very much for your answer, and I can understand it very well!

Thank you,

Kohta

On Thu, 19 Dec 2002 09:25:18 -0600