Cisco Support Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Announcements
Webcast-Catalyst9k
New Member

Understanding QoS settings

After going through the config on one of our switches I noticed some QoS settings that I have no idea what they mean and was wondering if someone could help me understand what these settings mean. Here is the config I found plus the config on one of the ports:

mls qos map cos-dscp 0 8 16 26 32 46 48 56
mls qos srr-queue input bandwidth 90 10
mls qos srr-queue input threshold 1 8 16
mls qos srr-queue input threshold 2 34 66
mls qos srr-queue input buffers 67 33
mls qos srr-queue input cos-map queue 1 threshold 2  1
mls qos srr-queue input cos-map queue 1 threshold 3  0
mls qos srr-queue input cos-map queue 2 threshold 1  2
mls qos srr-queue input cos-map queue 2 threshold 2  4 6 7
mls qos srr-queue input cos-map queue 2 threshold 3  3 5
mls qos srr-queue input dscp-map queue 1 threshold 2  9 10 11 12 13 14 15
mls qos srr-queue input dscp-map queue 1 threshold 3  0 1 2 3 4 5 6 7
mls qos srr-queue input dscp-map queue 1 threshold 3  32
mls qos srr-queue input dscp-map queue 2 threshold 1  16 17 18 19 20 21 22 23
mls qos srr-queue input dscp-map queue 2 threshold 2  33 34 35 36 37 38 39 48
mls qos srr-queue input dscp-map queue 2 threshold 2  49 50 51 52 53 54 55 56
mls qos srr-queue input dscp-map queue 2 threshold 2  57 58 59 60 61 62 63
mls qos srr-queue input dscp-map queue 2 threshold 3  24 25 26 27 28 29 30 31
mls qos srr-queue input dscp-map queue 2 threshold 3  40 41 42 43 44 45 46 47
mls qos srr-queue output cos-map queue 1 threshold 3  5
mls qos srr-queue output cos-map queue 2 threshold 3  3 6 7
mls qos srr-queue output cos-map queue 3 threshold 3  2 4
mls qos srr-queue output cos-map queue 4 threshold 2  1
mls qos srr-queue output cos-map queue 4 threshold 3  0
mls qos srr-queue output dscp-map queue 1 threshold 3  40 41 42 43 44 45 46 47
mls qos srr-queue output dscp-map queue 2 threshold 3  24 25 26 27 28 29 30 31
mls qos srr-queue output dscp-map queue 2 threshold 3  48 49 50 51 52 53 54 55
mls qos srr-queue output dscp-map queue 2 threshold 3  56 57 58 59 60 61 62 63
mls qos srr-queue output dscp-map queue 3 threshold 3  16 17 18 19 20 21 22 23
mls qos srr-queue output dscp-map queue 3 threshold 3  32 33 34 35 36 37 38 39
mls qos srr-queue output dscp-map queue 4 threshold 1  8
mls qos srr-queue output dscp-map queue 4 threshold 2  9 10 11 12 13 14 15
mls qos srr-queue output dscp-map queue 4 threshold 3  0 1 2 3 4 5 6 7
mls qos queue-set output 1 threshold 1 138 138 92 138
mls qos queue-set output 1 threshold 2 138 138 92 400
mls qos queue-set output 1 threshold 3 36 77 100 318
mls qos queue-set output 1 threshold 4 20 50 67 400
mls qos queue-set output 2 threshold 1 149 149 100 149
mls qos queue-set output 2 threshold 2 118 118 100 235
mls qos queue-set output 2 threshold 3 41 68 100 272
mls qos queue-set output 2 threshold 4 42 72 100 242
mls qos queue-set output 1 buffers 10 10 26 54
mls qos queue-set output 2 buffers 16 6 17 61
mls qos
!
!
vlan internal allocation policy ascending
!
!
interface GigabitEthernet0/2
switchport access vlan 40
switchport mode access
switchport voice vlan 100
srr-queue bandwidth share 10 10 60 20
srr-queue bandwidth shape  10  0  0  0
queue-set 2
mls qos trust device cisco-phone
mls qos trust cos
auto qos voip cisco-phone
spanning-tree portfast

