The operating system includes various subsystems that define or extend the kernel. Kernel subsystem attributes are used to set kernel variables, which control subsystem behavior or track subsystem statistics. Attributes are assigned default values at boot time. If the default values of some attributes are not appropriate for your system, you must modify these values to provide optimal performance.
To display and modify kernel subsystem attributes, follow these steps:
Determine the operating system support for an attribute (Section 3.1)
Display the attribute values (Section 3.2)
Modify the attribute values (Section 3.3)
3.1 Operating System Support for Attributes
To determine if your version of the operating system supports a particular kernel subsystem attribute, use the following method:
Use the
sysconfig -q
subsystem [attribute] command.
If you do not specify an attribute, the system displays all the subsystem
attributes that can be modified with the
sysconfig
or
sysconfigdb
command.
If the subsystem is not configured, the operating
system displays a message similar to the following:
framework error: subsystem 'inet' not found
If you specify an attribute, only the information specific to that attribute is displayed. For example:
#sysconfig -q inet tcbhashsizeinet: tcbhashsize = 32
If the attribute is not supported or if
it cannot be accessed by using
sysconfig, the operating
system displays a message similar to the following:
inet: tcbhashsize = unknown attribute
Use the
dbx p
(print) command.
If you cannot access the attribute, the operating
system displays a message stating that the attribute is not defined or active.
For example:
#dbx -k /vmunixdbx version 5.1 Type 'help' for help.(dbx)p tcp_keepalive_default"tcp_keepalive_default" is not defined or not active(dbx)
See
sysconfig(8)dbx(1)3.2 Displaying Attribute Values
There are various methods that you can use to display the current value of a kernel subsystem attribute and other descriptive information. Use:
The Kernel Tuner (dxkerneltuner) graphical
user interface (GUI) to display permanent, current (run-time), minimum, and
maximum values of attributes.
Access the GUI through the Common Desktop Environment
(CDE) Application Manager window; select the
System_Admin
icon, and then select the
MonitoringTuning
icon.
You can
then choose the subsystem whose attributes you want to display.
The
sysconfig -q
subsystem
[attribute] command to display the current (run-time)
value of the specified attribute or, if an attribute is not specified, all
the attributes for the specified subsystem:
sysconfig -q subsystem [attribute]
For example:
#sysconfig -q vm ubc_maxpercentvm: ubc_maxpercent = 100
The
sysconfig -Q
subsystem
[attribute] command to display the maximum and minimum
values of the attributes for the specified subsystem.
If you specify a particular
attribute, the system displays information only for that attribute.
The command output also includes information about the operations that
you can perform on the attribute.
The following list describes some of the
sysconfig
attributes:
C
- The attribute can be modified when
the subsystem is initially loaded; that is, the attribute supports boot time,
permanent modifications.
R
- The attribute can be tuned at run time;
that is, you can modify the value that the system is currently using.
Q
- The attribute's current value can be
displayed (queried).
For example:
#sysconfig -Q vfs bufcachevfs: bufcache - type=INT op=CQ min_val=0 max_val=50
The output
of the previous command shows that the minimum value of the
bufcache
attribute is 0 and the maximum value is 50.
The output also shows
that you cannot modify the current (run-time) value.
The following example shows how to use the
dbx p
(print) command to display the current value of a kernel variable, instead
of an attribute.
For example:
#dbx -k /vmunixdbx version 5.1 Type 'help' for help.(dbx)p ipport_userreserved5000(dbx)
See
dxkerneltuner(8)sysconfig(8)dbx(1)3.3 Modifying Attribute Values
There are various methods that you can use to modify attribute values. The method you use depends on the version of the operating system you are running and whether you want to modify the current (run-time) value of an attribute or modify an attribute's permanent value. You must be root to modify attribute values.
The following sections describe how to modify the current and permanent
values.
3.3.1 Current Value
In some cases, you can modify the current (run-time) value of an attribute.
This allows you to determine if modifying an attribute will improve your system
performance without rebooting the system.
Not all attributes can be tuned
at run time, and the temporary modifications are lost when you reboot the
system.
Use the
sysconfig -Q
command to determine whether
an attribute can be tuned at run time.
To modify an attribute's current (run-time) value, use one of the following methods:
The Kernel Tuner (dxkerneltuner) GUI, if
the attribute supports this operation.
Access the GUI through the Common Desktop
Environment (CDE) Application Manager window; select the
System_Admin
icon, and then select the
MonitoringTuning
icon.
Choose the subsystem whose attribute you want to modify, and enter the new
value in the
Current Value
field.
The
sysconfig -r
command, if the attribute
supports this operation.
Use the following command syntax:
sysconfig -r subsystem attribute=value
For example:
#sysconfig -r inet tcp_keepinit=30tcp_keepinit: reconfigured
The following example shows how to use the
dbx assign
command to modify the current value of a kernel variable, instead of an attribute.
However, modifications made with the
dbx assign
command
are lost when you reboot the system.
Use the following command syntax:
dbx assign attribute=value
For example:
#dbx -k /vmunixdbx version 5.1 Type 'help' for help.(dbx)assign ipport_userreserved=6000060000(dbx)
See
dxkerneltuner(8)sysconfig(8)dbx(1)3.3.2 Permanent Value
To modify an attribute's permanent (boot-time) value, the
sysconfigtab
file must contain the subsystem name, the attribute
name, and the value of the attribute.
Do not manually modify the
sysconfigtab
file.
To make these modifications, use one of the following
methods:
The Kernel Tuner (dxkerneltuner) GUI.
Access
the GUI through the Common Desktop Environment (CDE) Application Manager window,
select the
System_Admin
icon, and then select the
MonitoringTuning
icon.
Choose the subsystem whose attribute you
want to modify, and enter the new value in the
Boot Time Value
field.
The
sysconfigdb
command.
Use the following
command syntax:
sysconfigdb -a -f stanza_file subsystem
The
stanza_file
is a specially
formatted file that contains the name of the subsystem and a list of attributes
and their values.
This file is merged into the
sysconfigtab
file.
See
stanza(4)
To use the new attribute value, you must invoke the
sysconfig
-r
command if the attribute can be tuned at run time, or reboot
the system.
In addition, you can use the
dbx patch
command to
modify the value of a variable, as well as the on-disk
/vmunix
image value.
See
dxkerneltuner(8)sysconfig(8)sysconfigdb(8)