 |
» |
|
|
 |
The HP-UX Processor Sets allow a multi-processor system to
be partitioned into two or more groups of processors (CPU's), so
that CPU resources for selected applications or users can be isolated
from those of other applications or users. Processor Sets (also known
as psets) may be created and reconfigured dynamically by users who
have the appropriate privileges. Processor Sets was first shipped
as part of the optional Software Pack on HP-UX 11i in October 2001,
and is available in the Kernel from HP-UX 11i v1.6 by default.
Where Processor Sets is available in HP-UX, it is supported on all multi-processor
systems. Processor Sets is a full-functioning stand-alone feature,
but psets functionality is also fully supported by and integrated
with the optionally available Process Resource Manager (PRM)
product. Summary
of Change |  |
The Processor Sets functionality consists of several system
calls, one new library call, the underlying kernel support for those
calls, several changed system calls, one changed library call, several
changed commands, and one new command. The new Processor Sets system calls are: The changed Processor Sets system calls are: The new Processor Sets library call is pthread_pset_bind_np() which
is documented in the existing pthread_processor_bind_np(3T) manpage. To support the Processor Sets functionality, several commands
have been enhanced and a new command psrset(1M) was introduced. The following existing commands were enhanced to support Processor
Sets functionality: Details
of Change |  |
The new Processor Sets system calls are: - pset_create
Create a pset with no processors. pset_assign()
is used to add CPU's to a pset. - pset_destroy
Destroy a specific pset. - pset_assign
Place a CPU in a processor set. Because every processor
is in a pset (initially the "default pset"), pset_assign moves a
CPU from one pset to another. - pset_bind
Bind selected thread(s) or process(es) to a specific
pset. - pset_getattr
Get the attributes for a pset. Some example pset
attributes are the owner of the pset, or the access permissions
for the pset. - pset_setattr
Set the attributes for a pset. - pset_ctl
Query pset information, such as the pset binding
of the calling thread, or the number of CPU's in the pset.
The changed Processor Sets system calls: The new Processor Sets library call is: - pthread_pset_bind_np
/added to support psets and pset binding.
The changed Processor Sets commands are: - mpsched
A new option -f has been introduced
in mpsched to force the operation of binding of a process to a processor
if the HP Process Resource Manager is installed and configured. If mpsched is used without -f option in the presence
of HP PRM to bind a process to a processor, then an error message
is displayed. In order for this binding operation to go through,
the -f option needs to be used along with binding
options of mpsched. Moreover, in the presence of Processor Sets
functionality if mpsched is used to bind a process to a processor
or a ldom, across psets, then it prints the appropriate error message. - ps
The ps command has been enhanced to support the Processor Sets functionality
by adding two new options -z and -Z.
These two new options are added to enable the users to know to which
pset a pid is bound, and to list all the pids in a given pset. The description of the new options are: The -z option
adds a column "pset" before column "prmgrp/prmid". If
prmgrp and prmid are not present adds a column "pset" before the "pid" column.
The kernel pset, where all the kernel processes run, is displayed
as "KERN". Basically this option maps the pid with
a pset to which it is bound. This option doesn't take any arguments.
The -Z option
lists all the process ids bound to a specified pset. This option
takes a list of pset ids as arguments. If prmgrp and prmid are not
present, this option adds a pset column before the pid column in the listing.
- sar
The sar command has been enhanced to support Processor Sets functionality
by adding two new options -p and -P. The description of the new options are: - top
The top command has been enhanced to support the Processor Sets functionality
by adding two new options -p and -P. The description of the new options are: The -p
option takes the pset id as argument and displays load averages
and process state break down for system and processor set pset_id.
This option shows only the processes running on the processor set
pset_id. The -P
option displays a column PSET before column CPU for individual CPU
information. Also it displays a column PSET, before the column CPU
for each process information.
- uptime
The uptime command has been enhanced to support the Processor Sets functionality
by adding one new option -p. The -p option can be given with or without
an argument. If given with an argument, it takes pset id as an argument.
The -p option prints the current time, the length
of time the system has been up, and the number of users logged on
to the system in the first line of the output. The load averages
over the last 1, 5, and 15 minutes for the psets given in the command
line, pset_list, are displayed in the subsequent lines. If no arguments
are given, the load averages are displayed for all the psets in
the system. If pset id of an empty pset is given in the command line,
corresponding message is displayed. The -p option
cannot be used with other options. - id
The -P option of the id command has been enhanced to display correct prmid in
the presence of Processor Sets functionality. Also, the id command has been modified to return non-zero return values
on error conditions and displays an usage message on incorrect usage. - rtsched
Updated to support psets. A real-time thread only
runs, or competes for CPU's, within its pset.
The new Processor Sets command is: - psrset
The psrset command is new and was developed for the Processor Sets functionality.
This command creates and manages processor sets on a HP-UX system
supporting Processor Sets functionality. The psrset command supports different options which a user can use
to perform the following tasks: Assign a processor
to a given pset. Bind a pid to a given pset.
Destroy the specified pset.
Execute a command on a given
pset. Bind all the processes belonging
to a process group to a given pset. Display all the processors
and pset attributes for given pset or all psets in the system. Enable external I/O interrupts
for all processors in a given pset. Disable external I/O interrupts
for all processors in a given pset. Display the pset-processor
mapping for a given processor or for all processors in the system.
Display the pid - pset mapping
for a given pid or for all pids in the system. Remove the specified processor
from the pset and assign it to the default pset. Change the attributes of
a given pset. Unbind a given pid from a
pset to which it is currently bound. Bind all the processes owned
by a user id to the specified pset.
Impact |  |
Not applicable. Compatibility |  |
The behavior of mpctl has evolved as described above, though it is the same
as on HP-UX 11i with psets installed. There are no command compatibility issues because the enhanced
functionality in each command is accommodated in new options and
the behavior of the existing options is unchanged. Performance |  |
Not applicable. Obsolescence |  |
Not applicable. Documentation |  |
The manpages for all new and updated system and library calls,
and commands, are supplied with the system. A new manpage for command psrset(1M) is introduced in HP-UX
11i v1.6, see this manpage for details. The manpages of the following commands have been updated by
adding the description of the new functionality introduced: - getconf(1)
The following line has been added in the supported
inquiries section : PSET_SUPPORT - mpsched(1)
The SYNOPSIS section of has been changed. The description
of the -c and -l have been changed. The description
for the new -f option has been added. - ps(1)
The SYNOPSIS section has been changed. The description
for the -z and -Z options has
been added. - sar(1M)
The SYNOPSIS section has been changed. The descriptions
of the -u and -q options have
been changed. The description for the new -p and -P options
has been added. - top(1)
The SYNOPSIS section has been changed. In the Display
Description, the PSET field has been added. The description for
the new -p and -P options has
been added. - uptime(1)
The SYNOPSIS section has been changed. The description
for the new -p option has been added. In the EXAMPLES
section, an example to illustrate the use of the -p option
has been included. - id(1)
The SYNOPSIS section has been changed. The description
of the -P option has been changed. - rtsched(1)
The DESCRIPTION section has been updated to include
the psets information.
See the manpage of each command for specific information. The white paper of the Processor Sets functionality is available
at: http://docs.hp.com/hpux/pdf/5185-4322.pdf
|