[BACK]Return to renice.8 CVS log [TXT][DIR] Up to [local] / src / usr.bin / renice

Annotation of src/usr.bin/renice/renice.8, Revision 1.16

1.16    ! jmc         1: .\"    $OpenBSD: renice.8,v 1.15 2007/03/16 16:36:06 jmc Exp $
1.10      aaron       2: .\"
1.6       millert     3: .\" Copyright (c) 1983, 1991, 1993
                      4: .\"    The Regents of the University of California.  All rights reserved.
1.1       deraadt     5: .\"
                      6: .\" Redistribution and use in source and binary forms, with or without
                      7: .\" modification, are permitted provided that the following conditions
                      8: .\" are met:
                      9: .\" 1. Redistributions of source code must retain the above copyright
                     10: .\"    notice, this list of conditions and the following disclaimer.
                     11: .\" 2. Redistributions in binary form must reproduce the above copyright
                     12: .\"    notice, this list of conditions and the following disclaimer in the
                     13: .\"    documentation and/or other materials provided with the distribution.
1.14      millert    14: .\" 3. Neither the name of the University nor the names of its contributors
1.1       deraadt    15: .\"    may be used to endorse or promote products derived from this software
                     16: .\"    without specific prior written permission.
                     17: .\"
                     18: .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
                     19: .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
                     20: .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
                     21: .\" ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
                     22: .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
                     23: .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
                     24: .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
                     25: .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
                     26: .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
                     27: .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
                     28: .\" SUCH DAMAGE.
                     29: .\"
1.6       millert    30: .\"     from: @(#)renice.8     8.1 (Berkeley) 6/9/93
1.1       deraadt    31: .\"
1.6       millert    32: .Dd June 9, 1993
1.1       deraadt    33: .Dt RENICE 8
1.7       aaron      34: .Os
1.1       deraadt    35: .Sh NAME
                     36: .Nm renice
                     37: .Nd alter priority of running processes
                     38: .Sh SYNOPSIS
                     39: .Nm renice
                     40: .Ar priority
                     41: .Oo
1.15      jmc        42: .Op Fl g
                     43: .Ar pgrp ...
                     44: .Oc
                     45: .Oo
1.1       deraadt    46: .Op Fl p
                     47: .Ar pid ...
                     48: .Oc
                     49: .Oo
                     50: .Op Fl u
                     51: .Ar user ...
                     52: .Oc
                     53: .Sh DESCRIPTION
1.8       aaron      54: .Nm
1.11      aaron      55: alters the scheduling
1.15      jmc        56: .Em priority
                     57: of one or more running processes.
                     58: Processes may be selected using the parameters
                     59: .Ar pid
                     60: (process ID),
                     61: .Ar pgrp
                     62: (process group ID),
                     63: and
                     64: .Ar user
                     65: (user name).
                     66: If no flag is specified,
                     67: the default is to select by process ID.
1.1       deraadt    68: .Pp
1.11      aaron      69: Users other than the superuser may only alter the priority of
1.1       deraadt    70: processes they own,
1.10      aaron      71: and can only monotonically increase their
                     72: .Dq nice value
1.1       deraadt    73: within the range 0 to
                     74: .Dv PRIO_MAX
                     75: (20).
                     76: (This prevents overriding administrative fiats.)
1.11      aaron      77: The superuser
1.1       deraadt    78: may alter the priority of any process
                     79: and set the priority to any value in the range
                     80: .Dv PRIO_MIN
                     81: (\-20)
                     82: to
                     83: .Dv PRIO_MAX .
1.15      jmc        84: .Pp
1.1       deraadt    85: Useful priorities are:
                     86: 20 (the affected processes will run only when nothing else
                     87: in the system wants to),
1.10      aaron      88: 0 (the
                     89: .Dq base
                     90: scheduling priority),
1.1       deraadt    91: anything negative (to make things go very fast).
1.15      jmc        92: .Pp
                     93: The options are as follows:
                     94: .Bl -tag -width Ds
                     95: .It Fl g Ar pgrp
                     96: Alter the scheduling priority of all processes in process group
                     97: .Ar pgrp .
                     98: .It Fl p Ar pid
                     99: Alter the scheduling priority of process
                    100: .Ar pid .
                    101: .It Fl u Ar user
                    102: Alter the scheduling priority of all processes belonging to user
                    103: .Ar user .
                    104: .El
1.1       deraadt   105: .Sh FILES
                    106: .Bl -tag -width /etc/passwd -compact
                    107: .It Pa /etc/passwd
1.9       aaron     108: for mapping user names to user IDs
1.1       deraadt   109: .El
1.15      jmc       110: .Sh EXAMPLES
                    111: The following example
                    112: changes the priority of process IDs 987 and 32,
                    113: and all processes owned by users daemon and root:
                    114: .Bd -literal -offset indent
                    115: # renice +1 987 -u daemon root -p 32
                    116: .Ed
1.1       deraadt   117: .Sh SEE ALSO
1.4       deraadt   118: .Xr nice 1 ,
1.1       deraadt   119: .Xr getpriority 2 ,
                    120: .Xr setpriority 2
1.16    ! jmc       121: .Sh STANDARDS
        !           122: The
        !           123: .Nm
        !           124: utility is compliant with the
        !           125: .St -p1003.1-2004
        !           126: specification,
        !           127: but its presence is optional.
        !           128: .Pp
        !           129: The arguments to flags
        !           130: .Op Fl gpu
        !           131: are extensions to that specification.
1.1       deraadt   132: .Sh HISTORY
                    133: The
                    134: .Nm
                    135: command appeared in
                    136: .Bx 4.0 .
1.12      aaron     137: .Sh BUGS
                    138: Non-superusers cannot increase scheduling priorities of their own processes,
                    139: even if they were the ones that decreased the priorities in the first place.