System Administration Guide: Virtualization Using the Solaris Operating System

ProcedureHow to Use prctl to Display, Replace, and Verify the Value of a Control on a Project

  1. Become superuser or assume an equivalent role.

  2. Display the value of project.cpu-shares in the project group.staff.


    # prctl -n project.cpu-shares -i project group.staff
    project: 2: group.staff
    NAME    PRIVILEGE       VALUE    FLAG   ACTION     RECIPIENT
    project.cpu-shares
            privileged          1       -   none               -
            system          65.5K     max   none 
  3. Replace the current project.cpu-shares value 1 with the value 10.


    # prctl -n project.cpu-shares -v 10 -r -i project group.staff
    
  4. Display the value of project.cpu-shares in the project group.staff.


    # prctl -n project.cpu-shares -i project group.staff
    project: 2: group.staff
    NAME    PRIVILEGE       VALUE    FLAG   ACTION     RECIPIENT
    project.cpu-shares
            privileged         10       -   none               -
            system          65.5K     max   none