QOS- Single rate, three-color policing


Hi
all,

 

I
have a question regarding Single rate, three-color policing. 

Confirming
: - Tokens taken from BC bucket

Exceeding:
- Tokens taken from the BE bucket

Violating:
No tokens taken

 

My
question is, if there are not enough tokens in the BC bucket and not enough in
the BE bucket but combined buckets (BC+BE) there are enough tokens, will tokens
be taken from both buckets?

 

Packet
arrives 100 tokens required

BC=
70 tokens

BE=
50 tokens

 

Will
the policer take all the tokens from the BC bucket and take 30 tokens from the
BE bucket and perform the Exceeding action?

 

Many thanks

Comments

  • Dav

    Correct. 70 Tokens from BC conform and go through

    30 Tokens BE borrowed and exceed action taken.

  • Actually, more likely the conform action will be triggered. How it really works is kinda convoluted, which involves the concept of actual debt (Da) and Compounded debt (Dc). Here are the details:

    http://www.cisco.com/en/US/docs/ios/12_2/qos/configuration/guide/qcfpolsh.html

     

    EDIT:

    The above explains how CAR works, which isn't exactly related to the original question. Sorry for the wrong info!

    srTCM follows a simpler model, as deppcted in RFC 2697:

    When a packet of size B bytes arrives at time t, the following
       happens if the srTCM is configured to operate in the Color-Blind
       mode:

         o If Tc(t)-B >= 0, the packet is green and Tc is decremented by B
           down to the minimum value of 0, else

         o if Te(t)-B >= 0, the packets is yellow and Te is decremented by B
           down to the minimum value of 0, else

         o the packet is red and neither Tc nor Te is decremented.

     http://tools.ietf.org/html/rfc2697

    So, to answer the original question, given Bc of 70 and Be of 50, when a packet of 100 arrives, the violating action will be applied, while both Bc and Be will be left untouched. In reality though, both the Bc and Be should be given bigger value than the largest packet size, and Be should be given higher value than Bc.

  • The policer will not take tokens from both bc bucket and be bucket combined and the packet will be violating.

    @hs628: Even though be and bc values are configured to be bigger than the larger packet expected, you still run in to situations where there are not enough tockens in the backets to let the packet through. Well that is the whole idea about policing. no? Bc should be bigger than the largest packet is for making sure that the largest packet can be "conforming" if there are enough tokens in the bucket. A burst value less than the largest packet guanrantees that the packet will never conform.

  • @hs628: Even though be and bc values are configured to be bigger than the larger packet expected, you still run in to situations where there are not enough tockens in the backets to let the packet through.

    Absolutely. In most QoS related literature though, Bc and Be refers to the size of the comitted and excess bucket respectively, not the number of tokens left in each bucket at any given time. So yes it can cause a little confusion here.

Sign In or Register to comment.