Subject: [tsvwg] L4S and MPLS

From: Bob Briscoe <[email-masked]>
Date: Wed, 29 Apr 2020 13:28:22 +0100

Uma,

Further to your query about L4S for MPLS, RFC5129 was written before two 
distinct ECT codepoints were being considered, for L4S.

Altho a network might be designed so that interior LSRs do not 
bottleneck (e.g. some sort of Clos topology), in other network designs, 
they might sometimes be a bottleneck. Then I can suggest two ways to 
handle the two distinct ECT codepoints. They both devolve the work t  a) 
the ingress, b) the egress where an MPLS header is respectively first 
pushed over an IP header or finally popped from an IP header. This would 
be in keeping with the general approach in RFC5129 of devolving ECT 
checking to the nodes around the boundary.

a) Ingress

The two ECT codepoints are effectively 2 different AQM classifiers, so I 
would suggest mapping them to two different labels at the ingress. See 
https://tools.ietf.org/html/rfc5129#section-6
Then the label selects the AQM behaviour.

b) Egress

Map to only one label at ingress and have only one (linear) L4S-ECN AQM 
behaviour on interior LSRs (generating the more frequent ECN marking 
typical of L4S). Then when an egress LSR pops the last label and finds 
an ECN field in an IP header:

 1. if the inner is ECT(1), it passes on the ECN mark to the inner IP
    packet verbatim
 2. if the inner is ECT(0) or Not-ECT, it runs a simple algorithm to
    thin the signals down to the square of their frequency of arrival
    (requires one variable of per-LSP state).

Without thinking too hard about this, the "simple algorithm" could be:
  per LSP at egress, run each arriving ECN mark (i.e. C = 0 or 1) 
through a per-packet EWMA:

     p += (C - p) >> g_shift;
     if (rand() > p && rand() > p) {    // two random comparisons 
squares the probability
            if (ECT0) mark;
            else drop;
     }

where ">>" is a bit-shift and g_shift is the (constant) gain chosen for 
the EWMA.

Longer term (or even short term) it wouldn't necessarily need to support 
ECT0. Then the algo would simplify to:

     p += (C - p) >> g_shift;
     if (rand() > p && rand() > p) // two random comparisons squares the 
probability
         drop;

I thought up the idea of two comparisons with random numbers while in 
BT, and BT decided to publish without patenting it. That publication has 
since been cited widely within the global patent system, so it has 
official recognition. Therefore no IPR declaration would be needed if we 
wrote these points up as an extension to RFC5129 for L4S.

Cheers

Bob

PS. There's a broadly similar but inside-out approach written up for 
adding L4S support to ECN support in TRILL:
https://tools.ietf.org/html/draft-ietf-trill-ecn-support-07#appendix-A
This has been sitting in the RFC-Editor queue for 2 years now, waiting 
on the L4S decision in tsvwg.

-- 
________________________________________________________________
Bob Briscoe                               http://bobbriscoe.net/