CAR 101

Committed Access Rate

CAR can be enabled per interface to limit the incoming and outgoing traffic. CAR can perform classification, marking and policing.

Configuring CAR

1
R(config-if)# rate-limit {input|output} [FILTER] CIR BC BE conform-action ACTION exceed-action ACTION
2
! available ACTIONs:
3
continue scan other rate limits
4
drop drop packet
5
set-dscp-continue set dscp, scan other rate limits
6
set-dscp-transmit set dscp and send it
7
set-mpls-exp-imposition-continue set exp during imposition, scan other rate
8
limits
9
set-mpls-exp-imposition-transmit set exp during imposition and send it
10
set-prec-continue rewrite packet precedence, scan other rate
11
limits
12
set-prec-transmit rewrite packet precedence and send it
13
set-qos-continue set qos-group, scan other rate limits
14
set-qos-transmit set qos-group and send it
15
transmit transmit packet
Copied!

Filtering

If no FILTER is used, the rate-limiting parameters are applied to all incoming or outgoing traffic. You can use FILTERS to apply different rate-limiting parameters to different types of traffic, by issuing multiple CAR commands. The FILTERS can match an ACL, a rate-limit ACL, packets marked with a DSCP value or a QoS Group:
1
R(config-if)# rate-limit {input|output} [access-group ACL|access-group rate-limit RL-ACL| dscp DSCP| qos-group QOS-GROUP] ...
Copied!

Rate-limit ACL

A rate-limit RL-ACL can be defined to match traffic based on IP Precedencem, MAC Address or MPLS EXP bits
1
! IP Precedence - RL-ACL: 0-99
2
R(config)# access-list rate-limit RL-ACL {IP-PREC|mask PREC-MASK}
3
! MAC Address - RL-ACL:100-199
4
R(config)# access-list rate-limit RL-ACL MAC-ADDRESS
5
! MPLS EXP - RL-ACL:200-299
6
R(config)# access-list rate-limit RL-ACL {EXP|mask EXP-MASK}
Copied!
The mask is represented as a sum of the powers of two, but is written in Hex. The combination is unique and for each power that is used, that IP-PREC value is matched.
1
Ex: 18 = 0x12 = 00010010 => use IP Precedence: 1 and 4
Copied!

Verify

To verify CAR you can use:
1
R# sh interface INTERFACE rate-limit
Copied!