M Commands

This chapter describes the Cisco NX-OS quality of service (QoS) commands that begin with M.

match access-group

To identify a specified access control list (ACL) group as a match criteria for a class map, use the match access-group command. To remove an ACL match criteria from a class map, use the no form of this command.

match access-group name acl-name

no match access-group name acl-name

 
Syntax Description

name acl-name

Matches on the characteristics in the ACL name specified.

 
Command Default

None

 
Command Modes

Class-map type qos configuration

 
Command History

Release
Modification

5.2(1)N1(1)

This command was introduced.

 
Usage Guidelines


Note The permit and deny ACL keywords do not affect the matching of packets.


Examples

This example shows how to create a qos class map that matches characteristics of the ACL my_acl:

switch(config)# class-map class_acl
switch(config-cmap-qos)# match access-group name my_acl
 

 
Related Commands

Command
Description

show class-map

Displays class maps.

match cos

To define the class of traffic using the class of service (CoS) value in a type qos class map, use the match cos command. To remove the match on the CoS value, use the no form of this command.

match [ not ] cos cos-list

no match [ not ] cos cos-list

 
Syntax Description

not

(Optional) Negates the specified match result.

cos-list

Specified CoS value or list of specified CoS values. Valid values are from 0 to 7.

 
Command Default

None

 
Command Modes

Class-map type qos configuration

 
Command History

Release
Modification

5.2(1)N1(1)

This command was introduced.

 
Usage Guidelines

To specify a list of values, use one of the following options:

  • Specify a range of values separated by a dash
  • Specify a noncontiguous list of values separated by commas

Note Only class maps of type qos support the optional not keyword form of this command. Class maps of type queuing do not support the not keyword.


Examples

This example shows how to match on the CoS value for a type qos class map:

switch(config)# class-map class_acl
switch(config-cmap-qos)# match cos 5-7
 

 
Related Commands

Command
Description

show class-map

Displays class maps.

match dscp

To identify specific differentiated services code point (DSCP) values in the DiffServ field of the IP Header (either IPv4 or IPv6) as a match criteria, use the match dscp command. To remove specified DSCP values as a match criteria, use the no form of this command.

match [ not ] dscp dscp-list

no match [ not ] dscp dscp-list

 
Syntax Description

not

(Optional) Negates the specified match result.

dscp-list

Specified DSCP value or list of DSCP values. See Table 1 for a list of valid DSCP values.

 
Command Default

None

 
Command Modes

Class-map type qos configuration

 
Command History

Release
Modification

5.2(1)N1(1)

This command was introduced.

 
Usage Guidelines

The standard DSCP values are shown in Table 1 .

 

Table 1 Standard DSCP Values

DSCP Value
Description

af11

AF11 dscp (001010)—decimal value 10

af12

AF12 dscp (001100)—decimal value 12

af13

AF13 dscp (001110)—decimal value 14

af21

AF21 dscp (010010)—decimal value 18

af22

AF22 dscp (010100)—decimal value 20

af23

AF23 dscp (010110)—decimal value 22

af31

AF31 dscp (011010)—decimal value 26

af32

AF40 dscp (011100)—decimal value 28

af33

AF33 dscp (011110)—decimal value 30

af41

AF41 dscp (100010)—decimal value 34

af42

AF42 dscp (100100)—decimal value 36

af43

AF43 dscp (100110)—decimal value 38

cs1

CS1 (precedence 1) dscp (001000)—decimal value 8

cs2

CS2 (precedence 2) dscp (010000)—decimal value 16

cs3

CS3 (precedence 3) dscp (011000)—decimal value 24

cs4

CS4 (precedence 4) dscp (100000)—decimal value 32

cs5

CS5 (precedence 5) dscp (101000)—decimal value 40

cs6

CS6 (precedence 6) dscp (110000)—decimal value 48

cs7

CS7 (precedence 7) dscp (111000)—decimal value 56

default

Default dscp (000000)—decimal value 0

ef

EF dscp (101110)—decimal value 46

To specify a list of values, use one of the following options:

  • Specify a range of values separated by a dash
  • Specify a noncontiguous list of values separated by commas

Examples

This example shows how to match on DSCP value af21:

switch(config)# class-map my_test
switch(config-cmap-qos)# match dscp af21
 

 
Related Commands

Command
Description

show class-map

Displays class maps.

match ip rtp

