CoPP
Table 1 CoPP View
| Command | Purpose |
|---|---|
| **show policy-map ** [policy_map_name] | Display the CoPP configuration. |
| show copp status | Display the CoPP status. |
show policy-map [
Section titled “show policy-map [”[Command] **show policy-map ** [policy_map_name]
[Purpose] Display the CoPP configuration.
[Parameters]
| Parameter | Description |
|---|---|
| policy_map_name | CoPP policy name. |
[View] Privileged User View
[Use Cases]
sonic# show policy-map!policy-map type copp copp-system-policy class copp-system-arp bandwidth 1000000 12800show copp status
Section titled “show copp status”[Command] show copp status
[Purpose] Display the CoPP status.
[View] Privileged User View
[Use Cases]
sonic# show copp statusClass Status--------------------------- -----------------------------------------------------copp-system-arp cbs: 64000 cir: 256000 meter_type: bytes mode: sr_tcm queue: 5 red_action: drop trap_action: copy trap_ids: arp_req,arp_resp trap_priority: 5CoPP Config
Section titled “CoPP Config”Table 2 CoPP Config
| Command | Purpose |
|---|---|
| policy-map type copp copp-system-policy | Enter CoPP Configuration View. |
| class system_class_name | Specify the type of message targeted by CoPP. |
| bandwidth cir cbs | Set CoPP rate limiting. |
| arp broadcast disable | Configure CoPP action for ARP packets as trap. |
| ndp broadcast disable | Configure CoPP action for ND packets as trap. |
| igmp enable | Configure CoPP action for IGMP packets as forward. |
| pim enable | Configure CoPP action for PIM packets as forward. |
| isis enable | Configure CoPP action for ISIS packets as forward. |
| vrrp enable | Configure CoPP action for VRRP packets as forward. |
| ospf enable | Configure CoPP action for OSPF packets as forward. |
policy-map type copp copp-system-policy
Section titled “policy-map type copp copp-system-policy”[Command] policy-map type copp copp-system-policy
[Purpose] Enter CoPP Configuration View.
[View] Global Configuration View
[Use Cases]
sonic(config)# policy-map type copp copp-system-policysonic(config-pmap-copp-copp-system-policy)#class system_class_name
Section titled “class system_class_name”[Command] class system_class_name
[Purpose] Specify the type of message targeted by CoPP.
[Parameters]
| Parameter | Description |
|---|---|
| system_class_name | Specify the type of message. (copp-system-ttl_err/copp-system-bgp/copp-system-bfd/copp-system-ospf/copp-system-vrrp/copp-system-isis/copp-system-lacp/copp-system-stp/copp-system-arp/copp-system-neigh_discovery/ /copp-system-macsec/copp-system-lldp/copp-system-udld/copp-system-igmp/copp-system-dhcp_relay/copp-system-sflow/copp-system-ip2me/copp-system-nat/copp-system-pvrst/copp-system-pim/copp-system-vrrpv6/copp-system-mld/ /copp-system-ssh/copp-system-snmp/copp-system-l3_mtu_error/copp-system-ldp) |
[View] CoPP Configuration View
[Use Cases]
sonic(config-pmap-copp-copp-system-policy)# class copp-system-arpsonic(config-pmap-c-copp-system-policy-copp-system-arp)#bandwidth
Section titled “bandwidth”[Command] bandwidth cir cbs
[Purpose] Set CoPP rate limiting.
[Parameters]
| Parameter | Description |
|---|---|
| cir | Specify the CIR(Committed Information Rate) in byte/sec. The range is 1000 ~ 400000000000. |
| cbs | Specify CBS (Committed Burst Size) in byte. The range is 1000 ~ 400000000000. |
[View] CoPP-Class Map Configuration View
[Notes] Run command no bandwidth delete the customized CoPP configuration and the system will revert to the default CoPP configuration.
[Use Cases]
sonic(config-pmap-copp-copp-system-policy)# class copp-system-arpsonic(config-pmap-c-copp-system-policy-copp-system-arp)# bandwidth 1000000 12800arp broadcast disable
Section titled “arp broadcast disable”[Command] arp broadcast disable
[Purpose] Configure CoPP action for ARP packets as trap.
[View] Global Configuration View
[Notes] The action trap means upload to CPU, and copy means both upload to CPU and forward. The default action for ARP packets is copy. Run command no arp broadcast disable to configure CoPP action for ARP packets as copy
[Use Cases]
sonic(config)# arp broadcast disablesonic(config)# no arp broadcast disablendp broadcast disable
Section titled “ndp broadcast disable”[Command] ndp broadcast disable
[Purpose] Configure CoPP action for ND packets as trap.
[View] Global Configuration View
[Notes] The action trap means upload to CPU, and copy means both upload to CPU and forward. The default action for ND packets is copy. Run command no ndp broadcast disable to configure CoPP action for ND packets as copy
[Use Cases]
sonic(config)# ndp broadcast disablesonic(config)# no ndp broadcast disableigmp enable
Section titled “igmp enable”[Command] igmp enable
[Purpose] Configure CoPP action for IGMP packets as copy.
[View] Global Configuration View
[Notes] The action forward means forward the packets, and copy means both upload to CPU and forward. The default action for IGMP packets is forward. Run command no igmp enable to configure CoPP action for IGMP packets as forward
[Use Cases]
sonic(config)# igmp enablesonic(config)# no igmp enablepim enable
Section titled “pim enable”[Command] pim enable
[Purpose] Configure CoPP action for PIM packets as copy.
[View] Global Configuration View
[Notes] The action forward means forward the packets, and copy means both upload to CPU and forward. The default action for PIM packets is forward. Run command no pim enable to configure CoPP action for PIM packets as forward.
[Use Cases]
sonic(config)# pim enablesonic(config)# no pim enableisis enable
Section titled “isis enable”[Command] isis enable
[Purpose] Configure CoPP action for ISIS packets as copy.
[View] Global Configuration View
[Notes] The action forward means forward the packets, and copy means both upload to CPU and forward. The default action for ISIS packets is forward. Run command no isis enable to configure CoPP action for ISIS packets as forward.
[Use Cases]
sonic(config)# isis enablesonic(config)# no isis enablevrrp enable
Section titled “vrrp enable”[Command] vrrp enable
[Purpose] Configure CoPP action for VRRP packets as copy.
[View] Global Configuration View
[Notes] The action forward means forward the packets, and copy means both upload to CPU and forward. The default action for VRRP packets is forward. Run command no vrrp enable to configure CoPP action for VRRP packets as forward.
[Use Cases]
sonic(config)# vrrp enablesonic(config)# no vrrp enableospf enable
Section titled “ospf enable”[Command] ospf enable
[Purpose] Configure CoPP action for OSPF packets as copy.
[View] Global Configuration View
[Notes] The action forward means forward the packets, and copy means both upload to CPU and forward. The default action for OSPF packets is forward. Run command no ospf enable to configure CoPP action for OSPF packets as forward.
[Use Cases]
sonic(config)# ospf enablesonic(config)# no ospf enable