Cisco router QoS for WAN services terminating on high speed ports
Posted on August 28, 2015
- and tagged as
- cisco,
- networking
High speed WAN services differ from the typical xDSL connection in that they terminate on either Fast Ethernet or Gigabit Ethernet ports. This can also be the case with xDSL services on routers which do not have ATM ports and instead bridge to an external modem. The issue with QoS on these configurations is that the router has no way to determine if there is contention as the connection to the edge device/modem will in almost all circumstances be faster (ie, 10/100, or 10/100/1000) than the WAN link speed. The result is that typically configured QoS policies will never be triggered.
The solution is to artificially shape the outbound speed of the Ethernet port connecting to the WAN device to the WAN speed. This is archived by creating a parent Policy Map to shape the traffic, and apply the desired QoS Policy Map as a child of the shaper policy.
Create the desired QoS policy
class-map match-any voip-qos
match access-group name voip-qos
policy-map PM-Prioritise-VoIP
class voip-qos
priority 4000
Create the Parent Shaper and add the QoS policy PM as a child
policy-map PM-Parent-Shaper
class class-default
shape average 9500000
service-policy PM-Prioritise-VoIP
The average speed is in bps. I typically configure the shaped speed a little under the WAN limit to ensure the policy comes into effect.
Apply the configuration
interface GigabitEthernet0/0
description -- WAN Connection --
service-policy output PM-Parent-Shaper
Monitoring and confirming QoS policies
#show policy-map interface gig0/0
GigabitEthernet0/0
Service-policy output: PM-Parent-Shaper
Class-map: class-default (match-any)
26063381 packets, 5812312234 bytes
5 minute offered rate 306000 bps, drop rate 0000 bps
Match: any
Queueing
queue limit 64 packets
(queue depth/total drops/no-buffer drops) 0/9955/0
(pkts output/bytes output) 26005576/5796908317
shape (average) cir 9500000, bc 38000, be 38000
target shape rate 9500000
Service-policy : PM-Prioritise-VoIP
queue stats for all priority classes:
Queueing
queue limit 64 packets
(queue depth/total drops/no-buffer drops) 0/0/0
(pkts output/bytes output) 4826201/676898851
Class-map: voip-qos (match-any)
4826528 packets, 676916503 bytes
5 minute offered rate 70000 bps, drop rate 0000 bps
Match: access-group name voip-qos
4826528 packets, 676916503 bytes
5 minute rate 70000 bps
Priority: 4000 kbps, burst bytes 100000, b/w exceed drops: 0
Class-map: class-default (match-any)
21236853 packets, 5135395731 bytes
5 minute offered rate 237000 bps, drop rate 0000 bps
Match: any
queue limit 64 packets
(queue depth/total drops/no-buffer drops) 0/9955/0
(pkts output/bytes output) 21179374/5120009252