=================================================================== RCS file: /cvsrepo/anoncvs/cvs/src/usr.bin/renice/renice.8,v retrieving revision 1.14 retrieving revision 1.15 diff -u -r1.14 -r1.15 --- src/usr.bin/renice/renice.8 2003/06/03 02:56:15 1.14 +++ src/usr.bin/renice/renice.8 2007/03/16 16:36:06 1.15 @@ -1,4 +1,4 @@ -.\" $OpenBSD: renice.8,v 1.14 2003/06/03 02:56:15 millert Exp $ +.\" $OpenBSD: renice.8,v 1.15 2007/03/16 16:36:06 jmc Exp $ .\" .\" Copyright (c) 1983, 1991, 1993 .\" The Regents of the University of California. All rights reserved. @@ -39,59 +39,33 @@ .Nm renice .Ar priority .Oo -.Op Fl p -.Ar pid ... -.Oc -.Oo .Op Fl g .Ar pgrp ... .Oc .Oo +.Op Fl p +.Ar pid ... +.Oc +.Oo .Op Fl u .Ar user ... .Oc .Sh DESCRIPTION .Nm alters the scheduling -.Ar priority -(an integer) of one or more running processes. -The following -.Ar who -parameters (pid, pgrp and user) are interpreted as process IDs, process group -IDs, or user names. -.Nm renice Ns ing -a process group causes all processes in the process group -to have their scheduling priority altered. -.Nm renice Ns ing -a user causes all processes owned by the user to have -their scheduling priority altered. -By default, the processes to be affected are specified by -their process IDs. +.Em priority +of one or more running processes. +Processes may be selected using the parameters +.Ar pid +(process ID), +.Ar pgrp +(process group ID), +and +.Ar user +(user name). +If no flag is specified, +the default is to select by process ID. .Pp -The options are as follows: -.Bl -tag -width Ds -.It Fl g -Force -.Ar who -parameters to be interpreted as process group IDs. -.It Fl u -Force the -.Ar who -parameters to be interpreted as user names. -.It Fl p -Resets the -.Ar who -interpretation to be (the default) process IDs. -.El -.Pp -For example, -.Bd -literal -offset -# renice +1 987 -u daemon root -p 32 -.Ed -.Pp -would change the priority of process IDs 987 and 32, and -all processes owned by users daemon and root. -.Pp Users other than the superuser may only alter the priority of processes they own, and can only monotonically increase their @@ -107,6 +81,7 @@ (\-20) to .Dv PRIO_MAX . +.Pp Useful priorities are: 20 (the affected processes will run only when nothing else in the system wants to), @@ -114,11 +89,31 @@ .Dq base scheduling priority), anything negative (to make things go very fast). +.Pp +The options are as follows: +.Bl -tag -width Ds +.It Fl g Ar pgrp +Alter the scheduling priority of all processes in process group +.Ar pgrp . +.It Fl p Ar pid +Alter the scheduling priority of process +.Ar pid . +.It Fl u Ar user +Alter the scheduling priority of all processes belonging to user +.Ar user . +.El .Sh FILES .Bl -tag -width /etc/passwd -compact .It Pa /etc/passwd for mapping user names to user IDs .El +.Sh EXAMPLES +The following example +changes the priority of process IDs 987 and 32, +and all processes owned by users daemon and root: +.Bd -literal -offset indent +# renice +1 987 -u daemon root -p 32 +.Ed .Sh SEE ALSO .Xr nice 1 , .Xr getpriority 2 ,