Previous Table of Contents Next


The Priority Control Command (priocntl)

You can use the priocntl command to display or set scheduling parameters of specified processes. You can also use it to display the current configuration information for the process scheduler of a system or to execute a command with specified scheduling parameters.

Each process has a distinct class with a separate scheduling policy assigned to each class. The possible classes that are configured on your system are:

  System (SYS)
  Interactive (IA)
  Real-time (RT)
  Timesharing (TS)

For the timesharing class the user-supplied priority ranges from -20 to +20. The priority of a timeshare process, referred to as the user-mode priority, is inherited from the parent process. The system looks up the user-mode priority in its timesharing dispatch parameter table and adds in any nice or priocntl (user-supplied) priority and ensures a 0-59 range to create a global priority.

In the default configuration, a runnable real-time process runs before any other process. Inappropriate use of real-time processes can have a dramatic negative impact on system performance.

Displaying Basic Information About Process Classes

Follow this procedure to display basic information about process classes:

  Type priocntl -l and press Return. The process class and scheduling parameters for the system are displayed.

In this example, all classes are defined:

castle% priocntl -l
CONFIGURED CLASSES
==================

SYS (System Class)

TS (Time Sharing)
        Configured TS User Priority Range: -60 through 60

IA (Interactive)
        Configured IA User Priority Range: -60 through 60
RT (Real Time)
        Maximum Configured RT Priority: 59
castle%

Displaying the Global Priority of a Process

You can use the ps -ecl command to display the global priority of a process. The global priority is listed under the PRI column.

The following example shows the output from the ps -ecl command. Data in the PRI column shows that pageout has the highest priority at 98, and powerd has the lowest at 16:

castle% ps -ecl
 F S  UID  PID PPID  CLS PRI     ADDR   SZ    WCHAN TTY   TIME CMD
19 T    0    0    0  SYS  96 f0274e38    0          ?       0:01 sched
 8 S    0    1    0   TS  58 f5b2d888  162 f5b2da80 ?       0:00 init
