1 '\" te
   2 .\"  Copyright 1989 AT&T Copyright (c) 2008 Sun Microsystems, Inc. All Rights Reserved.
   3 .\" 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.
   4 .\" 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.
   5 .\" 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]
   6 .TH DISPADMIN 1M "Oct 7, 2008"
   7 .SH NAME
   8 dispadmin \- process scheduler administration
   9 .SH SYNOPSIS
  10 .LP
  11 .nf
  12 \fBdispadmin\fR \fB-l\fR
  13 .fi
  14 
  15 .LP
  16 .nf
  17 \fBdispadmin\fR \fB-c\fR \fIclass\fR {\fB-g\fR [\fB-r\fR \fIres\fR] | \fB-s\fR \fIfile\fR}
  18 .fi
  19 
  20 .LP
  21 .nf
  22 \fBdispadmin\fR \fB-d\fR [\fIclass\fR]
  23 .fi
  24 
  25 .SH DESCRIPTION
  26 .sp
  27 .LP
  28 The \fBdispadmin\fR command displays or changes process scheduler parameters
  29 while the system is running.
  30 .sp
  31 .LP
  32 \fBdispadmin\fR does limited checking on the values supplied in \fIfile\fR to
  33 verify that they are within their required bounds. The checking, however, does
  34 not attempt to analyze the effect that the new values have on the performance
  35 of the system. Inappropriate values can have a negative effect on system
  36 performance. (See \fISystem Administration Guide: Advanced Administration\fR.)
  37 .SH OPTIONS
  38 .sp
  39 .LP
  40 The following options are supported:
  41 .sp
  42 .ne 2
  43 .na
  44 \fB\fB-c\fR \fIclass\fR\fR
  45 .ad
  46 .sp .6
  47 .RS 4n
  48 Specifies the class whose parameters are to be displayed or changed. Valid
  49 \fIclass\fR values are: \fBRT\fR for the real-time class, \fBTS\fR for the
  50 time-sharing class, \fBIA\fR for the inter-active class, \fBFSS\fR for the
  51 fair-share class, and FX for the fixed-priority class. The time-sharing and
  52 inter-active classes share the same scheduler, so changes to the scheduling
  53 parameters of one will change those of the other.
  54 .RE
  55 
  56 .sp
  57 .ne 2
  58 .na
  59 \fB\fB-d\fR [\fIclass\fR]\fR
  60 .ad
  61 .sp .6
  62 .RS 4n
  63 Sets or displays the name of the default scheduling class to be used on reboot
  64 when starting \fBsvc:/system/scheduler:default\fR. If class name is not
  65 specified, the name and description of the current default scheduling class is
  66 displayed. If class name is specified and is a valid scheduling class name,
  67 then it is saved in \fBdispadmin\fR's private configuration file
  68 \fB/etc/dispadmin.conf\fR. Only super-users can set the default scheduling
  69 class.
  70 .RE
  71 
  72 .sp
  73 .ne 2
  74 .na
  75 \fB\fB-g\fR\fR
  76 .ad
  77 .sp .6
  78 .RS 4n
  79 Gets the parameters for the specified class and writes them to the standard
  80 output. Parameters for the real-time class are described in \fBrt_dptbl\fR(4).
  81 Parameters for the time-sharing and inter-active classes are described in
  82 \fBts_dptbl\fR(4). Parameters for the fair-share class are described in
  83 \fBFSS\fR(7). Parameters for the fixed-priority class are described in
  84 \fBfx_dptbl\fR(4).
  85 .sp
  86 The \fB-g\fR and \fB-s\fR options are mutually exclusive: you may not retrieve
  87 the table at the same time you are overwriting it.
  88 .RE
  89 
  90 .sp
  91 .ne 2
  92 .na
  93 \fB\fB-l\fR\fR
  94 .ad
  95 .sp .6
  96 .RS 4n
  97 Lists the scheduler classes currently configured in the system.
  98 .RE
  99 
 100 .sp
 101 .ne 2
 102 .na
 103 \fB\fB-r\fR \fIres\fR\fR
 104 .ad
 105 .sp .6
 106 .RS 4n
 107 When using the \fB-g\fR option you may also use the \fB-r\fR option to specify
 108 a resolution to be used for outputting the time quantum values. If no
 109 resolution is specified, time quantum values are in milliseconds. If \fIres\fR
 110 is specified it must be a positive integer between 1 and 1000000000 inclusive,
 111 and the resolution used is the reciprocal of \fIres\fR in seconds. For example,
 112 a \fIres\fR value of 10 yields time quantum values expressed in tenths of a
 113 second; a \fIres\fR value of 1000000 yields time quantum values expressed in
 114 microseconds. If the time quantum cannot be expressed as an integer in the
 115 specified resolution, it is rounded up to the next integral multiple of the
 116 specified resolution.
 117 .RE
 118 
 119 .sp
 120 .ne 2
 121 .na
 122 \fB\fB-s\fR \fIfile\fR\fR
 123 .ad
 124 .sp .6
 125 .RS 4n
 126 Sets scheduler parameters for the specified class using the values in
 127 \fIfile\fR. These values overwrite the current values in memory\(emthey become
 128 the parameters that control scheduling of processes in the specified class. The
 129 values in \fIfile\fR must be in the format output by the \fB-g\fR option.
 130 Moreover, the values must describe a table that is the same size (has same
 131 number of priority levels) as the table being overwritten. Super-user
 132 privileges are required in order to use the \fB-s\fR option.
 133 .sp
 134 Specify time quantum values for scheduling classes in system clock ticks, and
 135 not in constant-time units. Time quantum values are based on the value of the
 136 kernel's \fBhz\fR variable. If kernel variable \fBhires_tick\fR is set to
 137 \fB1\fR to get higher resolution clock behavior, the actual time quanta will be
 138 reduced by the order of \fB10\fR.
 139 .sp
 140 The \fB-g\fR and \fB-s\fR options are mutually exclusive: you may not retrieve
 141 the table at the same time you are overwriting it.
 142 .RE
 143 
 144 .SH EXAMPLES
 145 .LP
 146 \fBExample 1 \fRRetrieving the Current Scheduler Parameters for the real-time
 147 class
 148 .sp
 149 .LP
 150 The following command retrieves the current scheduler parameters for the
 151 real-time class from kernel memory and writes them to the standard output. Time
 152 quantum values are in microseconds.
 153 
 154 .sp
 155 .in +2
 156 .nf
 157 dispadmin \fB-c\fR RT \fB-g\fR \fB-r\fR 1000000
 158 .fi
 159 .in -2
 160 .sp
 161 
 162 .LP
 163 \fBExample 2 \fROverwriting the Current Scheduler Parameters for the Real-time
 164 Class
 165 .sp
 166 .LP
 167 The following command overwrites the current scheduler parameters for the
 168 real-time class with the values specified in \fBrt.config\fR.
 169 
 170 .sp
 171 .in +2
 172 .nf
 173 dispadmin \fB-c\fR RT \fB-s\fR rt.config
 174 .fi
 175 .in -2
 176 .sp
 177 
 178 .LP
 179 \fBExample 3 \fRRetrieving the Current Scheduler Parameters for the
 180 Time-sharing Class
 181 .sp
 182 .LP
 183 The following command retrieves the current scheduler parameters for the
 184 time-sharing class from kernel memory and writes them to the standard output.
 185 Time quantum values are in nanoseconds.
 186 
 187 .sp
 188 .in +2
 189 .nf
 190 dispadmin \fB-c\fR TS \fB-g\fR \fB-r\fR 1000000000
 191 .fi
 192 .in -2
 193 .sp
 194 
 195 .LP
 196 \fBExample 4 \fROverwriting the Current Scheduler Parameters for the
 197 Time-sharing Class
 198 .sp
 199 .LP
 200 The following command overwrites the current scheduler parameters for the
 201 time-sharing class with the values specified in \fBts.config\fR.
 202 
 203 .sp
 204 .in +2
 205 .nf
 206 dispadmin \fB-c\fR TS \fB-s\fR ts.config
 207 .fi
 208 .in -2
 209 .sp
 210 
 211 .SH FILES
 212 .sp
 213 .ne 2
 214 .na
 215 \fB\fB/etc/dispadmin.conf\fR\fR
 216 .ad
 217 .sp .6
 218 .RS 4n
 219 Possible location for argument to \fB-s\fR option.
 220 .RE
 221 
 222 .SH SEE ALSO
 223 .sp
 224 .LP
 225 \fBpriocntl\fR(1), \fBsvcs\fR(1), \fBsvcadm\fR(1M), \fBpriocntl\fR(2),
 226 \fBfx_dptbl\fR(4), \fBrt_dptbl\fR(4), \fBts_dptbl\fR(4), \fBattributes\fR(5),
 227 \fBsmf\fR(5), \fBFSS\fR(7)
 228 .sp
 229 .LP
 230 \fI\fR \fI\fR
 231 .SH DIAGNOSTICS
 232 .sp
 233 .LP
 234 \fBdispadmin\fR prints an appropriate diagnostic message if it fails to
 235 overwrite the current scheduler parameters due to lack of required permissions
 236 or a problem with the specified input file.
 237 .SH NOTES
 238 .sp
 239 .LP
 240 The default scheduling class setting facility is managed by the service
 241 management facility, \fBsmf\fR(5), under the service identifier:
 242 .sp
 243 .in +2
 244 .nf
 245 svc:/system/scheduler:default
 246 .fi
 247 .in -2
 248 
 249 .sp
 250 .LP
 251 Administrative actions on this service, such as enabling, disabling, or
 252 requesting restart, can be performed using \fBsvcadm\fR(1M). Note that
 253 disabling the service while it is running will not change anything. The
 254 service's status can be queried using the \fBsvcs\fR(1) command.