Sunday, February 7, 2010

Configuring LLQ Quality of service

Configuring LLQ on a switch access port.


#interface fastethernet 0/1
#wrr-queue cos-map 1 0 1
#wrr-queue cos-map 2 2 3
#wrr-queue cos-map 3 4 6 7
#wrr-queue cos-map 4 5
#priority-queue out

#mls qos trust device cisco-phone
#mls cos trust cos
#switchport voice vlan 100
#switchport access vlan 10

#switchport priority extend cos 0
#mls qos map cos-dscp 0 8 16 24 34 46 48 56
#mls qos bandwidth 10 20 70 0(0 or 1)

Description and usage of each command is as follows


In this Configuration im going to configure low latency queuing on a cisco switch, applicable to access port connecting to the IP phone daisy chained to a PC.


#interface fastethernet 0/1
#wrr-queue cos-map 1 0 1
#wrr-queue cos-map 2 2 3
#wrr-queue cos-map 3 4 6 7
#wrr-queue cos-map 4 5

In the above config we have configured four queues, 1 0 1, first digit is the queue number and preceding 0 and 1 are cos values reserved for this queue similarly queue 2 3 4 are configured, queue 4 is the main queue for which cos value 5 is reserved, IP phone marks all its traffic with cos value 5  


#priority-queue out

very important command this sets queue 4 to be prioritized in case of bottleneck, PQ traffic is out first.

#mls qos trust device cisco-phone
#mls cos trust cos

trust the cos vlaue only if cisco IP phone is attached, which is not good if you have phones from other vendors,switches utilize CDP to detect if their is a cisco IP phone attached.

#switchport voice vlan 100
#switchport access vlan 10

#switchport priority extend cos 0

Mark any packet from PC with cos 0

#mls qos map cos-dscp 0 8 16 24 34 46 48 56

Switch will mark the DSCP of packets according to the above map, if a layer 3 device encounters the packet and is taking decisions based on layer 3 DSCP markings. the values are mapped against 0 1 2 3 4 5 6 7 cos markings.

#mls qos bandwidth 10 20 70 0(0 or 1)

Sets the bandwidth for each queue, remember queue 4 is PQ so it will be serviced first and prioritized so you can set a 0 or 1 for this queue,0 preferable.

No comments: