xref: /csrg-svn/usr.bin/renice/renice.8 (revision 63073)
1*63073Sbostic.\" Copyright (c) 1983, 1991, 1993
2*63073Sbostic.\"	The Regents of the University of California.  All rights reserved.
318911Smckusick.\"
443810Strent.\" %sccs.include.redist.man%
518911Smckusick.\"
6*63073Sbostic.\"     @(#)renice.8	8.1 (Berkeley) 06/09/93
738662Sbostic.\"
847469Scael.Dd
947469Scael.Dt RENICE 8
1047469Scael.Os BSD 4
1147469Scael.Sh NAME
1247469Scael.Nm renice
1347469Scael.Nd alter priority of running processes
1447469Scael.Sh SYNOPSIS
1547469Scael.Nm renice
1647469Scael.Ar priority
1747469Scael.Oo
1847469Scael.Op Fl p
1947469Scael.Ar pid ...
2047469Scael.Oc
2147469Scael.Oo
2247469Scael.Op Fl g
2347469Scael.Ar pgrp ...
2447469Scael.Oc
2547469Scael.Oo
2647469Scael.Op Fl u
2747469Scael.Ar user ...
2847469Scael.Oc
2947469Scael.Sh DESCRIPTION
3047469Scael.Nm Renice
3118912Smckusickalters the
3218912Smckusickscheduling priority of one or more running processes.
3347469ScaelThe following
3447469Scael.Ar who
3518912Smckusickparameters are interpreted as process ID's, process group
3618912SmckusickID's, or user names.
3747469Scael.Nm Renice Ns 'ing
3818912Smckusicka process group causes all processes in the process group
3918912Smckusickto have their scheduling priority altered.
4047469Scael.Nm Renice Ns 'ing
4118912Smckusicka user causes all processes owned by the user to have
4218912Smckusicktheir scheduling priority altered.
4318912SmckusickBy default, the processes to be affected are specified by
4447469Scaeltheir process ID's.
4547469Scael.Pp
4647469ScaelOptions supported by
4747469Scael.Nm renice :
4847469Scael.Bl -tag -width Ds
4947469Scael.It Fl g
5047469ScaelForce
5147469Scael.Ar who
5247469Scaelparameters to be interpreted as process group ID's.
5347469Scael.It Fl u
5447469ScaelForce the
5547469Scael.Ar who
5647469Scaelparameters to be interpreted as user names.
5747469Scael.It Fl p
5847469ScaelResets the
5947469Scael.Ar who
6018912Smckusickinterpretation to be (the default) process ID's.
6147469Scael.El
6247469Scael.Pp
6318912SmckusickFor example,
6447469Scael.Bd -literal -offset
6547469Scaelrenice +1 987 -u daemon root -p 32
6647469Scael.Ed
6747469Scael.Pp
6818912Smckusickwould change the priority of process ID's 987 and 32, and
6918912Smckusickall processes owned by users daemon and root.
7047469Scael.Pp
7118912SmckusickUsers other than the super-user may only alter the priority of
7218912Smckusickprocesses they own,
7318912Smckusickand can only monotonically increase their ``nice value''
7447469Scaelwithin the range 0 to
7547469Scael.Dv PRIO_MAX
7647469Scael(20).
7718912Smckusick(This prevents overriding administrative fiats.)
7818912SmckusickThe super-user
7918912Smckusickmay alter the priority of any process
8047469Scaeland set the priority to any value in the range
8147469Scael.Dv PRIO_MIN
8247469Scael(\-20)
8347469Scaelto
8447469Scael.Dv PRIO_MAX .
8518912SmckusickUseful priorities are:
8628304Skarels20 (the affected processes will run only when nothing else
8718912Smckusickin the system wants to),
8818912Smckusick0 (the ``base'' scheduling priority),
8918912Smckusickanything negative (to make things go very fast).
9047469Scael.Sh FILES
9147469Scael.Bl -tag -width /etc/passwd -compact
9247469Scael.It Pa /etc/passwd
9347469Scaelto map user names to user ID's
9447469Scael.El
9547469Scael.Sh SEE ALSO
9647469Scael.Xr getpriority 2 ,
9747469Scael.Xr setpriority 2
9847469Scael.Sh BUGS
9918912SmckusickNon super-users can not increase scheduling priorities of their own processes,
10018912Smckusickeven if they were the ones that decreased the priorities in the first place.
10147469Scael.Sh HISTORY
10247469ScaelThe
10347469Scael.Nm
10447469Scaelcommand appeared in
10547469Scael.Bx 4.0 .
106