Print this page
6591 resource_controls(5) should talk about project.cpu-cap not project.cpu-caps
Split |
Close |
Expand all |
Collapse all |
--- old/usr/src/man/man5/resource_controls.5
+++ new/usr/src/man/man5/resource_controls.5
1 1 '\" te
2 2 .\" Copyright (c) 2007, Sun Microsystems, Inc. All Rights Reserved.
3 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 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 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 6 .TH RESOURCE_CONTROLS 5 "Jul 19, 2013"
7 7 .SH NAME
8 8 resource_controls \- resource controls available through project database
9 9 .SH DESCRIPTION
10 -.sp
11 10 .LP
12 11 The resource controls facility is configured through the project database. See
13 12 \fBproject\fR(4). You can set and modify resource controls through the
14 13 following utilities:
15 14 .RS +4
16 15 .TP
17 16 .ie t \(bu
18 17 .el o
19 18 \fBprctl\fR(1)
20 19 .RE
21 20 .RS +4
22 21 .TP
23 22 .ie t \(bu
24 23 .el o
25 24 \fBprojadd\fR(1M)
26 25 .RE
27 26 .RS +4
28 27 .TP
29 28 .ie t \(bu
30 29 .el o
31 30 \fBprojmod\fR(1M)
32 31 .RE
33 32 .RS +4
34 33 .TP
35 34 .ie t \(bu
36 35 .el o
37 36 \fBrctladm\fR(1M)
38 37 .RE
39 38 .sp
40 39 .LP
41 40 In a program, you use \fBsetrctl\fR(2) to set resource control values.
42 41 .sp
43 42 .LP
44 43 In addition to the preceding resource controls, there are resource pools,
45 44 accessible through the \fBpooladm\fR(1M) and \fBpoolcfg\fR(1M) utilities. In a
46 45 program, resource pools can be manipulated through the \fBlibpool\fR(3LIB)
47 46 library.
48 47 .sp
49 48 .LP
50 49 The following are the resource controls are available:
51 50 .sp
52 51 .ne 2
53 52 .na
54 53 \fB\fBprocess.max-address-space\fR\fR
55 54 .ad
56 55 .sp .6
57 56 .RS 4n
58 57 Maximum amount of address space, as summed over segment sizes, that is
59 58 available to this process, expressed as a number of bytes.
60 59 .RE
61 60
62 61 .sp
63 62 .ne 2
64 63 .na
65 64 \fB\fBprocess.max-core-size\fR\fR
66 65 .ad
67 66 .sp .6
68 67 .RS 4n
69 68 Maximum size of a core file created by this process, expressed as a number of
70 69 bytes.
71 70 .RE
72 71
73 72 .sp
74 73 .ne 2
75 74 .na
76 75 \fB\fBprocess.max-cpu-time\fR\fR
77 76 .ad
78 77 .sp .6
79 78 .RS 4n
80 79 Maximum CPU time that is available to this process, expressed as a number of
81 80 seconds.
82 81 .RE
83 82
84 83 .sp
85 84 .ne 2
86 85 .na
87 86 \fB\fBprocess.max-data-size\fR\fR
88 87 .ad
89 88 .sp .6
90 89 .RS 4n
91 90 Maximum heap memory available to this process, expressed as a number of bytes.
92 91 .RE
93 92
94 93 .sp
95 94 .ne 2
96 95 .na
97 96 \fB\fBprocess.max-file-descriptor\fR\fR
98 97 .ad
99 98 .sp .6
100 99 .RS 4n
101 100 Maximum file descriptor index available to this process, expressed as an
102 101 integer.
103 102 .RE
104 103
105 104 .sp
106 105 .ne 2
107 106 .na
108 107 \fB\fBprocess.max-file-size\fR\fR
109 108 .ad
110 109 .sp .6
111 110 .RS 4n
112 111 Maximum file offset available for writing by this process, expressed as a
113 112 number of bytes.
114 113 .RE
115 114
116 115 .sp
117 116 .ne 2
118 117 .na
119 118 \fB\fBprocess.max-msg-messages\fR\fR
120 119 .ad
121 120 .sp .6
122 121 .RS 4n
123 122 Maximum number of messages on a message queue (value copied from the resource
124 123 control at \fBmsgget()\fR time), expressed as an integer.
125 124 .RE
126 125
127 126 .sp
128 127 .ne 2
129 128 .na
130 129 \fB\fBprocess.max-msg-qbytes\fR\fR
131 130 .ad
132 131 .sp .6
133 132 .RS 4n
134 133 Maximum number of bytes of messages on a message queue (value copied from the
135 134 resource control at \fBmsgget()\fR time), expressed as a number of bytes.
136 135 .RE
137 136
138 137 .sp
139 138 .ne 2
140 139 .na
141 140 \fB\fBprocess.max-port-events\fR\fR
142 141 .ad
143 142 .sp .6
144 143 .RS 4n
145 144 Maximum allowable number of events per event port, expressed as an integer.
146 145 .RE
147 146
148 147 .sp
149 148 .ne 2
150 149 .na
151 150 \fB\fBprocess.max-sem-nsems\fR\fR
152 151 .ad
153 152 .sp .6
154 153 .RS 4n
155 154 Maximum number of semaphores allowed per semaphore set, expressed as an
156 155 integer.
157 156 .RE
158 157
159 158 .sp
160 159 .ne 2
161 160 .na
162 161 \fB\fBprocess.max-sem-ops\fR\fR
163 162 .ad
164 163 .sp .6
165 164 .RS 4n
166 165 Maximum number of semaphore operations allowed per \fBsemop\fR call (value
167 166 copied from the resource control at \fBsemget()\fR time). Expressed as an
168 167 integer, specifying the number of operations.
169 168 .RE
170 169
171 170 .sp
172 171 .ne 2
173 172 .na
174 173 \fB\fBprocess.max-sigqueue-size\fR\fR
175 174 .ad
176 175 .sp .6
177 176 .RS 4n
178 177 Maximum number of outstanding queued signals.
179 178 .RE
180 179
181 180 .sp
182 181 .ne 2
183 182 .na
184 183 \fB\fBprocess.max-stack-size\fR\fR
↓ open down ↓ |
164 lines elided |
↑ open up ↑ |
185 184 .ad
186 185 .sp .6
187 186 .RS 4n
188 187 Maximum stack memory segment available to this process, expressed as a number
189 188 of bytes.
190 189 .RE
191 190
192 191 .sp
193 192 .ne 2
194 193 .na
195 -\fB\fBproject.cpu-caps\fR\fR
194 +\fB\fBproject.cpu-cap\fR\fR
196 195 .ad
197 196 .sp .6
198 197 .RS 4n
199 198 Maximum amount of CPU resources that a project can use. The unit used is the
200 199 percentage of a single CPU that can be used by all user threads in a project.
201 200 Expressed as an integer. The cap does not apply to threads running in real-time
202 201 scheduling class. This resource control does not support the \fBsyslog\fR
203 202 action.
204 203 .RE
205 204
206 205 .sp
207 206 .ne 2
208 207 .na
209 208 \fB\fBproject.cpu-shares\fR\fR
210 209 .ad
211 210 .sp .6
212 211 .RS 4n
213 212 Number of CPU shares granted to a project for use with the fair share scheduler
214 213 (see \fBFSS\fR(7)). The unit used is the number of shares (an integer). This
215 214 resource control does not support the \fBsyslog\fR action.
216 215 .RE
217 216
218 217 .sp
219 218 .ne 2
220 219 .na
221 220 \fB\fBproject.max-contracts\fR\fR
222 221 .ad
223 222 .sp .6
224 223 .RS 4n
225 224 Maximum number of contracts allowed in a project, expressed as an integer.
226 225 .RE
227 226
228 227 .sp
229 228 .ne 2
230 229 .na
231 230 \fB\fBproject.max-crypto-memory\fR\fR
232 231 .ad
233 232 .sp .6
234 233 .RS 4n
235 234 Maximum amount of kernel memory that can be used for crypto operations.
236 235 Allocations in the kernel for buffers and session-related structures are
237 236 charged against this resource control.
238 237 .RE
239 238
240 239 .sp
241 240 .ne 2
242 241 .na
243 242 \fB\fBproject.max-locked-memory\fR\fR
244 243 .ad
245 244 .sp .6
246 245 .RS 4n
247 246 Total amount of physical memory locked by device drivers and user processes
248 247 (including D/ISM), expressed as a number of bytes.
249 248 .RE
250 249
251 250 .sp
252 251 .ne 2
253 252 .na
254 253 \fB\fBproject.max-lwps\fR\fR
255 254 .ad
256 255 .sp .6
257 256 .RS 4n
258 257 Maximum number of LWPs simultaneously available to a project, expressed as an
259 258 integer.
260 259 .RE
261 260
262 261 .sp
263 262 .ne 2
264 263 .na
265 264 \fB\fBproject.max-msg-ids\fR\fR
266 265 .ad
267 266 .sp .6
268 267 .RS 4n
269 268 Maximum number of message queue IDs allowed for a project, expressed as an
270 269 integer.
271 270 .RE
272 271
273 272 .sp
274 273 .ne 2
275 274 .na
276 275 \fB\fBproject.max-port-ids\fR\fR
277 276 .ad
278 277 .sp .6
279 278 .RS 4n
280 279 Maximum allowable number of event ports, expressed as an integer.
281 280 .RE
282 281
283 282 .sp
284 283 .ne 2
285 284 .na
286 285 \fB\fBproject.max-sem-ids\fR\fR
287 286 .ad
288 287 .sp .6
289 288 .RS 4n
290 289 Maximum number of semaphore IDs allowed for a project, expressed as an integer.
291 290 .RE
292 291
293 292 .sp
294 293 .ne 2
295 294 .na
296 295 \fB\fBproject.max-shm-ids\fR\fR
297 296 .ad
298 297 .sp .6
299 298 .RS 4n
300 299 Maximum number of shared memory IDs allowed for a project, expressed as an
301 300 integer.
302 301 .RE
303 302
304 303 .sp
305 304 .ne 2
306 305 .na
307 306 \fB\fBproject.max-shm-memory\fR\fR
308 307 .ad
309 308 .sp .6
310 309 .RS 4n
311 310 Total amount of shared memory allowed for a project, expressed as a number of
312 311 bytes.
313 312 .RE
314 313
315 314 .sp
316 315 .ne 2
317 316 .na
318 317 \fB\fBproject.max-tasks\fR\fR
319 318 .ad
320 319 .sp .6
321 320 .RS 4n
322 321 Maximum number of tasks allowable in a project, expressed as an integer.
323 322 .RE
324 323
325 324 .sp
326 325 .ne 2
327 326 .na
328 327 \fB\fBproject.pool\fR\fR
329 328 .ad
330 329 .sp .6
331 330 .RS 4n
332 331 Binds a specified resource pool with a project.
333 332 .RE
334 333
335 334 .sp
336 335 .ne 2
337 336 .na
338 337 \fB\fBrcap.max-rss\fR\fR
339 338 .ad
340 339 .sp .6
341 340 .RS 4n
342 341 The total amount of physical memory, in bytes, that is available to processes
343 342 in a project.
344 343 .RE
345 344
346 345 .sp
347 346 .ne 2
348 347 .na
349 348 \fB\fBtask.max-cpu-time\fR\fR
350 349 .ad
351 350 .sp .6
352 351 .RS 4n
353 352 Maximum CPU time that is available to this task's processes, expressed as a
354 353 number of seconds.
355 354 .RE
356 355
357 356 .sp
358 357 .ne 2
359 358 .na
360 359 \fB\fBtask.max-lwps\fR\fR
361 360 .ad
362 361 .sp .6
363 362 .RS 4n
364 363 Maximum number of LWPs simultaneously available to this task's processes,
365 364 expressed as an integer.
366 365 .RE
367 366
368 367 .sp
369 368 .LP
370 369 The following zone-wide resource controls are available:
371 370 .sp
372 371 .ne 2
373 372 .na
374 373 \fB\fBzone.cpu-cap\fR\fR
375 374 .ad
376 375 .sp .6
377 376 .RS 4n
378 377 Sets a limit on the amount of CPU time that can be used by a zone. The unit
379 378 used is the percentage of a single CPU that can be used by all user threads in
380 379 a zone. Expressed as an integer. When projects within the capped zone have
381 380 their own caps, the minimum value takes precedence. This resource control does
382 381 not support the \fBsyslog\fR action.
383 382 .RE
384 383
385 384 .sp
386 385 .ne 2
387 386 .na
388 387 \fB\fBzone.cpu-shares\fR\fR
389 388 .ad
390 389 .sp .6
391 390 .RS 4n
392 391 Sets a limit on the number of fair share scheduler (FSS) CPU shares for a zone.
393 392 CPU shares are first allocated to the zone, and then further subdivided among
394 393 projects within the zone as specified in the \fBproject.cpu-shares\fR entries.
395 394 Expressed as an integer. This resource control does not support the
396 395 \fBsyslog\fR action.
397 396 .RE
398 397
399 398 .sp
400 399 .ne 2
401 400 .na
402 401 \fB\fBzone.max-locked-memory\fR\fR
403 402 .ad
404 403 .sp .6
405 404 .RS 4n
406 405 Total amount of physical locked memory available to a zone.
407 406 .RE
408 407
409 408 .sp
410 409 .ne 2
411 410 .na
412 411 \fB\fBzone.max-lwps\fR\fR
413 412 .ad
414 413 .sp .6
415 414 .RS 4n
416 415 Enhances resource isolation by preventing too many LWPs in one zone from
417 416 affecting other zones. A zone's total LWPs can be further subdivided among
418 417 projects within the zone within the zone by using \fBproject.max-lwps\fR
419 418 entries. Expressed as an integer.
420 419 .RE
421 420
422 421 .sp
423 422 .ne 2
424 423 .na
425 424 \fB\fBzone.max-msg-ids\fR\fR
426 425 .ad
427 426 .sp .6
428 427 .RS 4n
429 428 Maximum number of message queue IDs allowed for a zone, expressed as an
430 429 integer.
431 430 .RE
432 431
433 432 .sp
434 433 .ne 2
435 434 .na
436 435 \fB\fBzone.max-sem-ids\fR\fR
437 436 .ad
438 437 .sp .6
439 438 .RS 4n
440 439 Maximum number of semaphore IDs allowed for a zone, expressed as an integer.
441 440 .RE
442 441
443 442 .sp
444 443 .ne 2
445 444 .na
446 445 \fB\fBzone.max-shm-ids\fR\fR
447 446 .ad
448 447 .sp .6
449 448 .RS 4n
450 449 Maximum number of shared memory IDs allowed for a zone, expressed as an
451 450 integer.
452 451 .RE
453 452
454 453 .sp
455 454 .ne 2
456 455 .na
457 456 \fB\fBzone.max-shm-memory\fR\fR
458 457 .ad
459 458 .sp .6
460 459 .RS 4n
461 460 Total amount of shared memory allowed for a zone, expressed as a number of
462 461 bytes.
463 462 .RE
464 463
465 464 .sp
466 465 .ne 2
467 466 .na
468 467 \fB\fBzone.max-swap\fR\fR
469 468 .ad
↓ open down ↓ |
264 lines elided |
↑ open up ↑ |
470 469 .sp .6
471 470 .RS 4n
472 471 Total amount of swap that can be consumed by user process address space
473 472 mappings and \fBtmpfs\fR mounts for this zone.
474 473 .RE
475 474
476 475 .sp
477 476 .LP
478 477 See \fBzones\fR(5).
479 478 .SS "Units Used in Resource Controls"
480 -.sp
481 479 .LP
482 480 Resource controls can be expressed as in units of size (bytes), time (seconds),
483 481 or as a count (integer). These units use the strings specified below.
484 482 .sp
485 483 .in +2
486 484 .nf
487 485 Category Res Ctrl Modifier Scale
488 486 Type String
489 487 ----------- ----------- -------- -----
490 488 Size bytes B 1
491 489 KB 2^10
492 490 MB 2^20
493 491 GB 2^30
494 492 TB 2^40
495 493 PB 2^50
496 494 EB 2^60
497 495
498 496 Time seconds s 1
499 497 Ks 10^3
500 498 Ms 10^6
501 499 Gs 10^9
502 500 Ts 10^12
503 501 Ps 10^15
504 502 Es 10^18
505 503
506 504 Count integer none 1
507 505 K 10^3
508 506 M 10^6
509 507 G 10^9
510 508 T 10^12
511 509 P 10^15
512 510 Es 10^18
513 511 .fi
514 512 .in -2
515 513
516 514 .sp
517 515 .LP
518 516 Scaled values can be used with resource controls. The following example shows a
519 517 scaled threshold value:
520 518 .sp
521 519 .in +2
522 520 .nf
523 521 task.max-lwps=(priv,1K,deny)
524 522 .fi
525 523 .in -2
526 524
527 525 .sp
528 526 .LP
529 527 In the \fBproject\fR file, the value \fB1K\fR is expanded to \fB1000\fR:
530 528 .sp
531 529 .in +2
532 530 .nf
533 531 task.max-lwps=(priv,1000,deny)
534 532 .fi
535 533 .in -2
536 534
537 535 .sp
538 536 .LP
539 537 A second example uses a larger scaled value:
540 538 .sp
541 539 .in +2
542 540 .nf
543 541 process.max-file-size=(priv,5G,deny)
544 542 .fi
545 543 .in -2
546 544
547 545 .sp
548 546 .LP
549 547 In the \fBproject\fR file, the value \fB5G\fR is expanded to \fB5368709120\fR:
550 548 .sp
551 549 .in +2
552 550 .nf
553 551 process.max-file-size=(priv,5368709120,deny)
554 552 .fi
555 553 .in -2
↓ open down ↓ |
65 lines elided |
↑ open up ↑ |
556 554
557 555 .sp
558 556 .LP
559 557 The preceding examples use the scaling factors specified in the table above.
560 558 .sp
561 559 .LP
562 560 Note that unit modifiers (for example, \fB5G\fR) are accepted by the
563 561 \fBprctl\fR(1), \fBprojadd\fR(1M), and \fBprojmod\fR(1M) commands. You cannot
564 562 use unit modifiers in the project database itself.
565 563 .SS "Resource Control Values and Privilege Levels"
566 -.sp
567 564 .LP
568 565 A threshold value on a resource control constitutes a point at which local
569 566 actions can be triggered or global actions, such as logging, can occur.
570 567 .sp
571 568 .LP
572 569 Each threshold value on a resource control must be associated with a privilege
573 570 level. The privilege level must be one of the following three types:
574 571 .sp
575 572 .ne 2
576 573 .na
577 574 \fB\fBbasic\fR\fR
578 575 .ad
579 576 .sp .6
580 577 .RS 4n
581 578 Can be modified by the owner of the calling process.
582 579 .RE
583 580
584 581 .sp
585 582 .ne 2
586 583 .na
587 584 \fB\fBprivileged\fR\fR
588 585 .ad
589 586 .sp .6
590 587 .RS 4n
591 588 Can be modified by the current process (requiring \fBsys_resource\fR privilege)
592 589 or by \fBprctl\fR(1) (requiring \fBproc_owner\fR privilege).
593 590 .RE
594 591
595 592 .sp
596 593 .ne 2
597 594 .na
598 595 \fB\fBsystem\fR\fR
599 596 .ad
600 597 .sp .6
601 598 .RS 4n
602 599 Fixed for the duration of the operating system instance.
603 600 .RE
604 601
605 602 .sp
606 603 .LP
607 604 A resource control is guaranteed to have one \fBsystem\fR value, which is
608 605 defined by the system, or resource provider. The \fBsystem\fR value represents
609 606 how much of the resource the current implementation of the operating system is
610 607 capable of providing.
611 608 .sp
612 609 .LP
613 610 Any number of privileged values can be defined, and only one basic value is
614 611 allowed. Operations that are performed without specifying a privilege value are
615 612 assigned a basic privilege by default.
616 613 .sp
617 614 .LP
618 615 The privilege level for a resource control value is defined in the privilege
619 616 field of the resource control block as \fBRCTL_BASIC\fR, \fBRCTL_PRIVILEGED\fR,
620 617 or \fBRCTL_SYSTEM\fR. See \fBsetrctl\fR(2) for more information. You can use
621 618 the \fBprctl\fR command to modify values that are associated with basic and
622 619 privileged levels.
623 620 .sp
624 621 .LP
↓ open down ↓ |
48 lines elided |
↑ open up ↑ |
625 622 In specifying the privilege level of \fBprivileged\fR, you can use the
626 623 abbreviation \fBpriv\fR. For example:
627 624 .sp
628 625 .in +2
629 626 .nf
630 627 task.max-lwps=(priv,1K,deny)
631 628 .fi
632 629 .in -2
633 630
634 631 .SS "Global and Local Actions on Resource Control Values"
635 -.sp
636 632 .LP
637 633 There are two categories of actions on resource control values: global and
638 634 local.
639 635 .sp
640 636 .LP
641 637 Global actions apply to resource control values for every resource control on
642 638 the system. You can use \fBrctladm\fR(1M) to perform the following actions:
643 639 .RS +4
644 640 .TP
645 641 .ie t \(bu
646 642 .el o
647 643 Display the global state of active system resource controls.
648 644 .RE
649 645 .RS +4
650 646 .TP
651 647 .ie t \(bu
652 648 .el o
653 649 Set global logging actions.
654 650 .RE
655 651 .sp
656 652 .LP
657 653 You can disable or enable the global logging action on resource controls. You
658 654 can set the \fBsyslog\fR action to a specific degree by assigning a severity
659 655 level, \fBsyslog=\fR\fIlevel\fR. The possible settings for \fIlevel\fR are as
660 656 follows:
661 657 .RS +4
662 658 .TP
663 659 .ie t \(bu
664 660 .el o
665 661 \fBdebug\fR
666 662 .RE
667 663 .RS +4
668 664 .TP
669 665 .ie t \(bu
670 666 .el o
671 667 \fBinfo\fR
672 668 .RE
673 669 .RS +4
674 670 .TP
675 671 .ie t \(bu
676 672 .el o
677 673 \fBnotice\fR
678 674 .RE
679 675 .RS +4
680 676 .TP
681 677 .ie t \(bu
682 678 .el o
683 679 \fBwarning\fR
684 680 .RE
685 681 .RS +4
686 682 .TP
687 683 .ie t \(bu
688 684 .el o
689 685 \fBerr\fR
690 686 .RE
691 687 .RS +4
692 688 .TP
693 689 .ie t \(bu
694 690 .el o
695 691 \fBcrit\fR
696 692 .RE
697 693 .RS +4
698 694 .TP
699 695 .ie t \(bu
700 696 .el o
701 697 \fBalert\fR
702 698 .RE
703 699 .RS +4
704 700 .TP
705 701 .ie t \(bu
706 702 .el o
707 703 \fBemerg\fR
708 704 .RE
709 705 .sp
710 706 .LP
711 707 By default, there is no global logging of resource control violations.
712 708 .sp
713 709 .LP
714 710 Local actions are taken on a process that attempts to exceed the control value.
715 711 For each threshold value that is placed on a resource control, you can
716 712 associate one or more actions. There are three types of local actions:
717 713 \fBnone\fR, \fBdeny\fR, and \fBsignal=\fR. These three actions are used as
718 714 follows:
719 715 .sp
720 716 .ne 2
721 717 .na
722 718 \fB\fBnone\fR\fR
723 719 .ad
724 720 .sp .6
725 721 .RS 4n
726 722 No action is taken on resource requests for an amount that is greater than the
727 723 threshold. This action is useful for monitoring resource usage without
728 724 affecting the progress of applications. You can also enable a global message
729 725 that displays when the resource control is exceeded, while, at the same time,
730 726 the process exceeding the threshhold is not affected.
731 727 .RE
732 728
733 729 .sp
734 730 .ne 2
735 731 .na
736 732 \fB\fBdeny\fR\fR
737 733 .ad
738 734 .sp .6
739 735 .RS 4n
740 736 You can deny resource requests for an amount that is greater than the
741 737 threshold. For example, a \fBtask.max-lwps\fR resource control with action deny
742 738 causes a \fBfork()\fR system call to fail if the new process would exceed the
743 739 control value. See the \fBfork\fR(2).
744 740 .RE
745 741
746 742 .sp
747 743 .ne 2
748 744 .na
749 745 \fB\fBsignal=\fR\fR
750 746 .ad
751 747 .sp .6
752 748 .RS 4n
753 749 You can enable a global signal message action when the resource control is
754 750 exceeded. A signal is sent to the process when the threshold value is exceeded.
755 751 Additional signals are not sent if the process consumes additional resources.
756 752 Available signals are listed below.
757 753 .RE
758 754
759 755 .sp
760 756 .LP
761 757 Not all of the actions can be applied to every resource control. For example, a
762 758 process cannot exceed the number of CPU shares assigned to the project of which
763 759 it is a member. Therefore, a deny action is not allowed on the
764 760 \fBproject.cpu-shares\fR resource control.
765 761 .sp
766 762 .LP
767 763 Due to implementation restrictions, the global properties of each control can
768 764 restrict the range of available actions that can be set on the threshold value.
769 765 (See \fBrctladm\fR(1M).) A list of available signal actions is presented in the
770 766 following list. For additional information about signals, see
771 767 \fBsignal\fR(3HEAD).
772 768 .sp
773 769 .LP
774 770 The following are the signals available to resource control values:
775 771 .sp
776 772 .ne 2
777 773 .na
778 774 \fB\fBSIGABRT\fR\fR
779 775 .ad
780 776 .sp .6
781 777 .RS 4n
782 778 Terminate the process.
783 779 .RE
784 780
785 781 .sp
786 782 .ne 2
787 783 .na
788 784 \fB\fBSIGHUP\fR\fR
789 785 .ad
790 786 .sp .6
791 787 .RS 4n
792 788 Send a hangup signal. Occurs when carrier drops on an open line. Signal sent to
793 789 the process group that controls the terminal.
794 790 .RE
795 791
796 792 .sp
797 793 .ne 2
798 794 .na
799 795 \fB\fBSIGTERM\fR\fR
800 796 .ad
801 797 .sp .6
802 798 .RS 4n
803 799 Terminate the process. Termination signal sent by software.
804 800 .RE
805 801
806 802 .sp
807 803 .ne 2
808 804 .na
809 805 \fB\fBSIGKILL\fR\fR
810 806 .ad
811 807 .sp .6
812 808 .RS 4n
813 809 Terminate the process and kill the program.
814 810 .RE
815 811
816 812 .sp
817 813 .ne 2
818 814 .na
819 815 \fB\fBSIGSTOP\fR\fR
820 816 .ad
821 817 .sp .6
822 818 .RS 4n
823 819 Stop the process. Job control signal.
824 820 .RE
825 821
826 822 .sp
827 823 .ne 2
828 824 .na
829 825 \fB\fBSIGXRES\fR\fR
830 826 .ad
831 827 .sp .6
832 828 .RS 4n
833 829 Resource control limit exceeded. Generated by resource control facility.
834 830 .RE
835 831
836 832 .sp
837 833 .ne 2
838 834 .na
839 835 \fB\fBSIGXFSZ\fR\fR
840 836 .ad
841 837 .sp .6
842 838 .RS 4n
843 839 Terminate the process. File size limit exceeded. Available only to resource
844 840 controls with the \fBRCTL_GLOBAL_FILE_SIZE\fR property
845 841 (\fBprocess.max-file-size\fR). See \fBrctlblk_set_value\fR(3C).
846 842 .RE
847 843
848 844 .sp
849 845 .ne 2
850 846 .na
↓ open down ↓ |
205 lines elided |
↑ open up ↑ |
851 847 \fB\fBSIGXCPU\fR\fR
852 848 .ad
853 849 .sp .6
854 850 .RS 4n
855 851 Terminate the process. CPU time limit exceeded. Available only to resource
856 852 controls with the \fBRCTL_GLOBAL_CPUTIME\fR property
857 853 (\fBprocess.max-cpu-time\fR). See \fBrctlblk_set_value\fR(3C).
858 854 .RE
859 855
860 856 .SS "Resource Control Flags and Properties"
861 -.sp
862 857 .LP
863 858 Each resource control on the system has a certain set of associated properties.
864 859 This set of properties is defined as a set of flags, which are associated with
865 860 all controlled instances of that resource. Global flags cannot be modified, but
866 861 the flags can be retrieved by using either \fBrctladm\fR(1M) or the
867 862 \fBsetrctl\fR(2) system call.
868 863 .sp
869 864 .LP
870 865 Local flags define the default behavior and configuration for a specific
871 866 threshold value of that resource control on a specific process or process
872 867 collective. The local flags for one threshold value do not affect the behavior
873 868 of other defined threshold values for the same resource control. However, the
874 869 global flags affect the behavior for every value associated with a particular
875 870 control. Local flags can be modified, within the constraints supplied by their
876 871 corresponding global flags, by the \fBprctl\fR command or the \fBsetrctl\fR
877 872 system call. See \fBsetrctl\fR(2).
878 873 .sp
879 874 .LP
880 875 For the complete list of local flags, global flags, and their definitions, see
881 876 \fBrctlblk_set_value\fR(3C).
882 877 .sp
883 878 .LP
884 879 To determine system behavior when a threshold value for a particular resource
885 880 control is reached, use \fBrctladm\fR to display the global flags for the
886 881 resource control . For example, to display the values for
887 882 \fBprocess.max-cpu-time\fR, enter:
888 883 .sp
889 884 .in +2
890 885 .nf
891 886 $ rctladm process.max-cpu-time
892 887 process.max-cpu-time syslog=off [ lowerable no-deny cpu-time inf seconds ]
893 888 .fi
894 889 .in -2
895 890
896 891 .sp
897 892 .LP
898 893 The global flags indicate the following:
899 894 .sp
900 895 .ne 2
901 896 .na
902 897 \fB\fBlowerable\fR\fR
903 898 .ad
904 899 .sp .6
905 900 .RS 4n
906 901 Superuser privileges are not required to lower the privileged values for this
907 902 control.
908 903 .RE
909 904
910 905 .sp
911 906 .ne 2
912 907 .na
913 908 \fB\fBno-deny\fR\fR
914 909 .ad
915 910 .sp .6
916 911 .RS 4n
917 912 Even when threshold values are exceeded, access to the resource is never
918 913 denied.
919 914 .RE
920 915
921 916 .sp
922 917 .ne 2
923 918 .na
924 919 \fB\fBcpu-time\fR\fR
925 920 .ad
926 921 .sp .6
927 922 .RS 4n
928 923 \fBSIGXCPU\fR is available to be sent when threshold values of this resource
929 924 are reached.
930 925 .RE
931 926
932 927 .sp
933 928 .ne 2
934 929 .na
935 930 \fB\fBseconds\fR\fR
936 931 .ad
937 932 .sp .6
938 933 .RS 4n
939 934 The time value for the resource control.
940 935 .RE
941 936
942 937 .sp
943 938 .LP
944 939 Use the \fBprctl\fR command to display local values and actions for the
945 940 resource control. For example:
946 941 .sp
947 942 .in +2
948 943 .nf
949 944 $ prctl -n process.max-cpu-time $$
950 945 process 353939: -ksh
951 946 NAME PRIVILEGE VALUE FLAG ACTION RECIPIENT
952 947 process.max-cpu-time
953 948 privileged 18.4Es inf signal=XCPU -
954 949 system 18.4Es inf none
955 950 .fi
↓ open down ↓ |
84 lines elided |
↑ open up ↑ |
956 951 .in -2
957 952
958 953 .sp
959 954 .LP
960 955 The \fBmax\fR (\fBRCTL_LOCAL_MAXIMAL\fR) flag is set for both threshold values,
961 956 and the \fBinf\fR (\fBRCTL_GLOBAL_INFINITE\fR) flag is defined for this
962 957 resource control. An \fBinf\fR value has an infinite quantity. The value is
963 958 never enforced. Hence, as configured, both threshold quantities represent
964 959 infinite values that are never exceeded.
965 960 .SS "Resource Control Enforcement"
966 -.sp
967 961 .LP
968 962 More than one resource control can exist on a resource. A resource control can
969 963 exist at each containment level in the process model. If resource controls are
970 964 active on the same resource at different container levels, the smallest
971 965 container's control is enforced first. Thus, action is taken on
972 966 \fBprocess.max-cpu-time\fR before \fBtask.max-cpu-time\fR if both controls are
973 967 encountered simultaneously.
974 968 .SH ATTRIBUTES
975 -.sp
976 969 .LP
977 970 See \fBattributes\fR(5) for a description of the following attributes:
978 971 .sp
979 972
980 973 .sp
981 974 .TS
982 975 box;
983 976 c | c
984 977 l | l .
985 978 ATTRIBUTE TYPE ATTRIBUTE VALUE
986 979 _
987 980 Interface Stability Evolving
988 981 .TE
989 982
990 983 .SH SEE ALSO
991 -.sp
992 984 .LP
993 985 \fBprctl\fR(1), \fBpooladm\fR(1M), \fBpoolcfg\fR(1M), \fBprojadd\fR(1M),
994 986 \fBprojmod\fR(1M), \fBrctladm\fR(1M), \fBsetrctl\fR(2),
995 987 \fBrctlblk_set_value\fR(3C), \fBlibpool\fR(3LIB), \fBproject\fR(4),
996 988 \fBattributes\fR(5), \fBFSS\fR(7)
997 989 .sp
998 990 .LP
999 991 \fISystem Administration Guide: Virtualization Using the Solaris Operating
1000 992 System\fR
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX