cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
3501
Views
5
Helpful
7
Replies

cisco 2960 change default dscp value

avtechs19
Level 1
Level 1

Hi, when qos is enabled on the switch (mls qos). It will rewrite anything that is not trusted of classified to 0. How would I change that to af11 0x28?

thx jason

1 Accepted Solution

Accepted Solutions

Jason

We may be talking cross purposes here.

My understanding is this. All Catalyst switches generate an internal DCSP value for the packet regardless of whether the packet is IP or non-IP. This internal value is used for QOS decisions but is not written into the packet itself.

How this internal DCSP value is generated depends on a number of things

1) If the port is set to Trust DSCP then the internal DCSP value is simply the same value as the value in the packet header.

2) If port is set to Trust IP Precedence then the internal DCSP value is obtained from the IPP to DCSP map.

3) If port is set to Trust CoS then the internal DSCP value is obtained from the CoS to DSCP map

4) If the port is set to Untrusted the received packet has a default CoS setting applied to it which is then mapped to an internal DSCP value using the CoS to DCSP map.

Now my understanding is that if you have "mls qos trust cos" on a port and the packet received has a DSCP value that is irrelevant. What will happen is that the packet either has

a) a CoS value, in which case that will be used and mapped to an internal DSCP value using the Cos to DSCP value.

b) No CoS value, in which case you assign the default CoS value of the port and then map that to an internal DSCP value using the Cos to DSCP map.

As far as i am aware the DSCP to CoS map is only used on the egress because the switch does not use an internal CoS value.

Perhaps i have misunderstood.

Jon

View solution in original post

7 Replies 7

Jon Marshall
Hall of Fame
Hall of Fame

Hi Jason

You can't really because you are talking about a default COS value ie. 0 and changing that to a DSCP value

What you can do though is change the default COS value ie.

switch(conf t)#interface range fa0/1 - 24

switch(config-if)# mls qos cos "COS value"

where COS value is between 1 & 7.

This would then set the COS value for all frames entering the switch to whatever value you chose.

http://www.cisco.com/en/US/docs/switches/lan/catalyst2960/software/release/12.2_37_se/configuration/guide/swqos.html#wp1032169

and then you can map that in the COS to DCSP map ie. you could choose value 3 and map to 28.

http://www.cisco.com/en/US/docs/switches/lan/catalyst2960/software/release/12.2_37_se/configuration/guide/swqos.html#wp1027339

I suppose you could just directly modify the COS to DSCP map and the DSCP to COS map if you wanted but i have never tried this.

HTH

Jon

If qos is enabled and the port is untrusted, what map is the switch using to determine the cos,dscp value?

jason

Jason

It will use the COS to DSCP map as this is used on ingress ports. The DSCP to COS map is used on egress ports. But it doesn't use the map per se to determine the COS value. If the port is untrusted it sets the default COS value and then uses the COS to DSCP map to generate an internal DSCP value.

Jon

hi, from the documentation it says that the cos-dscp,dscp-cos map is only dependent on what is trusted dscp,cos and what is availible in the packet. For example, if dscp is set on a ingress packet, and 'mls qos trust cos' is trusted on that port, it will do a it will do a dscp-to-cos map.

if the trust as 'mls qos trust dscp' it will just remark the packet with the same dscp.

jason

Jason

We may be talking cross purposes here.

My understanding is this. All Catalyst switches generate an internal DCSP value for the packet regardless of whether the packet is IP or non-IP. This internal value is used for QOS decisions but is not written into the packet itself.

How this internal DCSP value is generated depends on a number of things

1) If the port is set to Trust DSCP then the internal DCSP value is simply the same value as the value in the packet header.

2) If port is set to Trust IP Precedence then the internal DCSP value is obtained from the IPP to DCSP map.

3) If port is set to Trust CoS then the internal DSCP value is obtained from the CoS to DSCP map

4) If the port is set to Untrusted the received packet has a default CoS setting applied to it which is then mapped to an internal DSCP value using the CoS to DCSP map.

Now my understanding is that if you have "mls qos trust cos" on a port and the packet received has a DSCP value that is irrelevant. What will happen is that the packet either has

a) a CoS value, in which case that will be used and mapped to an internal DSCP value using the Cos to DSCP value.

b) No CoS value, in which case you assign the default CoS value of the port and then map that to an internal DSCP value using the Cos to DSCP map.

As far as i am aware the DSCP to CoS map is only used on the egress because the switch does not use an internal CoS value.

Perhaps i have misunderstood.

Jon

Thank you, That clears up the the confusion.

much appreciated

jason

Excellent explanation..

I have a few follow-up questions if you don't mind?

a) So one typically wouldn't use the command "mls qos trust cos" on a port that is simply acting as a switchport (i.e. not trunking)? Since there's no CoS to trust anyway, right?

b) You only see the DSCP to COS mapping played out if the egress is a trunked port?

As such it would derive a 'new' (albeit possibly the same) COS value regardless of the original ingress trunk COS value or even ingress switchport 'non-value'?

c) Is an exception to (b) when such packet is egressing a switchport interface that has WRR configured since placement into appropriate WRR queues is based on COS values not DSCP? Therefore the DSCP to COS map must be invoked?

d) To clarify the scenario in (c): WRR can be configured on both switchport and trunked egress interfaces?

It's a fairly confusing subject...Thanks for the help you've already provided.

Getting Started

Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community:

Review Cisco Networking products for a $25 gift card