Sorry for my ignorance.

Thanks

Brian

Everyone's tags (3)
10 REPLIES
Silver

Re: Understanding QoS settings

before you understand the commands, you have to understand the queueing in 2900/3560/3750. Before I start, I assume that you know the meaning of CoS, DSCP, and IP Precedence. If not, please let me know.

For each physical port on 2900/3560/3750, there are two input queues. Each input queue has three threshold. mls qos srr-queue input maps traffic with certain CoS or DSCP value to a particular queue and threshold. For example:

mls qos srr-queue input cos-map queue 2 threshold 3  3 5

The above command maps traffic with CoS value 3 and 5 to queue 2 threshold 3.

For each physical port on 2900/3560/3750, there are four output queues.  Each output queue has four threshold. mls qos srr-queue output maps  traffic with certain CoS or DSCP value to a particular queue and  threshold. For example:

mls qos srr-queue output dscp-map queue 1 threshold 3  40 41 42 43 44 45 46 47

The above command maps traffic with DSCP value 41 to 47 to queue 1 threshold 3.

The next question is what is a threshold. If traffic over certain threshold in a queue, the switch starts to drop traffic.

You can command mls qos queue-set output threshold to define the value of threshold. You can define two queue-set in 2900/3560/3750: queue 1 and 2. You can apply eithere queue set in the physical port.

mls qos queue-set output buffers defines the relative size of each queue.

Finally, you can define the egress queue strategy: share or shape by using commands srr-queue bandwidth share and srr-queue bandwidth shape.

The above may not be detailed enough. However, It is tough to explain everything in a message. Please read the above and ask any questions.

New Member

Re: Understanding QoS settings

Hi Dixho,

can you please explain CoS,DSCP and IP Precedence? and also trust boundrys?

thanks

Scott

Silver

Re: Understanding QoS settings

In order for networking device to classify traffic, there is certain information within a frame or packet to identify the importance of a frame or packet. CoS, IP Precedence, and DSCP are widely used nowadays.

CoS is in layer 2. IP Precedence and DSCP are in IP header.

In a dot1q tag, there are 3 bit used to identify the importance of the frame. As CoS is 3-bit, the range is between 0 to 7. In normal Cisco VOIP implementation, Cisco IP phones mark CoS 5 on RTP frames. Data traffic is put on native VLAN; so that there is no 802.1q tag on data traffic. By default, Cisco switches put any traffic without 802.1q to be CoS 0 and DSCP 0.

Before DSCP is used, the second byte in IP header is called ToS (Type of Service). It was used to classify IP traffic. Like CoS, IP precedence is 3 bits.  Thus, the range for IP precedence is 0 to 7. After a while, we find out that 3 bit is not long enough. We expand IP precedence from 3 bites to 6 bits. It is called DSCP. As DSCP is 6 bits, the range is 0 to 63. Normally, Cisco IP phones mark EF (DSCP value 46) on RTP packets.

QoS on campus switching is different than router. In router, we normally mark and police the traffic just before going to ISP. As a result, you determine what traffic is dropped if the traffic going to ISP exceeds the bandwidth of the circuit.

We normally classify traffic on ports connecting to phones and end devices. To simplify configuration, Cisco switches allow you to trust CoS; so that VOIP traffic is classify with CoS 5. Different switches have difference queues. However, all Cisco switches put CoS 5 or DSCP 46 into priority queue. Once traffic is classified on the access switches, we can simply trust DSCP or CoS on the links between switches. We should use trust DSCP on any layer 3 links. Also, make sure that voice VLAN is not used as native VLAN.

