8980 BIOS clock is sometimes one hour fast
[unleashed.git] / usr / src / man / man1m / psradm.1m
blob9f7113757b34cc946df6e0cf9563f575f8b716fe
1 '\" te
2 .\"  Copyright (c) 2008 Sun Microsystems, Inc.
3 .\" All Rights Reserved
4 .\" The contents of this file are subject to the terms of the Common Development and Distribution License (the "License").  You may not use this file except in compliance with the License.
5 .\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing.  See the License for the specific language governing permissions and limitations under the License.
6 .\" When distributing Covered Code, include this CDDL HEADER in each file and include the License file at usr/src/OPENSOLARIS.LICENSE.  If applicable, add the following below this CDDL HEADER, with the fields enclosed by brackets "[]" replaced with your own identifying information: Portions Copyright [yyyy] [name of copyright owner]
7 .TH PSRADM 1M "April 9, 2016"
8 .SH NAME
9 psradm \- change processor operational status
10 .SH SYNOPSIS
11 .LP
12 .nf
13 \fBpsradm\fR \fB-f\fR | \fB-i\fR | \fB-n\fR | \fB-s\fR [\fB-v\fR] [\fB-F\fR] \fIprocessor_id\fR
14 .fi
16 .LP
17 .nf
18 \fBpsradm\fR \fB-a\fR \fB-f\fR | \fB-i\fR | \fB-n\fR | \fB-s\fR [\fB-v\fR] [\fB-F\fR]
19 .fi
21 .SH DESCRIPTION
22 .LP
23 The \fBpsradm\fR utility changes the operational status of processors. The
24 legal states for the processor are \fBon-line\fR, \fBoff-line\fR, \fBspare\fR,
25 \fBfaulted\fR, and \fBno-intr\fR.
26 .sp
27 .LP
28 An \fBon-line\fR processor processes \fBLWPs\fR (lightweight processes) and can
29 be interrupted by I/O devices in the system.
30 .sp
31 .LP
32 An \fBoff-line\fR processor does not process any \fBLWPs.\fR Usually, an
33 \fBoff-line\fR processor is not interruptible by I/O devices in the system. On
34 some processors or under certain conditions, it might not be possible to
35 disable interrupts for an \fBoff-line\fR processor. Thus, the actual effect of
36 being \fBoff-line\fR might vary from machine to machine.
37 .sp
38 .LP
39 A spare processor does not process any LWPs. A spare processor can be brought
40 \fBon-line\fR, \fBoff-line\fR or to \fBno-intr\fR by a privileged user of the
41 system or by the kernel in response to changes in the system state.
42 .sp
43 .LP
44 A faulted processor is identified by the kernel, which monitors the behavior of
45 processors over time. A privileged user can set the state of a faulted
46 processor to be \fBon-line\fR, \fBoff-line\fR, \fBspare\fR or \fBno-intr\fR,
47 but must use the force option to do so.
48 .sp
49 .LP
50 A \fBno-intr\fR processor processes \fBLWPs\fR but is not interruptible by I/O
51 devices.
52 .sp
53 .LP
54 A processor can not be taken \fBoff-line\fR or made \fBspare\fR if there are
55 LWPs that are bound to the processor unless the additional \fB-F\fR option is
56 used. The \fB-F\fR option removes processor bindings of such LWPs before
57 changing the processor's operational status. On some architectures, it might
58 not be possible to take certain processors \fBoff-line\fR or \fBspare\fR if,
59 for example, the system depends on some resource provided by the processor.
60 .sp
61 .LP
62 At least one processor in the system must be able to process \fBLWPs.\fR At
63 least one processor must also be able to be interrupted. Since an
64 \fBoff-line\fR or \fBspare\fR processor can be interruptible, it is possible to
65 have an operational system with one processor \fBno-intr\fR and all other
66 processors \fBoff-line\fR or \fBspare\fR but with one or more accepting
67 interrupts.
68 .sp
69 .LP
70 If any of the specified processors are powered off, \fBpsradm\fR might power on
71 one or more processors.
72 .sp
73 .LP
74 Only users with the \fBPRIV_SYS_RES_CONFIG\fR privilege can use the
75 \fBpsradm\fR utility.
76 .SH OPTIONS
77 .LP
78 The following options are supported:
79 .sp
80 .ne 2
81 .na
82 \fB\fB-a\fR\fR
83 .ad
84 .RS 6n
85 Perform the action on all processors, or as many as possible.
86 .RE
88 .sp
89 .ne 2
90 .na
91 \fB\fB-f\fR\fR
92 .ad
93 .RS 6n
94 Take the specified processors \fBoff-line\fR.
95 .RE
97 .sp
98 .ne 2
99 .na
100 \fB\fB-F\fR\fR
102 .RS 6n
103 Force the transition to the additional specified state. Required if one or more
104 of the specified processors was in the faulted state. Set the specified
105 processors to faulted, if no other transition option was specified. Forced
106 transitions can only be made to \fBfaulted\fR, \fBspare\fR, or \fBoff-line\fR
107 states. Administrators are encouraged to use the \fB-Q\fR option for
108 \fBpbind\fR(1M) to find out which threads will be affected by forced a
109 processor state transition.
113 .ne 2
115 \fB\fB-i\fR\fR
117 .RS 6n
118 Set the specified processors \fBno-intr\fR.
122 .ne 2
124 \fB\fB-n\fR\fR
126 .RS 6n
127 Bring the specified processors \fBon-line\fR.
131 .ne 2
133 \fB\fB-s\fR\fR
135 .RS 6n
136 Make the specified processors spare.
140 .ne 2
142 \fB\fB-v\fR\fR
144 .RS 6n
145 Output a message giving the results of each attempted operation.
148 .SH OPERANDS
150 The following operands are supported:
152 .ne 2
154 \fB\fIprocessor_id\fR\fR
156 .RS 16n
157 The processor \fBID\fR of the processor to be set \fBon-line\fR or
158 \fBoff-line\fR, \fBspare\fR, or \fBno-intr\fR.
160 Specify \fIprocessor_id\fR as an individual processor number (for example,
161 \fB3\fR), multiple processor numbers separated by spaces (for example, \fB1 2
162 3\fR), or a range of processor numbers (for example, \fB1-4\fR). It is also
163 possible to combine ranges and (individual or multiple) \fIprocessor_id\fRs
164 (for example, \fB1-3 5 7-8 9\fR).
167 .SH EXAMPLES
169 \fBExample 1 \fRSetting Processors to \fBoff-line\fR
172 The following example sets processors 2 and 3 \fBoff-line\fR:
175 .in +2
177 % psradm \fB-f\fR 2 3
179 .in -2
183 \fBExample 2 \fRSetting Processors to no-intr
186 The following example sets processors 1 and 2 \fBno-intr\fR:
189 .in +2
191 % psradm \fB-i\fR 1 2
193 .in -2
197 \fBExample 3 \fRSetting Processors to \fBspare\fR
200 The following example sets processors 1 and 2 spare, even if either of the
201 processors was in the faulted state:
204 .in +2
206 % psradm -F -s 1 2
208 .in -2
212 \fBExample 4 \fRSetting All Processors \fBon-line\fR
214 .in +2
216 % psradm \fB-a\fR \fB-n\fR
218 .in -2
222 \fBExample 5 \fRForcing Processors to \fBoff-line\fR
225 The following example sets processors 1 and 2 offline, and revokes the
226 processor bindings from the processes bound to them:
229 .in +2
231 % psradm \fB-F\fR \fB-f\fR 1 2
233 .in -2
236 .SH EXIT STATUS
238 The following exit values are returned:
240 .ne 2
242 \fB\fB0\fR\fR
244 .RS 6n
245 Successful completion.
249 .ne 2
251 \fB\fB>0\fR\fR
253 .RS 6n
254 An error occurred.
257 .SH FILES
258 .ne 2
260 \fB\fB/etc/wtmpx\fR\fR
262 .RS 14n
263 Records logging processor status changes
266 .SH SEE ALSO
268 \fBpbind\fR(1M), \fBpsrinfo\fR(1M), \fBpsrset\fR(1M), \fBp_online\fR(2),
269 \fBprocessor_bind\fR(2), \fBattributes\fR(5)
270 .SH DIAGNOSTICS
271 .ne 2
273 \fB\fBpsradm: processor 4: Invalid argument\fR\fR
275 .sp .6
276 .RS 4n
277 The specified processor does not exist in the configuration.
281 .ne 2
283 \fB\fBpsradm: processor 3: Device busy\fR\fR
285 .sp .6
286 .RS 4n
287 The specified processor could not be taken \fBoff-line\fR because it either has
288 LWPs bound to it, is the last \fBon-line\fR processor in the system, or is
289 needed by the system because it provides some essential service.
293 .ne 2
295 \fB\fBpsradm: processor 3: Device busy\fR\fR
297 .sp .6
298 .RS 4n
299 The specified processor could not be set \fBno-intr\fR because it is the last
300 interruptible processor in the system, or it is the only processor in the
301 system that can service interrupts needed by the system.
305 .ne 2
307 \fB\fBpsradm: processor 3: Device busy\fR\fR
309 .sp .6
310 .RS 4n
311 The specified processor is powered off, and it cannot be powered on because
312 some platform-specific resource is unavailable.
316 .ne 2
318 \fB\fBpsradm: processor 0: Not owner\fR\fR
320 .sp .6
321 .RS 4n
322 The user does not have permission to change processor status.
326 .ne 2
328 \fB\fBpsradm: processor 2: Operation not supported\fR\fR
330 .sp .6
331 .RS 4n
332 The specified processor is powered off, and the platform does not support power
333 on of individual processors.