Re: [Idr] One question about "Terminal Action bit" in RFC5575

Christoph Loibl <c@tix.at> Wed, 14 December 2016 10:59 UTC

Return-Path: <c@tix.at>
X-Original-To: idr@ietfa.amsl.com
Delivered-To: idr@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id DC88C129D30; Wed, 14 Dec 2016 02:59:19 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.599
X-Spam-Level:
X-Spam-Status: No, score=-2.599 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_LOW=-0.7] autolearn=ham autolearn_force=no
Received: from mail.ietf.org ([4.31.198.44]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id SzDH0DErfRXW; Wed, 14 Dec 2016 02:59:17 -0800 (PST)
Received: from mail.hated.at (mail.hated.at [86.59.35.235]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id B03FA129D31; Wed, 14 Dec 2016 02:59:15 -0800 (PST)
Received: from 80-110-80-178.cgn.dynamic.surfer.at ([80.110.80.178] helo=[192.168.66.245]) by mail.hated.at with esmtpsa (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.69) (envelope-from <c@tix.at>) id 1cH77f-0003iZ-1v; Wed, 14 Dec 2016 11:49:21 +0100
From: Christoph Loibl <c@tix.at>
Message-Id: <5DB3C819-FEAE-48A7-A755-E1683E410D16@tix.at>
Content-Type: multipart/alternative; boundary="Apple-Mail=_B0A33760-352C-41EC-9FFD-72861888968F"
Mime-Version: 1.0 (Mac OS X Mail 10.1 \(3251\))
Date: Wed, 14 Dec 2016 11:58:53 +0100
In-Reply-To: <OF716322A9.48ACEC54-ON48258089.002B5092-48258089.00316E72@zte.com.cn>
To: zhang.zheng@zte.com.cn
References: <OF716322A9.48ACEC54-ON48258089.002B5092-48258089.00316E72@zte.com.cn>
X-Mailer: Apple Mail (2.3251)
Archived-At: <https://mailarchive.ietf.org/arch/msg/idr/ocEWmA5MKPBo9FH_1Znat_AR2CQ>
Cc: zhu.xiaolong@zte.com.cn, idr@ietf.org, robert@raszuk.net, shen.yiming@zte.com.cn, Idr <idr-bounces@ietf.org>, zhu.tong@zte.com.cn
Subject: Re: [Idr] One question about "Terminal Action bit" in RFC5575
X-BeenThere: idr@ietf.org
X-Mailman-Version: 2.1.17
Precedence: list
List-Id: Inter-Domain Routing <idr.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/idr>, <mailto:idr-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/idr/>
List-Post: <mailto:idr@ietf.org>
List-Help: <mailto:idr-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/idr>, <mailto:idr-request@ietf.org?subject=subscribe>
X-List-Received-Date: Wed, 14 Dec 2016 10:59:20 -0000

Hi,

Your example perfectly makes sense to me, and I understand that there are several sections in RFC5575 that are a little unclear. RFC5575 does not explain what should happen in your case, nor does it explain anything in case of action-interference.

This is why we currently working on a rfc557bis that should help us to fix those problems and improve interoperability for flowspec. Have a look at:

https://datatracker.ietf.org/doc/draft-hr-idr-rfc5575bis/ <https://datatracker.ietf.org/doc/draft-hr-idr-rfc5575bis/>
Section 7.6. Rules on Traffic Action Interference

During writing this section we were actually discussing single flowspec NLRIs with conflicting actions like:

rule 1
    traffic-rate: 10Mbps
    traffic-rate: 20Mbps

or

rule 1
   redirect: A
   redirect: B

I think we shall extend this section to also explain your case. Currently this is not explained even in our submitted draft draft-hr-idr-rfc5575bis <https://datatracker.ietf.org/doc/draft-hr-idr-rfc5575bis/> latest revision. In that case it may make sense to have a "latest" action wins behaviour. I suggest the following behaviour (this is nowhere written yet):

Suggestion: In your example the action for a flow matching all your rules should be a merge of rule 1 and rule 2:

> rule 1 
> 
>    traffic-rate: 10Mbps 
> 
>    traffic-marking: DSCP=10 
> 
>    traffic-action: T=1 S=1 
> 

after this rule 2 gets applied

> 
> rule 2 
> 
>    traffic-rate: 20Mbps 
> 
>    redirect: nexthop = 192.168.1.2 
> 
>    traffic-action: T=0 S=0 
> 


The resulting action for that flow is:

    traffic-rate: 20Mbps
    traffic-marking: DSCP=10
    redirect: nexthop = 192.168.1.2

Since on the second rule the terminal-bit is 0 there is no other rule to be evaluated.

To the "latest" applied action wins. However this is only one suggested behaviour. There are plenty of other options. It should also be considered that implementing such a behaviour may not be trivial.

Christoph


> On 14 Dec 2016, at 09:59, zhang.zheng@zte.com.cn wrote:
> 
> 
> Hi all, 
> 
>     About RFC5575, it seems like that the definition of "Terminal 
> Action bit" is blurred. 
> 
>     In section 7, the "Terminal Action bit" is defined as follows: 
> Terminal Action (bit 47): When this bit is set, the traffic filtering 
> engine will apply any subsequent filtering rules (as defined by the 
> ordering procedure).  If not set, the evaluation of the traffic filter 
> stops when this rule is applied. 
> 
>     How can routers do when many rules that define variant actions 
> are applied to a same flow? 
> 
>    For example, there are four rules that can be applied to one same flow. 
> And the sequence has been determined as below. When router executes rule 1, 
> the "Terminal Action Bit" is set. It indicated that next rule should be 
> executed. When router execute rule 2, which action should be executed? 
> Only redirect? Or/and traffic-marking? Which traffic-rate should be 
> selected? 
> 
> rule 1 
> 
>    traffic-rate: 10Mbps 
> 
>    traffic-marking: DSCP=10 
> 
>    traffic-action: T=1 S=1 
> 
> 
> rule 2 
> 
>    traffic-rate: 20Mbps 
> 
>    redirect: nexthop = 192.168.1.2 
> 
>    traffic-action: T=0 S=0 
> 
> 
> rule 3 
> 
>    traffic-rate: 30Mbps 
> 
>    traffic-marking: DSCP=30 
> 
>    redirect: nexthop = 192.168.2.2 
> 
>    traffic-action: T=1 S=1   
>                   
> 
> rule 4 
> 
>    traffic-rate: 40Mbps 
> 
>    traffic-marking: DSCP=40 
> 
>    traffic-action: T=0 S=0 
> 
> _______________________________________________
> Idr mailing list
> Idr@ietf.org
> https://www.ietf.org/mailman/listinfo/idr

-- 
Christoph Loibl
c@tix.at <mailto:c@tix.at> | CL8-RIPE | PGP-Key-ID: 0x4B2C0055 | http://www.nextlayer.at <http://www.nextlayer.at/>