To configure a class map to use the Real-Time Protocol (RTP) port as a match criteria, use the match ip rtp command. To remove the RTP port as a match criteria, use the no form of this command.

match [ not ] ip rtp port-list

no match [ not ] ip rtp port-list

 
Syntax Description

not

(Optional) Negates the specified match result.

port-list

Specified UDP port or list of UDP ports that are using RTP. Valid values range from 2000 to 65535.

 
Command Default

None

 
Command Modes

Class-map type qos configuration

 
Command History

Release
Modification

5.2(1)N1(1)

This command was introduced.

 
Usage Guidelines

To specify a list of values, use one of the following options:

  • Specify a range of values separated by a dash
  • Specify a noncontiguous list of values separated by commas

Examples

This example shows how to match on a port using RTP:

switch(config)# class-map my_test
switch(config-cmap-qos)# match ip rtp 2300
 

 
Related Commands

Command
Description

show class-map

Displays class maps.

match precedence

To configure a class map to use the precedence value in the type of service (ToS) byte field of the IP header (either IPv4 or IPv6) as a match criteria, use the match precedence command. To remove the precedence values as a match criteria, use the no form of this command.

match [ not ] precedence precedence-list

no match [ not ] precedence precedence-list

 
Syntax Description

not

(Optional) Negates the specified match result.

precedence-list

Specified IP precedence value or list of IP precedence values specified in bytes. Valid values are shown in Table 2 .

 
Command Default

None

 
Command Modes

Class-map type qos configuration

 
Command History

Release
Modification

5.2(1)N1(1)

This command was introduced.

 
Usage Guidelines

See Table 2 for a list of precedence values.

 

Table 2 Precedence Values

Precedence Value
Description

0-7

IP precedence value

critical

Critical precedence (5)

flash

Flash precedence (3)

flash-override

Flash override precedence (4)

immediate

Immediate precedence (2)

internet

Internetwork control precedence (6)

network

Network control precedence (7)

priority

Priority precedence (1)

routine

Routine precedence (0)

To specify a list of values, use one of the following options:

  • Specify a range of values separated by a dash
  • Specify a noncontiguous list of values separated by commas

Examples

This example shows how to match on an IP precedence value:

switch(config)# class-map my_test
switch(config-cmap-qos)# match precedence 7
 

 
Related Commands

Command
Description

show class-map

Displays class maps.

match protocol

To configure a class map to use a specific protocol as a match criterion, use the match protocol command. To remove the specified protocol as a match criteria, use the no form of this command.

match [ not ] protocol protocol-name

no match [ not ] protocol protocol-name

 
Syntax Description

not

(Optional) Negates the specified match result.

protocol-name

Specified protocol name. Valid values are shown in Table 3 .

 
Command Default

None

 
Command Modes

Class-map type qos configuration

 
Command History

Release
Modification

5.2(1)N1(1)

This command was introduced.

 
Usage Guidelines

The list of valid protocol names is shown in Table 3 .

 

Table 3 Protocol Names

Argument
Description

arp

Address Resolution Protocol (ARP)

clns_es

CLNS End Systems

clns_is

CLNS Intermediate System

dhcp

Dynamic Host Configuration (DHCP)

ldp

Label Distribution Protocol (LDP)

netbios

NetBIOS Extended User Interface (NetBEUI)

To specify more than one protocol, enter the command more than once with the desired protocol value each time.

Examples

This example shows how to match on a specified protocol:

switch(config)# class-map my_test
switch(config-cmap-qos)# match protocol ldp
 

 
Related Commands

Command
Description

show class-map

Displays class maps.

match qos-group

To configure a class map to use a specific QoS group value as a match criterion, use the match qos-group command. To remove the specified protocol as a match criteria, use the no form of this command.

match [ not ] qos-group qos-group-list

no match [ not ] qos-group qos-group-list

 
Syntax Description

not

(Optional) Negates the specified match result.

qos-group-list

Specified Qos group value or list of QoS group values specified in bytes. Valid values are from 2 to 5.

 
Command Default

None

 
Command Modes

Class map type network-qos configuration
Class map type queuing configuration

 
Command History

Release
Modification

5.2(1)N1(1)

This command was introduced.

 
Usage Guidelines

The QoS group is an internal label and is not part of the packet payload or any packet header. The QoS group values have no mathematical significance. For example, a QoS group value of 2 is not greater than 1; the values are used only to internally differentiate QoS groups. As such, this value has local significance only.

You match on the QoS group only in egress policies because its value is undefined until you set it in an ingress policy.

To specify a list of values, use one of the following options:

  • Specify a range of values separated by a dash
  • Specify a noncontiguous list of values separated by commas

Examples

This example shows how to match on a specified QoS group value:

switch(config)# class-map type queuing my_test
switch(config-cmap-qos)# match qos-group 6
switch(config-cmap-qos)#
 

 
Related Commands

Command
Description

class-map type network-qos

Creates or modifies a network qos class map.

class-map type queuing

Creates or modifies a queuing class map.

show class-map

Displays class maps.

mtu (ERSPAN)

To set the maximum transmission unit (MTU) size for Encapsulated Remote Switched Port Analyzer (ERSPAN) packets in a monitor session, use the mtu command. To remove the configured MTU, use the no form of this command.

mtu mtu-value

no mtu mtu-value

 
Syntax Description

mtu-value

Maximum allowable MTU for ERSPAN packets in a monitor session. The range is from 64 to 1518 bytes.

 
Command Default

Default is no truncation enabled.

 
Command Modes

ERSPAN session configuration mode

 
Command History

Release
Modification

5.2(1)N1(1)

This command was introduced.

 
Usage Guidelines

ERSPAN packets larger than the specified allowable size for the monitor session are truncated.

This command does not require a license.

Examples

This example shows how to set an MTU value for an ERSPAN session:

switch# configure terminal
switch(config)# monitor session 1 type erspan-source
switch(config-erspan-src)# erspan-id 100
switch(config-erspan-src)# mtu 100
switch(config-erspan-src)#
 

 
Related Commands

Command
Description

monitor session

Configures a SPAN or ERSPAN session.

show monitor session

Displays the SPAN or ERSPAN session configuration.

 

mtu (interface)

To configure the maximum transmission unit (MTU) size for Layer 2 and Layer 3 Ethernet interfaces, use the mtu command. To remove the configured MTU, use the no form of this command.

mtu mtu-value

no mtu mtu-value

 
Syntax Description

mtu-value

MTU value for the class of service (CoS). The range is from 64 to 9216.1500 to 9216.

 
Command Default

Default MTU value is 1500. For FCoE cos 3, the default is 2158.

 
Command Modes

Policy map type network-qos class configuration

 
Command History

Release
Modification

5.2(1)N1(1)

This command was introduced.

 
Usage Guidelines

You can configure an MTU for each virtual link in the system.

Examples

This example shows how to set an MTU value for a class in a type network-qos policy map:

switch(config)# class-map type network-qos my_class1
switch(config-cmap-nq)# match qos-group 1
switch(config-cmap-nq)# exit
switch(config)# policy-map type network-qos my_policy1
switch(config-pmap-nq)# class type network-qos my_class1
switch(config-pmap-nq-c)# mtu 5000
switch(config-pmap-nq-c)#
 

 
Related Commands

Command
Description

service-policy

Attaches a policy map to an interface or system policy.

show class-map

Displays class maps.

show policy-map

Displays policy maps.

system qos

Configures a system policy.

 

multicast-optimize

To optimize a class to send multiple packets, use the multicast-optimize command.

multicast-optimize

no multicast-optimize

 
Syntax Description

This command has no arguments or keywords.

 
Command Default

None

 
Command Modes

Policy map type network-qos class configuration

 
Command History

Release
Modification

5.2(1)N1(1)

This command was introduced.

 
Usage Guidelines

Multicast traffic in a class will be served by all available multicast queues.

Only one class in a policy map can be configured for multicast optimization.


Note On a Cisco Nexus 5548 switch, multicast optimization is enabled by default on the class-default class. You must remove it from the class-default class before enabling it on a user-defined class.


Examples

This example shows how to enable optimized multicast for a traffic class:

switch(config)# policy-map type network-qos my_queue
switch(config-pmap-nq)# class type network-qos nqos_class
switch(config-pmap-nq-c)# multicast-optimize
switch(config-pmap-nq-c)#
 

This example shows how to remove the multicast optimization from a traffic class:

switch(config)# policy-map type network-qos my_queue
switch(config-pmap-nq)# class type network-qos nqos_class
switch(config-pmap-nq-c)# no multicast-optimize
switch(config-pmap-nq-c)#
 

 
Related Commands

Command
Description

show policy-map

Displays the policy maps.