Unleashed v1.4
[unleashed.git] / share / man / man1 / nice.1
blob4a1c9b26cb2300587ccc9aad158113ab4dd0106a
1 .\"
2 .\" Sun Microsystems, Inc. gratefully acknowledges The Open Group for
3 .\" permission to reproduce portions of its copyrighted documentation.
4 .\" Original documentation from The Open Group can be obtained online at
5 .\" http://www.opengroup.org/bookstore/.
6 .\"
7 .\" The Institute of Electrical and Electronics Engineers and The Open
8 .\" Group, have given us permission to reprint portions of their
9 .\" documentation.
10 .\"
11 .\" In the following statement, the phrase ``this text'' refers to portions
12 .\" of the system documentation.
13 .\"
14 .\" Portions of this text are reprinted and reproduced in electronic form
15 .\" in the SunOS Reference Manual, from IEEE Std 1003.1, 2004 Edition,
16 .\" Standard for Information Technology -- Portable Operating System
17 .\" Interface (POSIX), The Open Group Base Specifications Issue 6,
18 .\" Copyright (C) 2001-2004 by the Institute of Electrical and Electronics
19 .\" Engineers, Inc and The Open Group.  In the event of any discrepancy
20 .\" between these versions and the original IEEE and The Open Group
21 .\" Standard, the original IEEE and The Open Group Standard is the referee
22 .\" document.  The original Standard can be obtained online at
23 .\" http://www.opengroup.org/unix/online.html.
24 .\"
25 .\" This notice shall appear on any product containing this material.
26 .\"
27 .\" The contents of this file are subject to the terms of the
28 .\" Common Development and Distribution License (the "License").
29 .\" You may not use this file except in compliance with the License.
30 .\"
31 .\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
32 .\" or http://www.opensolaris.org/os/licensing.
33 .\" See the License for the specific language governing permissions
34 .\" and limitations under the License.
35 .\"
36 .\" When distributing Covered Code, include this CDDL HEADER in each
37 .\" file and include the License file at usr/src/OPENSOLARIS.LICENSE.
38 .\" If applicable, add the following below this CDDL HEADER, with the
39 .\" fields enclosed by brackets "[]" replaced with your own identifying
40 .\" information: Portions Copyright [yyyy] [name of copyright owner]
41 .\"
42 .\"
43 .\" Copyright 1989 AT&T
44 .\" Portions Copyright (c) 1992, X/Open Company Limited  All Rights Reserved
45 .\" Copyright (c) 2004, Sun Microsystems, Inc.  All Rights Reserved.
46 .\"
47 .TH NICE 1 "Oct 25, 2017"
48 .SH NAME
49 nice \- invoke a command with an altered scheduling priority
50 .SH SYNOPSIS
51 .LP
52 .nf
53 \fB/usr/bin/nice\fR [\fB-\fIincrement\fR\fR | \fB-n\fR \fIincrement\fR] \fIcommand\fR
54      [\fIargument\fR]...
55 .fi
57 .SS "csh Builtin"
58 .LP
59 .nf
60 \fBnice\fR [\fB-\fIincrement\fR\fR | +\fIincrement\fR] [\fIcommand\fR]
61 .fi
63 .SH DESCRIPTION
64 .sp
65 .LP
66 The \fBnice\fR utility invokes \fBcommand\fR, requesting that it be run with a
67 different system scheduling priority. The \fBpriocntl\fR(1) command is a more
68 general interface to scheduler functions.
69 .sp
70 .LP
71 The invoking process (generally the user's shell) must be in a scheduling class
72 that supports \fBnice\fR.
73 .sp
74 .LP
75 If the C shell (see \fBcsh\fR(1)) is used, the full path of the command must be
76 specified. Otherwise, the \fBcsh\fR built-in version of \fBnice\fR will be
77 invoked. See \fBcsh Builtin\fR below.
78 .sp
79 .LP
80 If \fBnice\fR executes commands with arguments, it uses the default shell
81 \fB/usr/bin/sh\fR (see \fBsh\fR(1)).
82 .SS "csh Builtin"
83 .sp
84 .LP
85 \fBnice\fR is also a \fBcsh\fR built-in command with behavior different from
86 the utility versions.  See \fBcsh\fR(1) for description.
87 .SH OPTIONS
88 .sp
89 .LP
90 The following options are supported:
91 .sp
92 .ne 2
93 .na
94 \fB\fB-\fR\fIincrement\fR | \fB-n\fR \fIincrement\fR\fR
95 .ad
96 .RS 29n
97 \fIincrement\fR is a positive or negative decimal integer that has the same
98 effect on the execution of the utility as if the utility had called the
99 \fBnice()\fR function with the numeric value of the \fIincrement\fR
100 option-argument. See \fBnice\fR(2). \fBnice()\fR errors, other than
101 \fBEINVAL\fR, are ignored. If not specified, an increment of \fB10\fR is
102 assumed.
104 The super-user may run commands with priority higher than normal by using a
105 negative increment such as \fB-10\fR\&. A negative \fIincrement\fR assigned by
106 an unprivileged user is ignored.
109 .SH OPERANDS
112 The following operands are supported:
114 .ne 2
116 \fB\fIcommand\fR\fR
118 .RS 12n
119 The name of a command that is to be invoked. If \fIcommand\fR names any of the
120 special built-in utilities (see \fBshell_builtins\fR(1)), the results are
121 undefined.
125 .ne 2
127 \fB\fIargument\fR\fR
129 .RS 12n
130 Any string to be supplied as an argument when invoking \fIcommand\fR.
133 .SH ENVIRONMENT VARIABLES
136 See \fBenviron\fR(5) for descriptions of the following environment variables
137 that affect the execution of \fBnice\fR: \fBLANG\fR, \fBLC_ALL\fR,
138 \fBLC_CTYPE\fR, \fBLC_MESSAGES\fR, \fBPATH\fR, and \fBNLSPATH\fR.
139 .SH EXIT STATUS
142 If \fIcommand\fR is invoked, the exit status of \fBnice\fR will be the exit
143 status of \fIcommand\fR. Otherwise, \fBnice\fR will exit with one of the
144 following values:
146 .ne 2
148 \fB\fB1-125\fR\fR
150 .RS 9n
151 An error occurred.
155 .ne 2
157 \fB\fB126\fR\fR
159 .RS 9n
160 \fIcommand\fR was found but could not be invoked.
164 .ne 2
166 \fB\fB127\fR\fR
168 .RS 9n
169 \fIcommand\fR could not be found.
172 .SH ATTRIBUTES
175 See \fBattributes\fR(5) for descriptions of the following attributes:
176 .SS "/usr/bin/nice"
181 box;
182 c | c
183 l | l .
184 ATTRIBUTE TYPE  ATTRIBUTE VALUE
186 CSI     Enabled
188 Interface Stability     Standard
191 .SH SEE ALSO
194 \fBcsh\fR(1), \fBksh\fR(1), \fBnohup\fR(1), \fBpriocntl\fR(1), \fBsh\fR(1),
195 \fBshell_builtins\fR(1), \fBnice\fR(2), \fBattributes\fR(5), \fBenviron\fR(5),
196 \fBstandards\fR(5)