This section contains full details about the parts of the IPQoS configuration file. The IPQoS boot-time activated policy is stored in the file /etc/inet/ipqosinit.conf. Although you can edit this file, the best practice for a new IPQoS system is to create a configuration file with a different name. Tasks for applying and debugging an IPQoS configuration are in Chapter 4, Starting Up and Maintaining IPQoS (Tasks).
The syntax of the IPQoS configuration file is shown in the next example. The example uses the following conventions:
computer-style type - Syntactical information that is provided to explain the parts of the configuration file. You do not type any text that appears in computer style type.
bold type - Literal text that you must type in the IPQoS configuration file. For example, you must always begin the IPQoS configuration file with fmt_version.
italics type - Variable text that you replace with descriptive information about your configuration. For example, you must always replace action_name or module_name with information that pertains to your configuration.
file_format_version ::= fmt_version version action_clause ::= action { name action_name module module_name params_clause | "" cf_clauses } action_name ::= string module_name ::= ipgpc | dlcosmk | dscpmk | tswtclmt | tokenmt | flowacct params_clause ::= params { parameters params_stats | "" } parameters ::= prm_name_value parameters | "" prm_name_value ::= param_name param_value params_stats ::= global_stats boolean cf_clauses ::= class_clause cf_clauses | filter_clause cf_clauses | "" class_clause ::= class { name class_name next_action next_action_name class_stats | "" } class_name ::= string next_action_name ::= string class_stats ::= enable_stats boolean boolean ::= TRUE | FALSE filter_clause ::= filter { name filter_name class class_name parameters } filter_name ::= string
The remaining text describes each major part of the IPQoS configuration file.
You use action statements to invoke the various IPQoS modules that are described in IPQoS Architecture and the diffserv Model.
When you begin the IPQoS configuration file, you must always begin with the version number. Then, you must add the following action to invoke the classifier:
fmt_version 1.0 action { module ipgpc name ipgpc.classify } |
Use the following syntax for all other action statements:
action { name action_name module module_name params_clause | "" cf_clauses }
Statement |
Definition |
---|---|
name action_name |
Assigns a name to the action |
module module_name |
Identifies the IPQoS module to be invoked, which must be one of the modules in Table 6–5 |
params_clause |
Can be parameters for the classifier to process, such as global statistics or the next action to process |
cf_clauses |
A set of zero or more class clauses or filter clauses |
The module definition indicates which module is to process the parameters in the action statement. The IPQoS configuration file can include the following modules.
Table 6–5 IPQoS Modules
Module Name |
Definition |
---|---|
ipgpc |
IP classifier |
dscpmk |
Marker to be used to create DS codepoints in IP packets |
dlcosmk |
Marker to be used with VLAN devices |
tokenmt |
Token bucket meter |
tswtclmt |
Time-sliding window meter |
flowacct |
Flow-accounting module |
You define a class clause for each class of traffic.
Use this syntax to define the remaining classes in the IPQoS configuration.
class { name class_name next_action next_action_name } |
To enable statistics taking on a particular class, you must first enable global statistic in the ipgpc.classify action statement. For more information, refer to action Statement.
Use the enable_stats TRUE statement whenever you want to turn on statistics for a class. If you do not need to gather statistics for a class, you can specify enable_stats FALSE. Alternatively, you can eliminate the enable_stats statement.
Traffic on an IPQoS-enabled network that you do not specifically define is relegated to the default class.
Filters are made up of selectors that group traffic flows into classes. These selectors specifically define the criteria to be applied to traffic of the class that was created in the class clause. If a packet matches all selectors of the highest-priority filter, the packet is considered to be a member of the filter's class. For a complete list of selectors that you can use with the ipgpc classifier, refer to Table 6–1.
You define filters in the IPQoS configuration file by using a filter clause, which has the following syntax:
filter { name filter_name class class_name parameters (selectors) }
The params clause contains processing instructions for the module that is defined in the action statement. Use the following syntax for the params clause:
params { parameters params_stats | "" } |
In the params clause, you use parameters that are applicable to the module.
The params_stats value in the params clause is either global_stats TRUE or global_stats FALSE. The global_stats TRUE instruction turns on UNIX-style statistics for the action statement where global statistics is invoked. You can view the statistics by using the kstat command. You must enable action statement statistics before you can enable per-class statistics.