| 1 | .\" Copyright (c) 1980, 1991 Regents of the University of California. |
| 2 | .\" All rights reserved. |
| 3 | .\" |
| 4 | .\" %sccs.include.redist.man% |
| 5 | .\" |
| 6 | .\" @(#)nice.3 6.2 (Berkeley) %G% |
| 7 | .\" |
| 8 | .Dd |
| 9 | .Dt NICE 3 |
| 10 | .Os BSD 4 |
| 11 | .Sh NAME |
| 12 | .Nm nice |
| 13 | .Nd set program scheduling priority |
| 14 | .Sh SYNOPSIS |
| 15 | .Fn nice "int incr" |
| 16 | .Sh DESCRIPTION |
| 17 | .Bf -symbolic |
| 18 | This interface is obsoleted by setpriority(2). |
| 19 | .Ef |
| 20 | .Pp |
| 21 | The |
| 22 | .Fn nice |
| 23 | function obtains the scheduling priority of the process |
| 24 | from the system and sets it to the priority value specified in |
| 25 | .Fa incr . |
| 26 | The priority is a value in the range -20 to 20. |
| 27 | The default priority is 0; lower priorities cause more favorable scheduling. |
| 28 | Only the super-user may lower priorities. |
| 29 | .Pp |
| 30 | Children inherit the priority of their parent processes via |
| 31 | .Xr fork 2 . |
| 32 | .Sh SEE ALSO |
| 33 | .Xr nice 1 , |
| 34 | .Xr setpriority 2 , |
| 35 | .Xr fork 2 , |
| 36 | .Xr renice 8 |
| 37 | .Sh HISTORY |
| 38 | A |
| 39 | .Fn nice |
| 40 | syscall appeared in |
| 41 | .At v6 . |