C H A P T E R  6

Quality of Service Commands

This chapter provides a detailed explanation of the Quality of Service (QoS) commands. The following QoS commands are available in the FASTPATH software QoS module.

The commands are divided into these different groups:


Access Control List (ACL) Commands

Access control lists (ACLs) ensure that only authorized users have access to specific resources while blocking off any unwarranted attempts to reach network resources.

access-list

This command creates an Access control list (ACL) that is identified by the parameter <accesslistnumber>. The ACL number is an integer from 1 to 199. The range 1 to 99 is for normal ACL lists and 100 to 199 is for extended ACL lists. The ACL rule is created with the option of permit or deny. The protocol to filter for an ACL rule is specified by specifying cmp, igmp, ip, tcp, or udp. The command specifies a source IP address and source mask for matching the ACL rule specified by the srcip and srcmask parameters. The source layer 4 port match conditions for the ACL rule are specified by the port value parameter. The <startport> and <endport> parameters identify the first and last ports in the port range. They have values from 0 to 65535. The ending port must have a value equal or greater than the starting port. The starting port, ending port, and all ports in between will be part of the destination port range. The <portvalue> parameter uses a single keyword notation and currently has the values of domain, echo, ftp, ftpdata, http, smtp, snmp, telnet, tftp, and www. Each of these values translates into its equivalent port number, which is used as both the start and end of a port range. The command specifies a destination IP address and destination mask that must match the ACL rule specified by the dstip and dstmask parameters. The command specifies the TOS for an ACL rule depending on a match of precedence or DSCP values using the parameters tos, tosmask, dscp.

no access-list

This command deletes an ACL that is identified by the parameter <accesslistnumber> from the system.

ip access-group

This command attaches a specified ACL to an interface.

ip access-group all

This command attaches a specified ACL to all interfaces.

show ip access-lists

This command displays an Access control list (ACL) and all of the rules that are defined for the ACL. The <accesslistnumber> is the number used to identify the ACL.


Bandwidth Provisioning (BP) Commands

The Bandwidth Provisioning feature enables network providers to deliver varying levels of allocated bandwidth to users sharing the same physical interface. By mapping a subscriber’s traffic profile to a predefined policy and then actively provisioning the minimum and maximum bandwidth consumed by that subscriber, the network provider can provide enhanced service offerings to its customers.

bwallocation

This command creates a bandwidth allocation profile. The <name> field is an alphanumeric string up to 15 characters. The <name> field also supports the dash
“-” character.



Note - The CLI mode is changed to Bwallocation Config when this command is successfully executed.


no bwallocation

This command deletes a bandwidth allocation profile from the system. The <name> field is the user supplied name associated with the bandwidth allocation profile. A bandwidth allocation profile may not be deleted while it is associated with a traffic class.

bwallocation

This command associates a bandwidth allocation profile with a traffic class. The <bwprofile> parameter must represent a valid bandwidth allocation profile. The sum of the bandwidth allocation profile minimum bandwidth of all traffic classes associated with the same interface must not exceed the total bandwidth of the interface.

There is no restriction on the sum of the maximum bandwidth of all traffic classes attached to the same port. When a traffic class is attached to a port-channel (LAG) interface, the bandwidth allocation profile minimum bandwidth parameter will not be applicable to the traffic class.

maxbandwidth

This commands configures the maximum bandwidth for this bandwidth allocation profile. The bandwidth is specified in Mbps. The <maxbandwidth> parameter will be a value from 0 to the maximum bandwidth of the interface associated with this profile. The bandwidth allocation profile maximum bandwidth must be greater than or equal to the minimum bandwidth. If this value is set to 0, it will not allow any traffic for this bandwidth allocation profile.

no maxbandwidth

This commands resets the maximum bandwidth for this bandwidth allocation profile to the default value.

minbandwidth

This command configures the minimum bandwidth for this bandwidth allocation profile. The bandwidth is specified in Mbps. The <minbandwidth> parameter will be a value from 0 to the maximum bandwidth of the interface associated with this profile and represents the minimum data rate for this bandwidth allocation profile.

The bandwidth allocation profile minimum bandwidth must be smaller or equal to the maximum bandwidth.

no minbandwidth

This command resets the minimum bandwidth for this bandwidth allocation profile to the default value.

port

This command attaches a specific interface to this traffic class. The <slot/port> must indicate a valid <slot/port>.

show bwp-trafficclass detailed

This command displays the traffic class information for the specified traffic class.

The following attributes are only displayed if there is a Bandwidth Allocation Profile associated with this traffic class.


TABLE 6-3 Entry Definitions for show bwp-trafficclass detailed With Bandwidth Allocation Profile Association

Entry

Definition

Minimum Bandwidth

Displays the user-defined minimum bandwidth of this traffic class.

Maximum Bandwidth

Displays the user-defined maximum bandwidth of this traffic class.


show bwp-trafficclass summary

This command displays the traffic class information for all traffic classes in the system.

show bwp-trafficclass allocatedbw

This command displays the bandwidth allocated by traffic classes for the specified interface or all interfaces. The allocated minimum bandwidth cannot exceed the interface bandwidth, unless the interface is a port-channel (LAG) interface.

show bwp-bwallocation detailed

This command displays the bandwidth allocation information for the specified bandwidth allocation profile.

show bwp-bwallocation summary

This command displays the bandwidth allocation information for all bandwidth allocation profiles in the system.

traffic-class

This command creates a traffic class. The <name> field is an alphanumeric string up to 15 characters. The <name> field also supports the dash “-” character.



Note - The CLI mode is changed to Traffic-Class Config when this command is successfully executed.


no traffic-class

This command deletes a traffic class from the system. The <name> field is the administrator supplied name associated with the traffic class. Upon deletion of a traffic, all traffic class association with a bandwidth allocation profile is automatically removed.

vlan

This command associates a VLAN with a traffic class. The <vlanid> field is the VLAN ID for the traffic class within the range of 1 to 4094.

The VLAN parameter can identify an invalid vlan (The vlan does not need to exist in the system.)

weight

This command configures the priority for this traffic class. The <weight> parameter will be a value between 1 and 1024.


Differentiated Services Commands

This section contains the CLI commands used for the QoS Differentiated Services (DiffServ) package.

The user configures DiffServ in several stages by specifying:



Note - The only way to remove an individual match criterion from an existing class definition is to delete the class and re-create it.


Packets are filtered and processed based on defined criteria. The filtering criteria is defined by a class. The processing is defined by a policy's attributes. Policy attributes may be defined on a per-class instance basis, and it is these attributes that are applied when a match occurs.

Packet processing begins by testing the match criteria for a packet. A policy is applied to a packet when a class match within that policy is found.

Note that the type of class - all, any, or acl - has a bearing on the validity of match criteria specified when defining the class. A class type of 'any' processes its match rules in an ordered sequence; additional rules specified for such a class simply extend this list. A class type of acl obtains its rule list by interpreting each ACL rule definition at the time the Diffserv class is created. Differences arise when specifying match criteria for a class type all, since only one value for each non-excluded match field is allowed within a class definition. If a field is already specified for a class, all subsequent attempts to specify the same field fail, including the cases where a field can be specified multiple ways through alternative formats. The exception to this is when the exclude option is specified, in which case this restriction does not apply to the excluded fields.

The following class restrictions are imposed by the FASTPATH DiffServ design:

Regarding nested classes, referred to here as class references, a given class definition can contain at most one reference to another class, which can be combined with other match criteria. The referenced class is truly a reference and not a copy, since additions to a referenced class affect all classes that reference it. Changes to any class definition currently referenced by any other class must result in valid class definitions for all derived classes otherwise the change is rejected. A class reference may be removed from a class definition.

The user can display summary and detailed information for classes, policies and services. All configuration information is accessible via the CLI, Web, and SNMP user interfaces.

diffserv

This command sets the DiffServ operational mode to active. While disabled, the DiffServ configuration is retained and can be changed, but it is not activated. When enabled, Diffserv services are activated.

no diffserv

This command sets the DiffServ operational mode to inactive. While disabled, the DiffServ configuration is retained and can be changed, but it is not activated. When enabled, Diffserv services are activated.


Class Commands

The class command set is used in DiffServ to define:

This set of commands consists of class creation/deletion and matching, with the class match commands specifying layer 3, layer 2, and general match criteria. The class match criteria are also known as class rules, with a class definition consisting of one or more rules to identify the traffic belonging to the class. Note that once a class match criterion is created for a class, it cannot be changed or deleted - the entire class must be deleted and re-created.

The CLI command root is class-map.

class-map

This command defines a new DiffServ class of type match-all, match-any or match-access-group. The <classname> parameter is a case sensitive alphanumeric string from 1 to 31 characters uniquely identifying the class (Note: the class name 'default' is reserved and must not be used here).

When used without any match condition, this command enters the class-map mode. The <classname> is the name of an existing DiffServ class (note: the class name 'default' is reserved and is not allowed here)

The class type of match-all indicates all of the individual match conditions must be true for a packet to be considered a member of the class.

The class type of match-any indicates only one of the match criteria must be true for a packet to belong to the class; multiple matching criteria are evaluated in a sequential order, with the highest precedence awarded to the first criterion defined for the class.

The class type of match-access-group indicates the individual class match criteria are evaluated based on an access list (ACL). The <aclid> parameter is an integer specifying an existing ACL number (refer to the appropriate ACL documentation for the valid ACL number range). A match-access-group class type copies its set of match criteria from the current rule definition of the specified ACL number. All elements of a single ACL Rule are treated by DiffServ as a grouped set, similar to class type all. For any class, at least one class match condition must be specified for the class to be considered valid.



Note - The class match conditions are obtained from the referenced access list at the time of class creation. Thus, any subsequent changes to the referenced ACL definition do not affect the DiffServ class. To pick up the latest ACL definition, the DiffServ class must be deleted and re-created.


This command may be used without specifying a class type to enter the Class-Map Config mode for an existing DiffServ class.



Note - The CLI mode is changed to Class-Map Config when this command is successfully executed.


no class-map

This command eliminates an existing DiffServ class. The <classname> is the name of an existing DiffServ class (note: the class name 'default' is reserved and is not allowed here). This command may be issued at any time; if the class is currently referenced by one or more policies or by any other class, this deletion attempt will fail.

class-map rename

This command changes the name of a DiffServ class. The <classname> is the name of an existing DiffServ class. The <newclassname> parameter is a case-sensitive alphanumeric string from 1 to 31 characters uniquely identifying the class (Note: the class name ‘default’ is reserved and must not be used here).

match any

This command adds to the specified class definition a match condition whereby all packets are considered to belong to the class.

match class-map

This command adds to the specified class definition the set of match conditions defined for another class. The <refclassname> is the name of an existing DiffServ class whose match conditions are being referenced by the specified class definition.



Note - There is no [not] option for this match command.


no match class-map

This command removes from the specified class definition the set of match conditions defined for another class. The <refclassname> is the name of an existing DiffServ class whose match conditions are being referenced by the specified class definition. Note: there is no [not] option for this match command.

match cos

This command adds to the specified class definition a match condition based on the class of service of a packet, which is defined as the three bit priority field in the 802.1p header. The CoS value is an integer from 0 to 7. The optional [not] parameter has the effect of negating this match condition for the class (i.e., match all class of service values except for what is specified here).

match destination-address mac

This command adds to the specified class definition a match condition based on the destination MAC address of a packet. The <macaddr> parameter is any layer 2 MAC address formatted as six, two-digit hexadecimal numbers separated by colons (e.g., 00:11:22:dd:ee:ff). The <macmask> parameter is a layer 2 MAC address bit mask, which need not be contiguous, and is formatted as six, two-digit hexadecimal numbers separated by colons (e.g., ff:07:23:ff:fe:dc). The optional [not] parameter has the effect of negating this match condition for the class (i.e., match all destination MAC addresses except for what is specified here).

match dstip

This command adds to the specified class definition a match condition based on the destination IP address of a packet. The <ipaddr> parameter specifies an IP address. The <ipmask> parameter specifies an IP address bit mask; note that although similar to a standard subnet mask, this bit mask need not be contiguous. The optional [not] parameter has the effect of negating this match condition for the class (i.e., match all destination IP addresses except for what is specified here).

match dstl4port

This command adds to the specified class definition a match condition based on the destination layer 4 port of a packet using a single keyword or numeric notation or a numeric range notation.

To specify the match condition as a single keyword, the value for <portkey> is one of the supported port name keywords. The currently supported <portkey> values are: domain, echo, ftp, ftpdata, http, smtp, snmp, telnet, tftp, www. Each of these translates into its equivalent port number, which is used as both the start and end of a port range.

To specify the match condition using a numeric notation, one layer 4 port number is required. The port number is an integer from 0 to 65535.

To specify the match condition using a numeric range notation, two layer 4 port numbers are required and together they specify a contiguous port range. Each port number is an integer from 0 to 65535, but with the added requirement that the second number be equal to or greater than the first.

The optional [not] parameter has the effect of negating this match condition for the class (i.e., match all destination layer 4 port numbers except for the one specified here).

match ip dscp

This command adds to the specified class definition a match condition based on the value of the IP DiffServ Code Point (DSCP) field in a packet, which is defined as the high-order six bits of the Service Type octet in the IP header (the low-order two bits are not checked). The optional [not] parameter has the effect of negating this match condition for the class (i.e., match all IP DSCP values except for what is specified here). The <dscpval> value is specified as either an integer from 0 to 63, or symbolically through one of the following keywords: af11, af12, af13, af21, af22, af23, af31, af32, af33, af41, af42, af43, be, cs0, cs1, cs2, cs3, cs4, cs5, cs6, cs7, ef.



Note - The ip dscp, ip precedence, and ip tos match conditions are alternative ways to specify a match criterion for the same Service Type field in the IP header, but with a slightly different user notation.




Note - To specify a match on all DSCP values, use the match [not] ip tos <tosbits> <tosmask> command with <tosbits> set to 0 and <tosmask> set to 03 (hex).


match ip precedence

This command adds to the specified class definition a match condition based on the value of the IP Precedence field in a packet, which is defined as the high-order three bits of the Service Type octet in the IP header (the low-order five bits are not checked). The precedence value is an integer from 0 to 7. The optional [not] parameter has the effect of negating this match condition for the class (i.e., match all IP Precedence values except for what is specified here).



