MyWebUniversity.com Home Page
 



OpenSolaris man pages main menu


System Administration Commands                         psrset(1M)



NAME
     psrset - creation and management of processor sets

SYNOPSIS
     psrset -a [-F] processorsetid processorid...


     psrset -b processorsetid pid [/lwpid]...


     psrset -c [-F] [processorid]...


     psrset -d processorsetid...


     psrset -e processorsetid command [argument(s)]


     psrset -f processorsetid


     psrset [-i] [processorsetid]...


     psrset -n processorsetid


     psrset -p [processorid]...


     psrset [-q] [pid [/lwpid]...


     psrset -Q [processorsetid]...


     psrset -r [-F] processorid...


     psrset -u pid [/lwpid]...


     psrset -U [processorsetid]...


DESCRIPTION
     The psrset utility  controls  the  management  of  processor
     sets.  Processor sets allow the binding of processes or LWPs
     to groups of processors, rather than just a  single  proces-
     sor. Processors assigned to processor sets can run only LWPs
     that have been bound to that processor set.



SunOS 5.11          Last change: 25 Feb 2008                    1






System Administration Commands                         psrset(1M)



     This command cannot be used to modify processor  disposition
     when  pools  are enabled. Use pooladm(1M) and poolcfg(1M) to
     modify processor  set  configuration  through  the  resource
     pools facility.

OPTIONS
     The following options are supported:

     -a    Assign the specified processors to the specified  pro-
           cessor  set.  With  the additional -F option, all LWPs
           bound to the  specified  processors  will  be  unbound
           prior to changing processor sets.

           This  option  is  restricted   to   users   with   the
           PRIVSYSRESCONFIG privilege.


     -b    Bind all or a subset of  the  LWPs  of  the  specified
           processes to the specified processor set.

           LWPs bound to a processor set are  restricted  to  run
           only on the processors in that set. Processes can only
           be bound to non-empty processor sets, that is, proces-
           sor sets that have had processors assigned to them.

           Bindings are inherited,  so  new  LWPs  and  processes
           created  by a bound LWP have the same binding. Binding
           an interactive shell  to  a  processor,  for  example,
           binds all commands executed by the shell.

           This  option  is  restricted   to   users   with   the
           PRIVSYSRESCONFIG privilege.


     -c    Create a new processor set and displays the  new  pro-
           cessor set ID. With the additional -F option, all LWPs
           bound to the  specified  processors  will  be  unbound
           prior  to  assigning  them  to the processor set being
           created.

           If a list of processors is given, it also attempts  to
           assign  those processors to the processor set. If this
           succeeds, the processors are idle until LWPs are bound
           to  the  processor  set.  This option is restricted to
           users with the PRIVSYSRESCONFIG privilege.

           Only a limited number of processor sets can be  active
           (created  and  not  destroyed)  at  a given time. This
           limit is always be greater than the number of  proces-
           sors  in the system. If the -c option is used when the
           maximum number of processor sets  is  already  active,
           the command fails.



SunOS 5.11          Last change: 25 Feb 2008                    2






System Administration Commands                         psrset(1M)



           The following format is used for  the  first  line  of
           output  of  the  -c option when the LCMESAGES locale
           category specifies the "C" locale. In  other  locales,
           the   strings  created,  processor,  and  set  can  be
           replaced with more appropriate  strings  corresponding
           to the locale.

             "created processor set %d\n" processor set ID




     -d    Remove the specified processor set, releasing all pro-
           cessors and processes associated with it.

           This  option  is  restricted   to   users   with   the
           PRIVSYSRESCONFIG privilege.


     -e    Execute a command (with  optional  arguments)  in  the
           specified processor set.

           The command process and any child processes  are  exe-
           cuted only by processors in the processor set.

           This  option  is  restricted   to   users   with   the
           PRIVSYSRESCONFIG privilege.


     -f    Disables interrupts  for  all  processors  within  the
           specified processor set. See psradm(1M).

           If some processors in the set cannot have their inter-
           rupts  disabled, the other processors still have their
           interrupts disabled, and the command reports an  error
           and return non-zero exit status.

           This  option  is  restricted   to   users   with   the
           PRIVSYSRESCONFIG privilege.


     -F    Forces  the  specified  processor  set  operation   by
           unbinding  all  threads bound to the specified proces-
           sor. Only the -a or the -r option can be used in  com-
           bination   with   this   option.   Administrators  are
           encouraged to use the -Q option for pbind(1M) to  find
           out which threads will be affected by such operation.


     -i    Display a list of processors assigned  to  each  named
           processor  set. If no argument is given, a list of all
           processor sets and the processors assigned to them  is



SunOS 5.11          Last change: 25 Feb 2008                    3






System Administration Commands                         psrset(1M)



           displayed.  This  is also the default operation if the
           psrset command is not given an option.


     -n    Enable interrupts for all processors within the speci-
           fied processor set. See psradm(1M).

           This  option  is  restricted   to   users   with   the
           PRIVSYSRESCONFIG privilege.


     -p    Display the processor set assignments for  the  speci-
           fied  list of processors. If no argument is given, the
           processor set assignments for all  processors  in  the
           system is given.


     -q    Display the processor set bindings  of  the  specified
           processes  or  of  all processes. If a process is com-
           posed of multiple LWPs which have  different  bindings
           and  the  LWPs are not explicitly specified, the bind-
           ings of only one of the bound LWPs is  displayed.  The
           bindings  of  a  subset  of  LWPs  can be displayed by
           appending "/lwpids" to the process IDs. Multiple  LWPs
           may  be  selected  using  "-"  and "," delimiters. See
           EXAMPLES.


     -Q    Display the LWPs bound to the specified list  of  pro-
           cessor sets, or all LWPs with processor set bindings.


     -r    Remove a list of processors from their current proces-
           sor  sets.  Processors  that are removed return to the
           general pool of processors.

           Processors with LWPs bound to them using pbind(1M) can
           be  assigned  to  or removed from processor sets using
           the -F option.

           This  option  is  restricted   to   users   with   the
           PRIVSYSRESCONFIG privilege.


     -u    Remove the processor set bindings of a subset  or  all
           the  LWPs of the specified processes, allowing them to
           be executed on any on-line processor if they  are  not
           bound to individual processors through pbind.

           Users  with  the  PRIVSYSRESCONFIG  privilege   can
           unbind  any  process  or LWP from any active processor
           set. Other users can unbind processes  and  LWPs  from



SunOS 5.11          Last change: 25 Feb 2008                    4






System Administration Commands                         psrset(1M)



           processor  sets  that  do  not  have the PSETNOESCAPE
           attribute set. In addition, the user must have permis-
           sion  to  control  the affected processes; the real or
           effective user ID of the user must match the  real  or
           saved user ID of the target processes.


     -U    Removes the bindings of all LWPs bound to  the  speci-
           fied  list  of processor sets, or to any processor set
           if no argument is specified.


OPERANDS
     The following operands are supported:

     pid                 Specify pid as a process ID.


     lwpid               The set of LWPIDs of the specified  pro-
                         cess  to  be  controlled or queried. The
                         syntax for selecting LWP IDs is as  fol-
                         lows:

                           2,3,4-8       LWP IDs 2, 3, and 4 through 8
                           -4            LWPs whose IDs are 4 or below
                           4-            LWPs whose IDs are 4 or above



     processorid        Specify processorid  as  an  individual
                         processor  number (for example, 3), mul-
                         tiple  processor  numbers  separated  by
                         spaces  (for example, 1 2 3), or a range
                         of processor numbers (for example, 1-4).
                         It  is  also  possible to combine ranges
                         and     (individual     or     multiple)
                         processorids  (for  example,  1-3 5 7-8
                         9).


     processorsetid    Specify processorsetid as a  processor
                         set ID.


EXIT STATUS
     The following exit values are returned:

     0        Successful completion.


     non-0    An error occurred.




SunOS 5.11          Last change: 25 Feb 2008                    5






System Administration Commands                         psrset(1M)



ATRIBUTES
     See attributes(5) for descriptions of the  following  attri-
     butes:



     
           ATRIBUTE TYPE               ATRIBUTE VALUE       
    
     Availability                 SUNWcsu                     
    
     Stability Level              Stable                      
    


SEE ALSO
     pbind(1M),     pooladm(1M),     poolcfg(1M),     psradm(1M),
     psrinfo(1M),      processorbind(2),      processorinfo(2),
     psetbind(2),  psetcreate(2),  psetinfo(2),   sysconf(3C),
     libpool(3LIB), attributes(5), privileges(5)

DIAGNOSTICS
     The following output indicates that  the  specified  process
     did not exist or has exited:

       psrset: cannot query pid 31: No such process




     The following output indicates that the user does  not  have
     permission to bind the process:

       psrset: cannot bind pid 31: Not owner




     The following output indicates that the user does  not  have
     permission to assign the processor:

       psrset: cannot assign processor 4: Not owner




     The following output indicates that the specified  processor
     is not on-line, or the specified processor does not exist.

       psrset: cannot assign processor 8: Invalid argument





SunOS 5.11          Last change: 25 Feb 2008                    6






System Administration Commands                         psrset(1M)



     The following output indicates that an LWP in the  specified
     process  is  bound  to  a processor and cannot be bound to a
     processor set that does not include that processor:

       psrset: cannot bind pid 67: Device busy




     The following output indicates that the specified  processor
     could  not be added to the processor set. This can be due to
     bound LWPs on that processor, or because that processor can-
     not be combined in the same processor set with other proces-
     sors in that set, or because the processor is the  last  one
     in its current processor set:

       psrset: cannot assign processor 7: Device busy




     The following output indicates that the specified  processor
     set does not exist:

       psrset: cannot execute in processor set 8: Invalid argument




     The following output indicates that the  maximum  number  of
     processor sets allowed in the system is already active:

       psrset: cannot create processor set: Not enough space




     The following output indicates that the  pools  facility  is
     active.

       psrset: cannot assign processor 7: Operation not supported
       psrset: cannot bind pid 31: Operation not supported
       psrset: cannot bind pid 31: Operation not supported
       psrset: could not create processor set: Operation not supported
       psrset: could not remove processor set 1: Operation not supported
       psrset: cannot exec in processor set 1: Operation not supported
       psrset: cannot remove processor 7: Operation not supported
       psrset: cannot unbind pid 31: Operation not supported







SunOS 5.11          Last change: 25 Feb 2008                    7



OpenSolaris man pages main menu

Contact us      |       About us      |       Term of use      |       Copyright © 2000-2010 MyWebUniversity.com ™