System Administration Guide: Advanced Administration

ProcedureHow to Change Scheduling Parameters of a Timesharing Process (priocntl)

  1. (Optional) Assume the Primary Administrator role, or become superuser.

    The Primary Administrator role includes the Primary Administrator profile. To create the role and assign the role to a user, see Chapter 2, Working With the Solaris Management Console (Tasks), in System Administration Guide: Basic Administration.

  2. Change the scheduling parameters of a running timesharing process.

    # priocntl -s -m user-limit [-p user-priority] -i idtype idlist

    Lets you set the upper limit on the user priority range and change the current priority.

    -m user-limit

    When you use the -p option, specifies the maximum amount you can raise or lower the priority.

    -p user-priority

    Allows you to designate a priority.

    -i xidtype xidlist

    Uses a combination of xidtype and xidlist to identify the process or processes. The xidtype specifies the type of ID, such as the process ID or the user ID. Use xidlist to identify a list of process IDs or user IDs.

  3. Verify the process status.

    # ps -ecl | grep idlist

Example 12–8 Changing Scheduling Parameters of a Timesharing Process (priocntl)

The following example shows how to execute a command with a 500-millisecond time slice, a priority of 20 in the RT class, and a global priority of 120.

# priocntl -e -c RT -m 500 -p 20 myprog
# ps -ecl | grep myprog