Note - The ip dscp, ip precedence, and ip tos match conditions are alternative ways to specify a match criterion for the same Service Type field in the IP header, but with a slightly different user notation.




Note - To specify a match on all Precedence values, use the match [not] ip tos <tosbits> <tosmask>command with <tosbits> set to 0 and <tosmask> set to 1F (hex).


match ip tos

This command adds to the specified class definition a match condition based on the value of the IP TOS field in a packet, which is defined as all eight bits of the Service Type octet in the IP header. The value of <tosbits> is a two-digit hexadecimal number from 00 to ff. The value of <tosmask> is a two-digit hexadecimal number from 00 to ff. The optional [not] parameter has the effect of negating this match condition for the class (i.e., match all IP Precedence values except for what is specified here). The <tosmask> denotes the bit positions in <tosbits> that are used for comparison against the IP TOS field in a packet. For example, to check for an IP TOS value having bits 7 and 5 set and bit 1 clear, where bit 7 is most significant, use a <tosbits> value of a0 (hex) and a <tosmask> of a2 (hex).



Note - The ip dscp, ip precedence, and ip tos match conditions are alternative ways to specify a match criterion for the same Service Type field in the IP header, but with a slightly different user notation.




Note - In essence, this the “free form” version of the IP DSCP/Precedence/TOS match specification in that the user has complete control of specifying which bits of the IP Service Type field are checked.


match protocol

This command adds to the specified class definition a match condition based on the value of the IP Protocol field in a packet using a single keyword notation or a numeric value notation.

To specify the match condition using a single keyword notation, the value for <protocol-name> is one of the supported protocol name keywords. The currently supported values are: icmp, igmp, ip, tcp, udp. Note that a value of ip is interpreted to match all protocol number values.

To specify the match condition using a numeric value notation, the protocol number is a standard value assigned by IANA and is interpreted as an integer from 0 to 255. Note: This command does not validate the protocol number value against the current list defined by IANA.

The optional [not] parameter has the effect of negating this match condition for the class (i.e., match allIP Protocol numbers except for the one specified here).

match source-address mac

This command adds to the specified class definition a match condition based on the source MAC address of a packet. The <address> parameter is any layer 2 MAC address formatted as six, two-digit hexadecimal numbers separated by colons (e.g., 00:11:22:dd:ee:ff). The <macmask> parameter is a layer 2 MAC address bit mask, which need not be contiguous, and is formatted as six, two-digit hexadecimal numbers separated by colons (e.g., ff:07:23:ff:fe:dc). The optional [not] parameter has the effect of negating this match condition for the class (i.e., match all source MAC addresses except for what is specified here).

match srcip

This command adds to the specified class definition a match condition based on the source IP address of a packet. The <ipaddr> parameter specifies an IP address. The <ipmask> parameter specifies an IP address bit mask; note that although it resembles a standard subnet mask, this bit mask need not be contiguous. The optional [not] parameter has the effect of negating this match condition for the class (i.e., match all source IP addresses except for what is specified here).

match srcl4port

This command adds to the specified class definition a match condition based on the source layer 4 port of a packet using a single keyword or numeric notation or a numeric range notation.

To specify the match condition as a single keyword notation, the value for <portkey> is one of the supported port name keywords (listed below).

The currently supported <portkey> values are: domain, echo, ftp, ftpdata, http, smtp, snmp, telnet, tftp, www. Each of these translates into its equivalent port number, which is used as both the start and end of a port range.

To specify the match condition as a numeric value, one layer 4 port number is required. The port number is an integer from 0 to 65535.

To specify the match condition as a range, rwo layer 4 port numbers are required and together they specify a contiguous port range. Each port number is an integer from 0 to 65535, but with the added requirement that the second number be equal to or greater than the first. The optional [not] parameter has the effect of negating this match condition for the class (i.e., match all source layer 4 ports except for those within the range specified here).

The optional [not] parameter has the effect of negating this match condition for the class (i.e., match all source layer 4 port numbers except for the one specified here).

match vlan

This command adds to the specified class definition a match condition based on the value of the layer 2 VLAN Identifier field of a packet. The VLAN ID is an integer from 1 to 4094. The optional [not] parameter has the effect of negating this match condition for the class (i.e., match all VLAN Identifier values except for what is specified here).


Policy Commands

The 'policy' command set is used in DiffServ to define:

The policy commands are used to associate a traffic class, which was defined by the class command set, with one or more QoS policy attributes. This association is then assigned to an interface in a particular direction to form a service. The user specifies the policy name when the policy is created.

The DiffServ CLI does not necessarily require that users associate only one traffic class to one policy. In fact, multiple traffic classes can be associated with a single policy, each defining a particular treatment for packets that match the class definition. When a packet satisfies the conditions of more than one class, preference is based on the order in which the classes were added to the policy, with the foremost class taking highest precedence.

This set of commands consists of policy creation/deletion, class addition/removal, and individual policy attributes. Note that the only way to remove an individual policy attribute from a class instance within a policy is to remove the class instance and re-add it to the policy. The values associated with an existing policy attribute can be changed without removing the class instance.

The CLI command root is policy-map.

bandwidth kbps

This command identifies a minimum amount of bandwidth to be reserved for the specified class instance within the named policy using an absolute rate notation. The committed information rate is specified in kilobits-per-second (Kbps) and is an integer from 1 to 4294967295.



Note - The actual bandwidth allocation does not occur until the policy is attached to an interface in a particular direction.




Note - The bandwidth kbps and percent commands are alternative ways to specify the same bandwidth policy attribute.


bandwidth percent

This command identifies a minimum amount of bandwidth to be reserved for the specified class instance within the named policy using a relative rate notation. The committed information rate is specified as a percentage of total link capacity and is an integer from 1 to 100.



Note - The actual bandwidth allocation does not occur until the policy is attached to an interface in a particular direction.




Note - The bandwidth kbps and percent commands are alternative ways to specify the same bandwidth policy attribute.


class

This command creates an instance of a class definition within the specified policy for the purpose of defining treatment of the traffic class through subsequent policy attribute statements. The <classname> is the name of an existing DiffServ class. Note that this command causes the specified policy to create a reference to the class definition.



Note - The CLI mode is changed to Policy-Class-Map Config when this command is successfully executed.


no class

This command deletes the instance of a particular class and its defined treatment from the specified policy. <classname> is the names of an existing DiffServ class. Note that this command removes the reference to the class definition for the specified policy.

mark ip-dscp

This command marks all packets for the associated traffic stream with the specified IP DSCP value.

The <dscpval> value is specified as either an integer from 0 to 63, or symbolically through one of the following keywords: af11, af12, af13, af21, af22, af23, af31, af32, af33, af41, af42, af43, be, cs0, cs1, cs2, cs3, cs4, cs5, cs6, cs7, ef.

mark ip-precedence

This command marks all packets for the associated traffic stream with the specified IP Precedence value. The IP Precedence value is an integer from 0 to 7.

police-simple

This command is used to establish the traffic policing style for the specified class. The simple form of the police command uses a single data rate and burst size, resulting in two outcomes: conform and nonconform. The conforming data rate is specified in kilobits-per-second (Kbps) and is an integer from 1 to 4294967295. The conforming burst size is specified in kilobytes (KB) and is an integer from 1 to 128.

For each outcome, the only possible actions are drop, set-dscp-transmit, set-prec-transmit, or transmit. In this simple form of the police command, the conform action defaults to transmit and the violate action defaults to drop. These actions can be set with this command once the style has been configured.

For set-dscp-transmit, a <dscpval> value is required and is specified as either an integer from 0 to 63, or symbolically through one of the following keywords: af11, af12, af13, af21, af22, af23, af31, af32, af33, af41, af42, af43, be, cs0, cs1, cs2, cs3, cs4, cs5, cs6, cs7, ef.

For set-prec-transmit, an IP Precedence value is required and is specified as an integer from 0-7.

police-single-rate

This command is used to establish the traffic policing style for the specified class. The single-rate form of the police command uses a single data rate and two burst sizes, resulting in three outcomes: conform, exceed and violate. The conforming data rate is specified in kilobits-per-second (Kbps) and is an integer from 1 to 4294967295. The conforming burst size is specified in kilobytes (KB) as an integer from 1 to 128. The exceeding burst size is specified in kilobytes (KB) as an integer from 1 to 128. Note that the exceeding burst size must be equal to or greater than the conforming burst size.

For each outcome, the only possible actions are drop, set-dscp-transmit, set-prec-transmit, or transmit. In this singlerate form of the police command, the conform action defaults to send, the exceed action defaults to drop, and the violate action defaults to drop. These actions can be set with this command once the style has been configured.

For set-dscp-transmit, a <dscpval> value is required and is specified as either an integer from 0 to 63, or symbolically through one of the following keywords: af11, af12, af13, af21, af22, af23, af31, af32, af33, af41, af42, af43, be, cs0, cs1, cs2, cs3, cs4, cs5, cs6, cs7, ef.

For set-prec-transmit, an IP Precedence value is required and is specified as an integer from 0-7.

police-two-rate

This command is used to establish the traffic policing style for the specified class. The two-rate form of the police command uses two data rates and two burst sizes, resulting in three outcomes: conform, exceed and violate. The first two data parameters are the conforming data rate and burst size. The conforming data rate is specified in kilobits-per-second (Kbps) and is an integer from 1 to 4294967295, while the conforming burst size is specified in kilobytes (KB) as an integer from 1 to 128. The next two data parameters are the peak data rate and burst size. The peak data rate is specified in kilobits-per-second (Kbps) as an integer from 1 to 4294967295, while the peak burst size is specified in kilobytes (KB) as an integer from 1 to 128. Note that the peak data rate must be equal to or greater than the conforming data rate.

