Policing is allowed to borrow future traffic credits but Shaping is not ?

Hi everybody

 

I was reading these slides about Shaping and Policing

On slide number three it is said that:

 

1)Policing is allowed to borrow future traffic credits and pay them back

2) Shaping instead uses existing credits and is not allowed to pay back

The second statement makes sense for me but I don't quite understand the second one. By my understanding Policing buckets refresh at a 1/CIR (and 1/EIR)  and that means existing credit too which contradicts the first statement from above.

Could anybody help me with this ?

thanks a lot

Cristian

Comments

  • When talking about shaping we have Tc = Bc/CIR. Tc is the time interval and defines when tokens are being replenished. If we have VoIP traffic it is important to have a low Tc so that VoIP packets don't get stuck too long behind large data packets. If we look at a graph of shaping it will be a smooth curve with the graph closely following the shaped bandwidth if the circuit is being used to 100% Excess traffic is buffered until buffers fill and then there will be tail drop.

    In policing Tc is not used to replenish tokens at a fixed interva. Instead when packets arrive the policer looks at the interval between the packets and calculates if enough tokens have been replenished to send the packet. If not, it is dropped. This means that if we look at a graph it will not be as smooth as traffic is being dropped instantly instead of put into buffers.

    Shaping traffic does not automatically mean that sending over Bc is allowed, so I don't agree that we are borrowing credits. We are just keeping packets in buffer until we have credits, this is not the same thing according to me but I can understand someone trying to simplify it that way.

  • Great explanation provided by Daniel.

    Policing uses a sliding window for the policing. Policing will use current and future credits if needed, it will all come down to the rate that you are policing.

  • Can you either detail how the sliding mechanism explains the borrowing or provide a link to a document that explains the internals for the sliding window averaging mechanism? I could only find the term mentioned as a formula (ecuation) but not how that relates to Policing.

    While I can understand that this mechanism is used for averaging I can not understand how that explains the borrowing of future credits. 

    I can only specuulate that Policing deals with quasi instant values of the bandwidth (Bc/Tc) having the micro unit of 1/CIR as credit token. Howwever this does not explain the borrowing of future credits. 

     

  • Hi!

    Here's a link that might help.  Note the "How Extended Bursts Capability Works".  This is how the Be value relates to CAR.  

    http://www.cisco.com/en/US/docs/ios/qos/configuration/guide/polcing_shping_oview.html

  • Thanks for the link, I already read that one but, in my opinion that does not explain the borrowing. The "debt" term is used as a metaphor there. 

    Let's recap a little bit:

    Shapping:

    Bc or Bc+Be -means how much you are allowed to transmit in a Tc cycle in order to smooth the tramsission to a CIR rate

    Bc -this it the leaky tocken capacity. 

    Be-extends the capacity by acumulating unused credits from the past Tc cycles 

    Here you do not exceed the CIR by any means.

     

    Policing:

    Bc means the instant transmission rate you can use in any 1/CIR interval in order to stay under CIR

    Bc -this is the estimated burst size to keep you under an averge speed (CIR)

    Be-if in the previous cycles you have not used Bc at full capacity then you can, for a little while, use Be to speed up the transmission hoping that the average will stay under CIR. I suspect that here is where the sliding window averaging is used

     

    In the case of a dual rate mechanism the Be meaning changes again and Be is ment to support an alternate Be/Tc rate that can be used (agreed by the receiver). However the packets transmitted at this speed will be marked and could be dropped if the receiver experineces congestion

    That is how I see it. Am I wrong? If yes please tell me where.

     

    The link you provided uses the "credit" metahpor to explain how CAR is punishing the aggressive flows. That is a calculation method and nothing more. Also it should be noted that this refers to CAR only while the generic statement quted above at the beining of the thread covers all the Policing methods. 

     

Sign In or Register to comment.