The documentation set for this product strives to use bias-free language. For the purposes of this documentation set, bias-free is defined as language that does not imply discrimination based on age, disability, gender, racial identity, ethnic identity, sexual orientation, socioeconomic status, and intersectionality. Exceptions may be present in the documentation due to language that is hardcoded in the user interfaces of the product software, language used based on RFP documentation, or language that is used by a referenced third-party product. Learn more about how Cisco is using Inclusive Language.
This chapter describes the Cisco NX-OS quality of service (QoS) commands that begin with S.
To attach a policy map to an interface, use the service-policy command. To remove a service-policy from an interface, use the no form of this command.
service-policy { input | type { qos input | queuing { input | output }}} policy-map-name
no service-policy { input | type { qos input | queuing { input | output }}} policy-map-name
Interface configuration mode
Vlan configuration mode
|
|
You can attach one ingress and one egress type queuing policy map to an interface of type port, and port channel. Only one policy map can be attached to the input of a given interface for each of the policy type qos and queuing.
Beginning with Cisco NX-OS Release 5.0(3)N1(1), you can use this command on a Layer 3 routed interface.
This example shows how to attach a queuing policy map to the ingress packets of a Layer 2 port interface:
switch(
config)#
interface ethernet 2/1
This example shows how to attach qos type policy maps to the incoming packets of a Layer 2 interface:
switch(config)#
system qos
This example shows how to attach a qos type policy map named set-dscp to the incoming packets of a Layer 2 interface:
switch(config)#
interface ethernet 2/1
This example shows how to attach a queuing policy map to a Layer 3 interface:
switch(
config)#
interface ethernet 1/5
|
|
---|---|
Displays all interfaces and VLANs with attached service policies in a brief format. |
|
To attach a policy map to a control plane for aggregate control plane services, use the service-policy command.
service-policy input policy-map-name
Applies the specified service policy to packets that are entering the control plane. |
|
Name of the control plane policy map to be attached. The name can be a maximum of 64 alphanumeric characters. |
Control-plane configuration mode
|
|
---|---|
After using the control-plane command, you should use the service-policy command to configure a quality of service (QoS) policy. This policy is attached to the control plane interface for aggregate control plane services, which can control the number or rate of packets that are going to the process level.
This example shows how to attach a control-plane policy map to the control plane:
|
|
---|---|
Displays the configuration of a class or all classes for the policy map of a control plane. |
To attach a policy map to a system policy, use the service-policy command. To remove a service policy from a system policy, use the no form of this command.
service-policy { input | type { network-qos | qos input | queuing { input | output }}} policy-map-name
no service-policy { input | type { network-qos | qos input | queuing { input | output }}} policy-map-name
|
|
This example shows how to attach a queuing policy map to the system policy:
switch(
config)#
system qos
|
|
---|---|
To attach a policy map to a virtual Ethernet interface, use the service-policy command. To remove a service policy from a virtual Ethernet interface, use the no form of this command.
service-policy { input | type { qos input | queuing { input | output }}} policy-map-name
no service-policy { input | type { qos input | queuing { input | output }}} policy-map-name
Virtual Ethernet interface configuration mode
|
|
You can attach one ingress and one egress type queuing policy map to an interface of type port and port channel. Only one policy map can be attached to the input of a given interface for each of the policy type qos and queuing.
Note For more information on using service policies, see the Cisco Nexus 5000 Series NX-OS Quality of Service Configuration Guide.
This example shows how to attach a qos policy map to the ingress packets of a virtual Ethernet interface:
switch(
config)#
interface vethernet 12
This example shows how to attach a queuing policy that is configured for traffic shaping to the incoming packets of a virtual Ethernet interface:
|
|
---|---|
Displays all interfaces and VLANs with attached service policies in a brief format. |
|
To assign a class of service (CoS) value for a class of traffic in a type network-qos policy map, use the set command. To remove the assigned value from the class, use the no form of this command.
CoS value to assign for this class of traffic. The range is from 0 to 7. |
Policy map type network-qos class configuration
|
|
You can use this command only on type network-qos policies that are attached to egress ports.
Beginning in Cisco NX-OS Release 5.0(3)N1(1), in Layer 3 topologies you must configure each qos-group in the network-qos policy with a unique cos value.
This example shows how to assign a CoS value for a class of traffic in a type network-qos policy map:
switch(
config)#
policy-map type network-qos my_policy1
This example shows how to remove the assignment of CoS for a class of traffic in a type network-qos policy map:
switch(
config)#
policy-map type network-qos my_policy1
|
|
---|---|
To assign a Differentiated Services Code Point (DSCP) value for a traffic class in a type qos policy map on a Cisco Nexus 5548 switch, use the set dscp command. To remove a previously set DSCP value, use the no form of this command.
DSCP value or parameter to assign for this class of traffic. Valid values are from 0 to 63. For a list of standard DSCP values, see Table 1 . |
Policy map type qos configuration
|
|
---|---|
Note This command is supported only on a Cisco Nexus 5548 switch.
Marking is a method that you use to modify the QoS fields of the incoming and outgoing packets.
You can set the value of standard QoS fields IP precedence, DSCP, and Class of Service (CoS), and internal labels that can be used in subsequent actions. Marking is used to identify the traffic type for use in policing, queuing, and scheduling traffic (only CoS is used in scheduling).
Use this command to classify the traffic based on the DSCP packet header field (either IPv4 or IPv6). When you set the DSCP value for a packet, make sure that you use a traffic class other than the class-default system class. For example, qos-group x, where x is any value from 1 to 5.
Note You cannot set the DSCP packet header field (either IPv4 or IPv6) if the traffic is in the class-default system class (qos-group 0).
You can set the DSCP value in the six most significant bits of the DiffServ field of the IP header to a specified value. You can enter numeric values from 0 to 63, as well as the standard DSCP values shown in Table 1 .
If you set the values for more than two IP header fields (either IPv4 or IPv6), an error similar to the following appears:
Note You can set DSCP or IP precedence but you cannot set both values because they modify the same field in the IP packet.
After you set the DSCP value, for the QoS policy map to work correct and create the specified QoS groups, make sure that you attach the QoS policy map to a system policy, then define a network-qos policy map and attach it to the system policy. Make sure that the QoS group of the QoS policy map matches that of the of the network-qos policy.
This example shows how to set the DSCP value for a QoS policy:
|
|
---|---|
Copies the running configuration to the startup configuration file. |
|
To set the precedence value in an IP header (either IPv4 or IPv6) for a class of traffic in a type qos policy map on a Cisco Nexus 5548 switch, use the set precedence command. To leave the precedence value unchanged for the class, use the no form of this command.
set precedence precedence-value
no set precedence precedence-value
IP precedence value to assign for this class of traffic. Valid values are from 0 to 7. For a list of standard precedence values, see Table 2 . |
Policy map type qos configuration
|
|
---|---|
Note This command is supported only on a Cisco Nexus 5548 switch.
Marking is a method that you use to modify the QoS fields of the incoming and outgoing packets.
You can set the value of standard QoS fields IP precedence, DSCP, and Class of Service (CoS), and internal labels that can be used in subsequent actions. Marking is used to identify the traffic type for use in policing, queuing, and scheduling traffic (only CoS is used in scheduling).
Use this command to classify the traffic based on the IP precedence packet header field. When you set the IP precedence value for a packet, make sure that you use a traffic class other than the class-default system class. For example, qos-group x, where x is any value from 1 to 5.
Note You cannot set the IP precedence packet header field if the traffic is in the class-default system class (qos-group 0).
If you set the values for more than two IP header fields, you see the following error message:
Note You can set DSCP or IP precedence but you cannot set both values because they modify the same field in the IP packet.
After you set the IP precedence value, for the QoS policy map to work correct and create the specified QoS groups, make sure that you attach the QoS policy map to a system policy, then define a network-qos policy map and attach it to the system policy. Make sure that the QoS group of the QoS policy map matches that of the of the network-qos policy.
This example shows how to set the IP precedence value for a QoS policy:
|
|
---|---|
Copies the running configuration to the startup configuration file. |
|
To assign the QoS group identifier for a class of traffic in a type qos policy map, use the set qos-group command. To remove the assigned value from the class, use the no form of this command.
no set qos-group qos-group-value
Policy map type qos class configuration
|
|
---|---|
You can set the QoS group identifier value only in ingress policies. You can set a maximum of 5 QoS groups in ingress policies.
If you set the values for more than two IP header fields in a policy map class, an error message similar to the following appears:
This example shows how to assign a QoS group identifier for a class of traffic in a type qos policy map in Cisco NX-OS release 4.1(3)N1(1):
This example shows how to assign a QoS group identifier for a class of traffic in a type qos policy map in Cisco NX-OS release 5.0(2)N1(1):
|
|
---|---|
Copies the running configuration to the startup configuration file. |
|
To configure shaping on an egress queue to impose a maximum rate on it, use the shape command. To remove a shaping configuration, use the no form of this command.
shape target-rate { kbps | mbps | gbps } burst-size
no shape target-rate { kbps | mbps | gbps } burst-size
Policy map type queuing class configuration mode
|
|
---|---|
Traffic shaping is supported only on virtual Ethernet interfaces.
Shaping rate limits the traffic with a specified rate. You can configure shaping only in the ingress direction. All traffic on the virtual Ethernet interface is rate limited to the given shaping rate.
Note If you configure shaping, you cannot configure priority in the same policy map.
This example shows how to configure shaping on a queuing policy map and apply the policy to a virtual Ethernet interface:
|
|
---|---|
To define the upper bound of any maximum transmission unit (MTU) in the system, use the system jumbomtu command.
|
|
This example shows how to define the upper bound of any MTU in the system:
switch(
config)#
system jumbomtu 9216
|
|
---|---|
Displays the jumbo MTU frames sent and received on the specified interface. |
To configure a system policy, use the system qos command.
|
|
This example shows how to configure a system qos to apply a queuing policy to all interfaces in the system:
switch(config)#
system qos
|
|
---|---|
Associates the system class policy-map to the service policy for the system. |