For each outcome, the only possible actions are drop, set-dscp-transmit, set-prec-transmit, or transmit. In this two-rate form of the police command, the conform action defaults to send, the exceed action defaults to drop, and the violate action defaults to drop. These actions can be set with this command once the style has been configured.

For set-dscp-transmit, a <dscpval> value is required and is specified as either an integer from 0 to 63, or symbolically through one of the following keywords: af11, af12, af13, af21, af22, af23, af31, af32, af33, af41, af42, af43, be, cs0, cs1, cs2, cs3, cs4, cs5, cs6, cs7, ef.

For set-prec-transmit, an IP Precedence value is required and is specified as an integer from 0-7.

policy-map

This command establishes a new DiffServ policy. The <policyname> parameter is a case-sensitive alphanumeric string from 1 to 31 characters uniquely identifying the policy. The type of policy is specific to either the inbound or outbound traffic direction as indicated by the {in | out} parameter.



Note - The policy type dictates which of the individual policy attribute commands are valid within the policy definition.




Note - The CLI mode is changed to Policy-Map Config when this command is successfully executed.


no policy-map

This command eliminates an existing DiffServ policy. The <policyname> parameter is the name of an existing DiffServ policy. This command may be issued at any time; if the policy is currently referenced by one or more interface service attachments, this deletion attempt will fail.

policy-map rename

This command changes the name of a DiffServ policy. The <policyname> is the name of an existing DiffServ class. The <newpolicyname> parameter is a case-sensitive alphanumeric string from 1 to 31 characters uniquely identifying the policy.


Service Commands

The 'service' command set is used in DiffServ to define:

The service commands attach a defined policy to a directional interface. Only one policy may be assigned at any one time to an interface in a particular direction. The policy type (in, out) must match the interface direction to which it is attached.

This set of commands consists of service addition/removal.

The CLI command root is service-policy.

service-policy

This command attaches a policy to an interface in a particular direction. The command can be used in the Interface Config mode to attach a policy to a specific interface. Alternatively, the command can be used in the Global Config mode to attach this policy to all system interfaces. The direction value is either in or out. The <policyname> parameter is the name of an existing DiffServ policy, whose type must match the interface direction. Note that this command causes a service to create a reference to the policy.



Note - This command effectively enables DiffServ on an interface (in a particular direction). There is no separate interface administrative 'mode' command for DiffServ.




Note - This command will fail if any attributes within the policy definition exceed the capabilities of the interface. Once a policy is successfully attached to an interface, any attempt to change the policy definition such that it would result in a violation of said interface capabilities will cause the policy change attempt to fail.


no service-policy

This command detaches a policy from an interface in a particular direction. The command can be used in the Interface Config mode to detach a policy from a specific interface. Alternatively, the command can be used in the Global Config mode to detach this policy from all system interfaces to which it is currently attached. The direction value is either in or out. The <policyname> parameter is the name of an existing DiffServ policy. Note that this command causes a service to remove its reference to the policy.



Note - This command effectively disables DiffServ on an interface (in a particular direction). There is no separate interface administrative 'mode' command for DiffServ.



Show Commands

The 'show' command set is used in DiffServ to display configuration and status information for:

This information can be displayed in either summary or detailed formats. The status information is only shown when the DiffServ administrative mode is enabled; it is suppressed otherwise.

There is also a 'show' command for general DiffServ information that is available at any time.

show class-map

This command displays all configuration information for the specified class. The <classname> is the name of an existing DiffServ class.

If the Class Name is specified the following fields are displayed.


TABLE 6-8 Entry Definitions for show class-map With ClassName Specified

Display

Definition

Class Name

The name of this class.

Class Type

The class type (all, any, or acl) indicating how the match criteria are evaluated for this class. A class type of all means every match criterion defined for the class is evaluated simultaneously they must all be true to indicate a class match. For a type of any each match criterion is evaluated sequentially and only one need be true to indicate a class match. Class type acl rules are evaluated in a hybrid manner, with those derived from each ACL Rule grouped and evaluated simultaneously, while each such grouping is evaluated sequentially.

Match Criteria

The Match Criteria fields will only be displayed if they have been configured. They will be displayed in the order entered by the user. These are evaluated in accordance with the class type. The possible Match Criteria fields are: Class of Service, Destination IP Address, Destination Layer 4 Port, Destination MAC Address, Every, IP DSCP, IP Precedence, IP TOS, Protocol Keyword, Reference Class, Source IP Address, Source Layer 4 Port, Source MAC Address, and VLAN.

Values

The values of the Match Criteria.

Excluded

Indicates whether or not this Match Criteria is excluded.


If the Class Name is not specified, this command displays a list of all defined DiffServ classes. The following fields are displayed.


TABLE 6-9 Entry Definitions for show class-map Without ClassName Specified

Display

Definition

Class Name

The name of this class. (Note that the order in which classes are displayed is not necessarily the same order in which they were created.)

Class Type

The class type (all, any, or acl) indicating how the match criteria are evaluated for this class. A class type of all means every match criterion defined for the class is evaluated simultaneously they must all be true to indicate a class match.For a type of any each match criterion is evaluated sequentially and only one need be true to indicate a class match. Class type acl rules are evaluated in a hybrid manner, with those derived from each ACL Rule grouped and evaluated simultaneously, while each such grouping is evaluated sequentially.

ACL Number

The ACL number used to define the class match conditions at the time the class was created. This field is only meaningful if the class type is acl. (Note that the contents of the ACL may have changed since this class was created.)

Ref Class Name

The name of an existing DiffServ class whose match conditions are being referenced by the specified class definition.


show diffserv

This command displays the DiffServ General Status Group information, which includes the current administrative mode setting as well as the current and maximum number of rows in each of the main DiffServ private MIB tables. This command takes no options.

show policy-map

This command displays all configuration information for the specified policy. The <policyname> is the name of an existing DiffServ policy.

If the Policy Name is specified the following fields are displayed.


TABLE 6-11 Entry Definitions for show policy-map With PolicyName Specified

Display

Definition

Policy Name

The name of this policy.

Type

The policy type, namely whether it is an inbound or outbound policy definition.


The following information is repeated for each class associated with this policy (only those policy attributes actually configured are displayed).


TABLE 6-12 Entry Definitions for show policy-map With PolicyName Specified for Each Class Associated with Policy

Display

Definition

Class Name

The name of this class.

Mark CoS

Denotes the class of service value that is set in the 802.1p header of outbound packets. This is not displayed if the mark cos was not specified.

Mark IP DSCP

Denotes the mark/re-mark value used as the DSCP for traffic matching this class. This is not displayed if mark ip description is not specified using the police-two-rate command, or if policing is in use for the class under this policy.

Mark IP Precedence

Denotes the mark/re-mark value used as the IP Precedence for traffic matching this class. This is not displayed if precedence is not specified using police-two-rate command, or if either mark DSCP or policing is in use for the class under this policy.

Policing Style

This field denotes the style of policing, if any, used (simple, single rate, or two rate).

Committed Rate (Kbps)

The committed rate, used in simple policing, single-rate policing, and two-rate policing.

Committed Burst Size (KB)

The committed burst size, used in simple policing, single-rate policing, and two-rate policing.

Excess Burst Size (KB)

The excess burst size, used in single-rate policing.

Peak Rate (Kbps)

The peak rate, used in two-rate policing.

Peak Burst Size (KB)

The peak burst size, used in two-rate policing.

Conform Action

The current setting for the action taken on a packet considered to conform to the policing parameters. This is not displayed if policing is not in use for the class under this policy.

Conform DSCP Value

This field shows the DSCP mark value if the conform action is markdscp.

Conform IP Precedence Value

This field shows the IP Precedence mark value if the conform action is markprec.

Exceed Action

The current setting for the action taken on a packet considered to exceed to the policing parameters. This is not displayed if policing not in use for the class under this policy.

Exceed DSCP Value

This field shows the DSCP mark value if this action is markdscp.

Exceed IP Precedence Value

This field shows the IP Precedence mark value if this action is mark-prec.

Non-Conform Action

The current setting for the action taken on a packet considered to not conform to the policing parameters. This is not displayed if policing not in use for the class under this policy.

Non-Conform DSCP Value

The DSCP mark value if this action is markdscp.

Non-Conform IP Precedence Value

The IP Precedence mark value if this action is markprec.

Bandwidth

The minimum amount of bandwidth reserved in either percent or kilobits-per-second.

Expedite Burst Size (KBytes)

The maximum guaranteed amount of bandwidth reserved in either percent or kilobits-per-second format.

Shaping Average

This field is displayed if average shaping is in use. Indicates whether average or peak rate shaping is in use, along with the parameters used to form the traffic shaping criteria, such as CIR and PIR. This is not displayed if shaping is not configured for the class under this policy.

Shape Committed Rate (Kbps)

This field is displayed if average or peak rate shaping is in use. It displays the shaping committed rate in kilobits-per-second.

Shape Peak Rate (Kbps)

This field is displayed if peak rate shaping is in use. It displays the shaping peak rate in kilobits-per-second.

Random Drop Minimum Threshold

The RED minimum threshold.This is not displayed if the queue depth management scheme is not RED.

Random Drop Maximum Threshold

