Traffic Regulation
此内容尚不支持你的语言。
Traffic Regulation
Section titled “Traffic Regulation”show traffic-behavior rule
Section titled “show traffic-behavior rule”[Command]
show traffic-behavior rule
[Purpose]
Displays the configured aboute CAR policies
[View]
System view
[Use Cases]
sonic# show traffic-behavior ruleName Type Mode CIR CBS------ ------ ------ ------ -----test BYTES SR_TCM 100000 64000show traffic-behavior counters
Section titled “show traffic-behavior counters”[Command]
show traffic-behavior counters
[Purpose]
View the hit statistics for the CAR
[View]
System view
[Use Cases]
sonic# show traffic-behavior countersPolicerId Forward DROP Remark-Forward------------- --------- ------ ----------------flow_controll 1049585 12764 1810877traffic-behavior traffic-behavior-name
Section titled “traffic-behavior traffic-behavior-name”[Command]
traffic-behavior traffic-behavior-name
no traffic behavior traffic-behavior-name
[Purpose]
Create a traffic behavior and go to the Traffic behavior view, or go to the existing Traffic behavior view, or bind the traffic behavior to interface
[Parameter]
| Parameter | Description |
|---|---|
| traffic-behavior-name | traffic behavior name |
[View]
System view, Interface view
[Use Cases]
sonic# configure terminalsonic(config)# traffic-behavior testsonic(config-traffic-behavior-test)#[Command]
car {sr-tcm|tr-tcm} [meter-type {bytes|packets}] cir cir [cbs cbs ] [pir pir ][pbs pbs ] [yellow-packet-action {DROP|FORWARD|REMARK}] [red-packet-action {DROP|FORWARD|REMARK}] [remark-dot1p value ] [remark-dscp value ] [remark-tc value ]
[Purpose]
Create a CAR template to bind to traffic behavior
[Parameter]
| Parameter | Description |
|---|---|
| sr-tcm | Single bucket single speed mode, this mode only requires the configuration of cir and cbs |
| tr-tcm | Double buckets and double speed mode |
| meter-type | If meter-type mode is bytes: cir, pir in kBps, cbs, pbs in byte If meter-type mode is packets: cir, pir in kpps, cbs, pbs in packet Default mode is bytes |
| cir | Specifies the committed information rate (CIR), which is the allowed rate at which traffic can pass through. |
| cbs | Specifies the committed burst size (CBS), which is the average volume of burst traffic that can pass through an interface. |
| pir | Specifies the peak information rate (PIR), which is the maximum rate at which traffic can pass through. |
| pbs | Specifies the peak burst size (PBS), which is the maximum volume of burst traffic that can pass through an interface. |
| red-packet-action {DROP|FORWARD|REMARK}/ yellow-packet-action {DROP|FORWARD|REMARK} | Specifies the packet color. The packet color is determined by cbs cbs-value and pbs pbs-value of this command. |
[View]
Traffic behavior view
[Notes]
When the burst size of the message < cbs value, the message is marked as green When cbs value < burst size < pbs value, the message is marked yellow When burst size > pbs value, the message is marked as red no car This command removes the CAR template
[Use Cases]
sonic# configure terminalsonic(config)# traffic-behavior testsonic(config-traffic-behavior-test)# car sr-tcm meter-type PACKETS cir 1000traffic-behavior bind [egress] traffic-behavior-name
Section titled “traffic-behavior bind [egress] traffic-behavior-name”[Command]
traffic-behavior bind [egress] traffic-behavior-name
no traffic-behavior bind traffic-behavior-name
[Purpose]
Bind traffic behavior to the interface
[Parameter]
| Parameter | Description |
|---|---|
| egress | Bind in the direction of the output interface |
[View]
Interface view
[Use Cases]
sonic(config)# interface ethernet 1sonic(config-if-1)# traffic-behavior bind test1