19 S    0    2    0  SYS  98 f5b2d1c8    0 f02886a4 ?       0:00 pageout
19 S    0    3    0  SYS  60 f5b2cb08    0 f028aeb4 ?       0:11 fsflush
 8 S    0  205    1   TS  58 f5b2b6c8  448 f5d47b26 ?       0:00 sendmail
 8 S    0   91    1   TS  58 f5d10890  340 f597e07e ?       0:00 in.route
 8 S    0  277    1   TS  58 f5b2b008  350 f591ac78 ?       0:00 sac
 8 S    0  101    1   TS  58 f5b2bd88  445 f597e02e ?       0:00 rpcbind
 8 S    0  174    1   TS  52 f5b2c448  480 f5b2c640 ?       0:00 nscd
 8 S    0  128    1   TS  42 f5d101d0  446 f5d47f86 ?       0:00 inetd
 8 S    0  103    1   TS  20 f5d0fb10  462 f5d47fae ?       0:00 keyserv
 8 S    0  150    1   TS  58 f5d0f450  558 f5d47d7e ?       0:00 automoun
 8 S    0  133    1   TS  53 f5d0ed90  502 f5d47f5e ?       0:00 statd
 8 S    0  135    1   TS  33 f5d0e6d0  409 f5d47ee6 ?       0:00 lockd
 8 S    0  280  257   TS  48 f5d0e010  380 f5cc5706 ?       0:00 mibiisa
 8 S    0  154    1   TS  32 f5dea898  697 f5d47d56 ?       0:00 syslogd
 8 S    0  168    1   TS  48 f5dea1d8  360 f591aeb8 ?       0:00 cron
 8 S    0  184    1   TS  53 f5de9b18  648 f5d47c66 ?       0:00 lpsched
 8 S    0  285    1   IA  59 f5de9458  471 f5d47716 ?       0:00 fbconsol
 8 S    0  227    1   TS  52 f5de8d98  518 f5d479be ?       0:01 vold
 8 S    0  202    1   TS  16 f5de86d8  215 f5de88d0 ?       0:00 powerd
 8 S    0  215    1   TS  59 f5de8018  214 f5d47b4e ?       0:00 utmpd
 8 S 1001  282  270   IA  59 f5e4c8a0 2360 f5d47806 ?       0:34 Xsun
 8 S    0  278    1   TS  38 f5e4a6e0  368 f5d4782e console 0:00 ttymon
 8 S    0  257    1   TS  58 f5e4a020  444 f5d4791e ?       0:00 snmpdx
 8 S    0  268    1   TS  58 f5e6e8a8  738 f5eaf1f6 ?       0:00 snmpXdmi
 8 S    0  283  270   IA  59 f5e4bb20 1370 f5e4bb90 ?       0:00 dtlogin
 8 S    0  266    1   TS  58 f5e4b460  591 f5d478f6 ?       0:00 dmispd
 8 S    0  270    1   TS  48 f5e4ada0 1344 f597e6e6 ?       0:01 dtlogin
 8 S    0  281  277   TS  58 f5e4c1e0  371 f5e4c3d8 ?       0:00 ttymon
 8 S 1001  311  301   IA  59 f5e6e1e8  471 f5d476ee ?       0:00 fbconsol
 8 S 1001  301  283   IA  59 f5e6db28  392 f5e6db98 ?       0:01 Xsession
 8 S 1001  349  346   IA  59 f5e6d468  256 f5e6d660 pts/2   0:00 csh
 8 S 1001  315    1   IA  59 f5e6cda8  982 f5d476c6 ?       0:00 speckeys
 8 S 1001  366  349   IA  42 f5e6c6e8 1410 f5d47586 pts/2   0:01 dtsessio
 8 S 1001  374  366   IA  59 f5e6c028 1655 f5d474be ??      0:16 dtterm
 8 S 1001  346  301   IA  59 f5ef38b0 1211 f5d47676 pts/2   0:00 sdt_shel
 8 S 1001  347    1   IA  59 f5ef31f0  478 f5d47626 ?       0:00 dsdm
 8 S    0  367  128   TS  32 f5ef2b30  676 f5d475ae ?       0:00 rpc.ttdb
 8 S 1001  365    1   IA  59 f5ef2470  903 f5d475d6 pts/2   0:01 ttsessio
 8 S 1001  375  366   IA  49 f5ef1db0 1702 f5d474e6 ?       0:03 dtfile
 8 S 1001  376  366   IA  48 f5ef16f0 1118 f5d4750e ?       0:01 snapshot
 8 S 1001  373  366   IA  59 f5ef1030 1710 f5d4755e ?       0:04 dtwm
 8 S 1001  393  374   IA  43 f5f468b8  253 f5f93386 pts/5   0:00 csh
 8 S 1001  378    1   IA  59 f5f461f8  385 f5f46268 ?       0:00 sdtvolch
 8 S 1001  405  375   IA  59 f5f45b38 1687 f5f76738 ?       0:00 dtfile
 8 S 1001  445  378   IA  55 f5f45478  193 f591aaf8 ?       0:00 cat
 8 S 1001  387  374   IA  59 f5f44db8  255 f5f44fb0 pts/3   0:00 csh
 8 S 1001  407  387   I   48 f5f446f8 1140 f5d4732e pts/3   0:02 textedit
 8 S 1001  390  374   IA  55 f5f44038  252 f5f93986 pts/4   0:00 csh
 8 S 1001  417  393   IA  48 f5fa58c0  916 f5d472de pts/5   0:01 cmdtool
 8 S 1001  420  417   IA  48 f5fa5200  252 f5fc2b96 pts/6   0:00 csh
 8 S 1001  531  374   I   49 f5fa4480  256 f5fa4678 pts/7   0:00 csh
 8 O    0  56   531   IA  29 f5fa3dc0  199          pts/7   0:00 ps
 8 S    0  528  387   IA  58 f5fa3040   69 f5f8427e pts/3   0:00 sh
castle%

You can also use the /usr/sbin/dispadmin -l command to display process scheduler information.

The following example shows the output from the displadmin -l command:

castle% /usr/sbin/dispadmin -l
CONFIGURED CLASSES
==================
SYS     (System Class)
TS      (Time Sharing)
IA      (Interactive)
castle%

For complete information, refer to the dispadmin(1M) manual page.


Previous Table of Contents Next