The RED maximum threshold.This is not displayed if the queue depth management scheme is not RED.

Random Drop Maximum Drop Probability

The RED maximum drop probability.This is not displayed if the queue depth management scheme is not RED.

Random Drop Sampling Rate

The RED sampling rate.This is not displayed if the queue depth management scheme is not RED.

Random Drop Decay Exponent

The RED decay exponent.This is not displayed if the queue depth management scheme is not RED.


If the Policy Name is not specified this command displays a list of all defined DiffServ policies. The following fields are displayed.


TABLE 6-13 Entry Definitions for show policy-map Without PolicyName Specified

Display

Definition

Policy Name

The name of this policy. (Note that the order in which the policies are displayed is not necessarily the same order in which they were created.)

Policy Type

The policy type, namely whether it is an inbound or outbound policy definition.

Class Members

List of all class names associated with this policy.


show diffserv service

This command displays policy service information for the specified interface and direction. The <slot/ port> parameter specifies a valid slot/port number for the system. The direction parameter indicates the interface direction of interest.

show diffserv service brief

This command displays all interfaces in the system to which a DiffServ policy has been attached. The direction parameter is optional; if specified, only services in the indicated direction are shown, otherwise service information is shown for both directions, where applicable.

The following information is repeated for interface and direction (only those interfaces configured with an attached policy are shown).


TABLE 6-16 Entry Definitions for show diffserv service brief For Interface and Direction

Entry

Definition

Interface

Valid slot and port number separated by forward slashes.

Direction

The traffic direction of this interface service, either in or out

OperStatus

The current operational status of this DiffServ service interface.

Policy Name

The name of the policy attached to the interface in the indicated direction.


show policy-map interface

This command displays policy-oriented statistics information for the specified interface and direction. The <slot/port> parameter specifies a valid interface for the system. The direction parameter indicates the interface direction of interest.



Note - This command is only allowed while the DiffServ administrative mode is enabled.


The following information is repeated for each class instance within this policy.


TABLE 6-18 Entry Definitions for show policy-map interface For Each Class Instance

Entry

Definition

Class Name

The name of this class instance.

In Offered Octets/Packets

A count of the octets/packets offered to this class instance before the defined DiffServ treatment is applied. Only displayed for the 'in' direction.

In Discarded Octets/Packets

A count of the octets/packets discarded for this class instance for any reason due to DiffServ treatment of the traffic class. Only displayed for the 'in' direction.

Tail Dropped Octets/Packets

A count of the octets/packets discarded due to tail dropping from a transmission queue, typically due to the effects of traffic shaping. These counts may not be supported on all platforms. Only displayed for the 'out' direction.

Random Dropped Octets/Packets

A count of the octets/packets discarded due to WRED active queue depth management, typically due to the effects of traffic shaping. These counts are only applicable for a class instance whose policy attributes includes random dropping, and may not be supported on all platforms. Only displayed for the 'out' direction.

Shape Delayed Octets/Packets

A count of the octets/packets that were delayed due to traffic shaping. These counts are only applicable for a class instance whose policy attributes includes shaping, and may not be supported on all platforms. Only displayed for the'out' direction.

Sent Octets/Packets

A count of the octets/packets forwarded for this class instance after the defined DiffServ treatment was applied. In this case, forwarding means the traffic stream was passed to the next functional element in the data path, such as the switching or routing function or an outbound link transmission element. Only displayed for the 'out' direction.




Note - None of the counters listed here are guaranteed to be supported on all platforms. Only supported counters are shown in the display output.


show service-policy

This command displays a summary of policy-oriented statistics information for all interfaces in the specified direction. The direction parameter indicates the interface direction of interest.

This command enables or disables the route reflector client. A route reflector client relies on a route reflector to re-advertise its routes to the entire AS. The possible values for this field are enable and disable.

The following information is repeated for each interface and direction (only those interfaces configured with an attached policy are shown).


TABLE 6-19 Entry Definitions for show service-policy

Entry

Definition

Interface

Valid slot and port number separated by forward slashes.

Dir

The traffic direction of this interface service, either in or out.

Operational Status

The current operational status of this DiffServ service interface.

Offered Packets

A count of the total number of packets offered to all class instances in this service before their defined DiffServ treatment is applied. These are overall per-interface per-direction counts.

Discarded Packets

A count of the total number of packets discarded for all class instances in this service for any reason due to DiffServ treatment. These are overall per-interface per-direction counts.

Sent Packets

A count of the total number of packets forwarded for all class instances in this service after their defined DiffServ treatments were applied. In this case, forwarding means the traffic stream was passed to the next functional element in the data path, such as the switching or routing function or an outbound link transmission element. These are overall per-interface per-direction counts.

Policy Name

The name of the policy attached to the interface.




Note - None of the counters listed here are guaranteed to be supported on all platforms. Only supported counters are shown in the display output.