Re: CB Policing with Be and Without Violate Action

From: gladston@br.ibm.com
Date: Fri Jul 01 2005 - 16:06:30 GMT-3


Simon,

Giving it a second though I got confused with the follwowing:

You said that using drop for exceed action is strange because even though
there is tokens on Be packets will be dropped. First time I read I makes a
lot of sense.
But thinking about it again, any action for exceed and Be has no sense (if
 violate action is not used), because anything above Bc will exceed for CB
shaping.

If the keyword violate is not used, I expected CB Policing do something
similar to CAR (even considering they use algorithm and CAR uses Da/Dc).
That is, if the exceed action is 'drop' (when violate is not used) I
expected CB policing used tokens on Be.
But your post made me thing again about it and read again Wendell.

So, comparing with CAR:

CAR
rate-limit output 64000 8000 9000 conform transmit exceed drop <---- on
T0, when 10 packets (1000bytes) arrive, Bc is used to transmit 8 packets
and Be is used to transmit 1 packet.

CB Police without violate
Police cir 64000 bc 8000 be 1000 conform transmit exceed drop <---- on T0,
when 10 packets (1000bytes) arrived, Bc is used to transmit 8 packets and
then....everything above is discarded.

So, there is only sense to use CB Police without the keyword Violate if
the exceed action is anything but Drop. (as you pointed)
But, if that is true, there is no sense to use a value for Be even if the
action is other than Drop, because everything above 8 packets on this
example (no matter if Be is 1000 or 100000) will follow the exceed action.

Would you agree?

Cordially
------------------------------------------------------------------
 Gladston

SIMON HART <simon.hart@btinternet.com>
01/07/2005 10:23

To
SIMON HART <simon.hart@btinternet.com>, Alaerte Gladston
Vidali/Brazil/IBM@IBMBR, ccielab@groupstudy.com
cc

Subject
Re: CB Policing with Be and Without Violate Action

Sorry, I have noticed a mistake on example 4, should
read

At Tc4
Offered packets 10
In contract first 8 packets - transmit
Remaining 2 packets - try and use Be
Decrement Be by 1 token
Take exceed action on Be - set the dscp of af13

Violate action - drop - therefore drop the remaining
packet.

HTH

Simon

--- SIMON HART <simon.hart@btinternet.com> wrote:

> Hi Gladston,
>
> CB Policing without violate action is valid. Your
> configs below, however, do not make a great deal of
> sense. I shall try and explain.
>
> Police cir 64000 bc 8000 be 1000
>
> Now this statement dictates that we can transmit
> conforming bits at a rate of 64000 bits (8000bytes)
> every second. So our Tc is 1 second. The statement
> also suggests that during any Tc interval of 1
> second
> we can send an additional 8000 bits (1000bytes), if
> the be bucket has not been used up.
>
> Now in order to explore this further we need to make
> some assumptions. Firstly lets assume that the
> packets offered are 1000bytes (8000 bits).
>
> Therefore for each Tc we can transmit 64000/8000 = 8
> packets that conform.
>
> We need to determine the actions for conforming and
> non-conforming traffic
>
> so in your config:
>
> conform-action transmit
> exceed-action drop
> violate-action drop
>
>
> Example 1
>
> Now look at what happens as packets are offered
>
> At Tc0
>
> Bc = 8 packets
> Be = 1 packet
>
> At Tc1 (end of first period)
> Offered packets 9
> In contract first 8 packets - transmit
> Remaining 1 packet - try and use Be
> Decrement Be by 1 token
> Take action on Be - in this case drop, therefore
> packet is dropped.
>
> At Tc2
> Offered packets 10
> In contract first 8 packets - transmit
> Remaining 2 packets - try and use Be
> Be = 0
> therefore take Violate action - which is drop
> remaining packets
>
> At Tc3
> Offered packets 5
> In contract first 5 packets - transmit
> Because Bc has not been fully used (3 tokens spare)
> We can now add 1 token to Be
>
> At Tc4
> Offered packets 10
> In contract first 8 packets - transmit
> Remaining 2 packets - try and use Be
> Decrement Be by 1 token
> Take exceed action on Be - in this case drop,
> therefore packet is dropped.
> 1 packet now violates - take violate action -
> therefore drop this packet.
>
> Hopefully from the above example you can see that Be
> is not really being used for any purpose. This is
> because the Be action is the same as the violate
> action, and hence any non-conforming packets will be
> dropped.
>
>
> Example 2
>
> Now see what happens when we remove the violate
> action
> on the previous example.
>
> At Tc0
>
> Bc = 8 packets
> Be = 1 packet
>
> At Tc1 (end of first period)
> Offered packets 9
> In contract first 8 packets - transmit
> Remaining 1 packet - try and use Be
> Decrement Be by 1 token
> Take action on Be - in this case drop, therefore
> packet is dropped.
>
> At Tc2
> Offered packets 10
> In contract first 8 packets - transmit
> Remaining 2 packets - try and use Be
> Be = 0
> No violate action - however therefore take Be action
> -
> drop packets
>
> At Tc3
> Offered packets 5
> In contract first 5 packets - transmit
> Because Bc has not been fully used (3 tokens spare)
> We can now add 1 token to Be
>
> At Tc4
> Offered packets 10
> In contract first 8 packets - transmit
> Remaining 2 packets - try and use Be
> Decrement Be by 1 token
> Take exceed action on Be - in this case drop,
> therefore packet is dropped.
> No violate action, therefore take exceed action -
> which is drop the remaining packet.
>
>
> Example 3
>
> This time we have no violate action and the exceed
> action is set-dscp to af13
>
> exceed-action set-dscp-transmit af13
>
> At Tc0
>
> Bc = 8 packets
> Be = 1 packet
>
> At Tc1 (end of first period)
> Offered packets 9
> In contract first 8 packets - transmit
> Remaining 1 packet - try and use Be
> Decrement Be by 1 token
> Take action on Be - transmit with dscp of af13
>
> At Tc2
> Offered packets 10
> In contract first 8 packets - transmit
> Remaining 2 packets - try and use Be
> Be = 0
> No violate action - however therefore take Be action
> -
> transmit with dscp of af13
>
> At Tc3
> Offered packets 5
> In contract first 5 packets - transmit
> Because Bc has not been fully used (3 tokens spare)
> We can now add 1 token to Be
>
> At Tc4
> Offered packets 10
> In contract first 8 packets - transmit
> Remaining 2 packets - try and use Be
> Decrement Be by 1 token
> Take exceed action on Be - set dscp of af13
> No violate action, therefore take exceed action -
> which is transmit with dscp of af13
>
> In this example it should be clear that the class is
> no longer policed as all traffic is transmitted,
> however the out of contract traffic (everything
> above
> cir) will be marked as af13.
>
>
> Example 4
>
> One final example to round this off.
>
> We shall use an exceed action that sets dscp and a
> violate action that drops packets
>
> exceed-action set-dscp-transmit af13
> violate-action drop
>
> At Tc0
>
> Bc = 8 packets
> Be = 1 packet
>
> At Tc1 (end of first period)
> Offered packets 9
> In contract first 8 packets - transmit
> Remaining 1 packet - try and use Be
> Decrement Be by 1 token
> Take action on Be - transmit with dscp of af13
>
> At Tc2
> Offered packets 10
> In contract first 8 packets - transmit
>
=== message truncated ===



This archive was generated by hypermail 2.1.4 : Sun Sep 04 2005 - 17:00:29 GMT-3