ipqosconf

Synopsis

Description

The ipqosconf utility configures the Quality of Service facility of the Internet
Protocol (IP). Only superusers can use this command.

Without arguments, ipqosconf displays the actual IPQoS configuration.

Configuration is not preserved across reboot. You must apply the configuration every
time that the machine reboots. To apply the configuration early in the
boot phase, you can populate the /etc/inet/ipqosinit.conf file, which is then read
from the svc:/network/initial:default service.

Options

The following options are supported:

-aconf_file

Apply the configuration in conf_file. If the conf_file is -, ipqosconf reads from standard input.

-c

Populate the boot file with the current configuration.

-f

Flush the configuration.

-l

List the current applied configuration.

-L

List the current configuration in verbose mode.

In addition to the information that the -l option provides, the -L option provides filters and classes configured through other means than the iqposconf command. This option also provides the full set of filters that were created by ipqosconf by representing a multi-homed host in a configuration file

-s

Log messages to syslog during an -a operation.

-v

Toggle verbose mode during an -a operation.

The -v option causes all messages to go to the console in addition to their normal destination. Messages intended to go to syslog, because the -s flag is set or because it is a log message, still go to syslog as well as the console.

CONFIGURATION FILE

The configuration file is composed of a format version and a succession
of configuration (action) blocks. There are different configuration blocks for each type
of action that is being configured.

Format Version

The first line of the configuration file specifies the format version contained
in the configuration file.

The following entry specifies the format version:

fmt_version x.x

where x.x is the format version. 1.0 is the only supported version.

Configuration Blocks

Following the format version, are a succession of configuration (action) blocks that
are different for each type of action being configured. A configuration block
always has the following structure:

There must be exactly one configuration block belonging to module ipgpc. The
action must be named ipgpc.classify. All other actions should be reachable from
ipgpc by way of parameters of type action or the next_action of
a class.

The set of types that are used for parameters of the different
modules are:

red_action_name action
yellow_action_name action
green_action_name action
committed_rate uint32
committed_burst uint32
peak_rate uint32
<if present this signifies that this will be a two rate meter, not
a single rate meter>
peak_burst uint32
<this is the 'peak' burst size for a two rate meter, but
the 'excess' burst size for a single rate meter>
color_aware boolean
color_map integer_array
global_stats boolean

Types

action

A string of characters with a matching action definition. The character string can be up to twenty three characters in length. To allow for spaces the string needs to be enclosed in quotes and cannot span lines. Two special actions are pre-defined and can not have an explicit action definition. The two pre-defined actions are continue and drop. continue causes the packet that is passed to it to continue normal processing. drop causes the packet that is passed to it to be dropped.

address

A machine name or address recognized by getipnodebyname(3SOCKET). If a machine name is specified, and ip_version has been defined, the query is done using that address family. If a machine name is not specified and ip_version has not been defined, the query is done using the AI_DEFAULT flag to getipnodebyname()(..AF_INET6..). CIDR address masks following an IP address are allowed. Specify the CIDR address masks as 1-32 (for v4) or 1-128 (for v6). CIDR addresses are disallowed for node names.

enum

Either one of the supported values or comma delimited list of support values, enclosed in curly braces.

ifname

A non-NULL, existing interface name recognized by the SIOGLIFINDEX socket ioctl.

integer_array

A comma delimited set of range/value pairs, enclosed in curly braces.

Specify range in the format x-y, where x and y are integers that denote the range of array indexes to which the value applies. The minimum value for both x and y is 0. The maximum value for x is particular to the parameter. Any array indexes not referred to in the set of ranges are left at their previous value.

map_index

A non-negative integer used as an index into any maps associated with a parameter of this type.

The maximum value of this type is dictated by the number of entries in the associated maps. The index starts at 0.

A value of TRUE or FALSE that determines whether detailed statistics are switched on for this dscp action.

Specify TRUE to switch on or FALSE to switch off.

dscp_map

The integer_array that supplies the values that IP packets with a given dscp value have their dscp re-marked with.

The existing value is used to index into the array where the new value is taken from. The array is of size 64, meaning valid indexes are 0-63 and valid values are also 0-63.

dsfield

The DS field of the IP datagram header. This is an 8–bit value, with each bit position corresponding with the same one in the header; this enables matches to be done on the CU bits. If you specify this parameter, you must also specify the dsfield_mask parameter.

dsfield_mask

The mask applied to the dsfield parameter to determine the bits against which to match. This is an 8-bit value, with each bit position corresponding with the same one in the dsfield parameter.

global_stats

A value of TRUE or FALSE to enable or disable the statistic collection for this action.

green_action_name

The action to be executed for packets that are deemed to be green.

if_name

The name of an interface recognized by the SIOGLIFINDEX ioctl. This parameter is of type ifname.

ip_version

This parameter is of type enum and has valid values of V4 and V6.

If it is set to V4 only then only ipv4addresses are requested for a specified hostname. If it is set to V6, only ipv6 addresses are returned if there are any, otherwise v4 mapped v6 addresses are returned. If both V4 and V6 are specified, or if ip_version is not specified, then both ipv4 and ipv6 addresses are requested for a specified hostname.

max_limit

The maximum number of flow entries present at one time in the flowacct actions in the memory resident table.

next_action

The action to be executed when the current action is complete.

This value can be either the name of an action defined in the configuration file, or one of the two special action types: drop and continue.

peak_burst

The peak burst size, for a two rate meter, or excess burst size, for a single rate meter, in bits.

peak_rate

The peak rate in bits per second.

precedence

An integer that is used to order filters. If there are two matching filters that have the same priority value, the one with the lower precedence value is the one matched. This parameter should be used because the order of the filters in a configuration file has no influence on their relative precedence.

priority

An integer that represents the relative priority of a filter. If there are two matching filters, the one with the higher priority value is the one matched. Multiple filters can have the same priority.

projid

The project ID of the process sending the data. This value is always -1 for received traffic.

protocol

The Upper Layer Protocol against which this entry is matched.

red_action_name

The action to be executed for packets that are determined to be red.

saddr

The source address of the datagram.

sport

The source port of the datagram.

timeout

The timeout in milliseconds after which flows are written to the accounting file.

timer

The period in milliseconds at which timed-out flows are checked for.

user

The user ID or username of the process sending the data. This value is always -1 for received traffic.

window

The window size in ms.

yellow_action_name

The action to be executed for packets that are determined to be yellow.

Security

None.

Examples

Example 1 Sending All Traffic From eng to the AF 1 Class of Service

This example sends all traffic from eng to the AF 1 class of
service. It is documented in four separate steps:

Diagnostics

ipqosconf sends messages to syslog of facility user, severity notice when any
changes are made to the IPQoS configuration.

Errors that occur during an ipqosconf operation send an error message to
the console by default. For the application of a new configuration if
the -s option is set then these messages are sent to syslog
as facility user, severity error instead. If the -v option is present during
an application then all error and change notificationmessages are sent to the
console as well as their default destination.