Menu

Lumen help

Network: Configuring traffic shaping

You can configure traffic shaping on many vendor platforms. Use the examples below to learn how configure traffic shaping on devices for several vendors. We recommend configuring a committed burst size equal to a 4ms Tc and an excess burst size equal to 0 bits (when applicable).

Examples:

 

CIR: 50Mbps
Burst size = 50,000,000bps × .004 seconds = 200,000 bits

 

CIR: 20Mbps
Burst size = 20,000,000bps × .004 seconds = 80,000 bits

The commands below configure the following settings and apply traffic shaping to interface FastEthernet0/1. In this example the Bc is 200,000 bits. This is because 50,000,000 bps × .004 seconds = 200,000 bits. You may need to adjust your queue-limit depending on your traffic load.

CIR = 50,000,000 bits/sec
Bc = 200,000 bits
Be = 0 bits
Queue-Limit = 400 packets

CPE-ROUTER#config t
Enter configuration commands, one per line.  End with CNTL/Z.
CPE-ROUTER (config)#policy-map SHAPE
CPE-ROUTER (config-pmap)#class class-default
CPE-ROUTER (config-pmap-c)#shape average 50000000 200000 0
CPE-ROUTER (config-pmap-c)#queue-limit 400
CPE-ROUTER (config-pmap-c)#interface FastEthernet0/1
CPE-ROUTER (config-if)#service-policy output SHAPE

The commands below configure the following settings and apply traffic shaping to interface FastEthernet0/1. Additionally the child policy XYZ-QOS is nested under the parent policy SHAPE. The parent policy (SHAPE) provides the traffic shaping for all traffic, the child policy (XYZ-QOS) provides the QoS functions per queue (scheduling, prioritization, etc).

CIR = 50,000,000 bits/sec
Bc = 200,000 bits
Be = 0 bits
Queue-Limit = 400 packets

CPE-ROUTER#config t
Enter configuration commands, one per line.  End with CNTL/Z.
CPE-ROUTER (config)#policy-map SHAPE
CPE-ROUTER (config-pmap)#class class-default
CPE-ROUTER (config-pmap-c)#shape average 50000000 200000 0
CPE-ROUTER (config-pmap-c)#queue-limit 400
CPE-ROUTER (config-pmap-c)#service-policy XYZ-QOS
CPE-ROUTER (config-pmap-c)#interface FastEthernet0/1
CPE-ROUTER (config-if)#service-policy output SHAPE

The commands below will configure traffic shaping and apply it to interface
Te0/1/0/1.1000 with the following settings:

CIR: 50,000,000 bits/sec
Be: 1 byte

RP/0/RSP0/CPU0:CPE-ROUTER#config t
RP/0/RSP0/CPU0:CPE-ROUTER(config)#policy-map SHAPE
RP/0/RSP0/CPU0:CPE-ROUTER(config-pmap)#class class-default
RP/0/RSP0/CPU0:CPE-ROUTER(config-pmap-c)#shape average 50000000 1 bytes
RP/0/RSP0/CPU0:CPE-ROUTER(config-pmap-c)#interface Te0/1/0/1.1000
RP/0/RSP0/CPU0:CPE-ROUTER(config-subif)#service-policy output SHAPE
RP/0/RSP0/CPU0:CPE-ROUTER(config-subif)#commit

The commands below will configure traffic shaping and apply it to interface
Te0/1/0/1.1000 with the following settings. Additionally the child policy XYZ-QOS will be nested under the parent shaping policy (SHAPE).

CIR: 50,000,000 bits/sec
Be: 1 byte

RP/0/RSP0/CPU0:CPE-ROUTER#config t
RP/0/RSP0/CPU0:CPE-ROUTER(config)#policy-map SHAPE
RP/0/RSP0/CPU0:CPE-ROUTER(config-pmap)#class class-default
RP/0/RSP0/CPU0:CPE-ROUTER(config-pmap-c)#shape average 50000000 1 bytes
RP/0/RSP0/CPU0:CPE-ROUTER(config-pmap-c)#service-policy XYZ-QOS
RP/0/RSP0/CPU0:CPE-ROUTER(config-pmap-c)#interface Te0/1/0/1.1000
RP/0/RSP0/CPU0:CPE-ROUTER(config-subif)#service-policy output SHAPE
RP/0/RSP0/CPU0:CPE-ROUTER(config-subif)#commit

The commands below will configure traffic shaping on interface ge-0/0/0 with a CIR of 50 Mbits/sec

CPE-ROUTER> configure private
warning: uncommitted changes will be discarded on exit
Entering configuration mode

[edit]
CPE-ROUTER # set class-of-service interfaces ge-0/0/0 unit 0 shaping-rate 50m

[edit]
CPE-ROUTER # commit and-quit

The commands below will configure traffic shaping on interface eth 0/1 with the following settings:

CIR: 50,000,000 bits/sec
Burst: 30,000 bytes
Count-ethernet overhead = Count Ethernet FCS in bandwidth calculation

CPE-ROUTER#config t
CPE-ROUTER (config)#int eth 0/1
CPE-ROUTER (config-eth 0/1)#traffic-shape rate 50000000 30000 count-eth-overhead
CPE-ROUTER (config-eth 0/1)#end

Use the information below to configure SonicWall:

sonic wall sonicos