The last question is what happens if a users put a data device on the voice VLAN and construst frames with CoS 5. Here comes extended trust. Switches have to receive CDP on the port before trusting the device on the voice VLAN is a VOIP phone. Not sure if I miss anything.

New Member

Re: Understanding QoS settings

thanks so much dixho, that has helped me with my study's alot.

New Member

Hello all! thanks a lot for

Hello all!

 

thanks a lot for the answers, i would like to know what is purpose of this couple of lines configured. I have been reading about  this but i don´t understand it clearly.

in the first line 90 10 is not talking about a percentage, else a composition of weight, right?

 

 

mls qos srr-queue input bandwidth 90 10
mls qos srr-queue input threshold 1 8 16
mls qos srr-queue input threshold 2 34 66
mls qos srr-queue input buffers 67 33

Super Bronze

DisclaimerThe Author of this

Disclaimer

The Author of this posting offers the information contained within this posting without consideration and with the reader's understanding that there's no implied or expressed suitability or fitness for any purpose. Information provided is for informational purposes only and should not be construed as rendering professional advice of any kind. Usage of this posting's information is solely at reader's own risk.

Liability Disclaimer

In no event shall Author be liable for any damages whatsoever (including, without limitation, damages for loss of use, data or profit) arising out of the use or inability to use the posting's information even if Author has been advised of the possibility of such damage.

Posting

Correct, the two values in your highlighted command are weights, which effectively are ratios, in this instance, 90:10 or 9:1).  However, since they, also in this instance, add to 100, they also happen to represent percentages too.  If they were set to 9 and 1, the effective bandwidth sharing should be the same, but as they no longer add to 100, they are no longer also percentages (which would still be 90 and 10 percent).

New Member

Re: Understanding QoS settings

Thanks dixho. I have a much better understanding now. But to replicate this type of setup would take an even greater understanding. And I suppose that would be achieved by either doing it or watching someone else do it and have them explain more in depth for each entry as they go along.

For instance, I noticed that the mappings have different threshholds and different settings after the threshholds. Is there a particular reasoning that our config may be "out of numerical order"? Or does it really even matter?

Thanks

Silver

Re: Understanding QoS settings

I agree with you. The QoS configuration for Catalyst product is really complicated. Different switch model has different commands and queues. it is more complicated in 6500 as each linecard has different buffer and queues.

I do not quite understand your comment of "out of numerical order". Can you elaborate please?

New Member

Re: Understanding QoS settings

Take the following commands for instance:

mls qos srr-queue input dscp-map queue 1 threshold 2  9 10 11 12 13 14 15
mls qos srr-queue input dscp-map queue 1 threshold 3  0 1 2 3 4 5 6 7
mls qos srr-queue input dscp-map queue 1 threshold 3  32
mls qos srr-queue input dscp-map queue 2 threshold 1  16 17 18 19 20 21 22 23
mls qos srr-queue input dscp-map queue 2 threshold 2  33 34 35 36 37 38 39 48
mls qos srr-queue input dscp-map queue 2 threshold 2  49 50 51 52 53 54 55 56
mls qos srr-queue input dscp-map queue 2 threshold 2  57 58 59 60 61 62 63
mls qos srr-queue input dscp-map queue 2 threshold 3  24 25 26 27 28 29 30 31
mls qos srr-queue input dscp-map queue 2 threshold 3  40 41 42 43 44 45 46 47

If you notice, the settings after the threshold are "out of numerical order". 40 41 42 43 44 45 46 47 are in threshold 3 while 33 34 35 36 37 38 39 48 are further up the list in threshold 2.

Silver

Re: Understanding QoS settings

I suggest that you go through the following URL for the meaning of DSCP value:

http://www.cisco.com/en/US/tech/tk543/tk757/technologies_tech_note09186a00800949f2.shtml

It is not always that higher DSCP value has is more important. For example, DSCP value 46 is always mapped to the priority queue.

7375
Views
20
Helpful
10
Replies
CreatePlease to create content