Debian Codegraph @

doc/cset-set.1

raw
1 '\" t
2 .\" Title: cset-set
3 .\" Author: Alex Tsariounov <[email protected]>
4 .\" Generator: DocBook XSL Stylesheets v1.78.1 <http://docbook.sf.net/>
5 .\" Date: March 2016
6 .\" Manual: \ \&
7 .\" Source: \ \& 1.5.8
8 .\" Language: English
9 .\"
10 .TH "CSET\-SET" "1" "March 2016" "\ \& 1\&.5\&.8" "\ \&"
11 .\" -----------------------------------------------------------------
12 .\" * Define some portability stuff
13 .\" -----------------------------------------------------------------
14 .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
15 .\" http://bugs.debian.org/507673
16 .\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html
17 .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
18 .ie \n(.g .ds Aq \(aq
19 .el .ds Aq '
20 .\" -----------------------------------------------------------------
21 .\" * set default formatting
22 .\" -----------------------------------------------------------------
23 .\" disable hyphenation
24 .nh
25 .\" disable justification (adjust text to left margin only)
26 .ad l
27 .\" -----------------------------------------------------------------
28 .\" * MAIN CONTENT STARTS HERE *
29 .\" -----------------------------------------------------------------
30 .SH "NAME"
31 cset-set \- manage sets of cpus
32 .SH "SYNOPSIS"
33 .sp
34 .nf
35 \fIcset\fR [cset options] \fIset\fR [set options] [args]
36 \fIcset\fR set \-\-help
37 \fIcset\fR set
38 \fIcset\fR set \-\-recurse
39 \fIcset\fR set \-\-list myset
40 \fIcset\fR set myset
41 \fIcset\fR set \-\-recurse \-\-list myset
42 \fIcset\fR set \-\-cpu 2\-5 \-\-mem 0 \-\-set newset
43 \fIcset\fR set \-\-cpu 2\-5 newset
44 \fIcset\fR set \-\-cpu 1,2,5\-7 another_set
45 \fIcset\fR set \-\-destroy newset
46 \fIcset\fR set \-\-destroy /mygroup_sets/my_set
47 .fi
48 .SH "OPTIONS"
49 .PP
50 \-h, \-\-help
51 .RS 4
52 prints the list of options for this command
53 .RE
54 .PP
55 \-l, \-\-list
56 .RS 4
57 list the named cpuset(s); if \-r is used, will list recursively
58 .RE
59 .PP
60 \-c CPUSPEC, \-\-cpu=CPUSPEC
61 .RS 4
62 create or modify cpuset in the specified cpuset with CPUSPEC specification
63 .RE
64 .PP
65 \-m MEMSPEC, \-\-mem=MEMSPEC
66 .RS 4
67 specify which memory nodes to assign to the created or modified cpuset
68 .RE
69 .PP
70 \-d, \-\-destroy
71 .RS 4
72 destroy specified cpuset
73 .RE
74 .PP
75 \-s CPUSET, \-\-set=CPUSET
76 .RS 4
77 specify cpuset name to be acted on
78 .RE
79 .PP
80 \-r, \-\-recurse
81 .RS 4
82 do recursive listing, for use with \-\-list
83 .RE
84 .PP
85 \-v, \-\-verbose
86 .RS 4
87 prints more detailed output, for the set command, using this flag will not chop listing to fit in 80 columns
88 .RE
89 .PP
90 \-\-cpu_exclusive
91 .RS 4
92 mark this cpuset as owning its CPUs exclusively
93 .RE
94 .PP
95 \-\-mem_exclusive
96 .RS 4
97 mark this cpuset as owning its MEMs exclusively
98 .RE
99 .SH "DESCRIPTION"
100 This command is used to create, modify, and destroy cpusets\&. Cpusets form a tree\-like structure rooted at the root cpuset which always includes all system CPUs and all system memory nodes\&.
101
102 A cpuset is an organizational unit that defines a group of CPUs and a group of memory nodes where a process or thread (i\&.e\&. task) is allowed to run on\&. For non\-NUMA machines, the memory node is always 0 (zero) and cannot be set to anything else\&. For NUMA machines, the memory node can be set to a similar specification as the CPU definition and will tie those memory nodes to that cpuset\&. You will usually want the memory nodes that belong to the CPUs defined to be in the same cpuset\&.
103
104 A cpuset can have exclusive right to the CPUs defined in it\&. This means that only this cpuset can own these CPUs\&. Similarly, a cpuset can have exclusive right to the memory nodes defined in it\&. This means that only this cpuset can own these memory nodes\&.
105
106 Cpusets can be specified by name or by path; however, care should be taken when specifying by name if the name is not unique\&. This tool will generally not let you do destructive things to non\-unique cpuset names\&.
107
108 Cpusets are uniquely specified by path\&. The path starts at where the cpusets filesystem is mounted so you generally do not have to know where that is\&. For example, so specify a cpuset that is called "two" which is a subset of "one" which in turn is a subset of the root cpuset, use the path "/one/two" regardless of where the cpusets filesystem is mounted\&.
109
110 When specifying CPUs, a so\-called CPUSPEC is used\&. The CPUSPEC will accept a comma\-separated list of CPUs and inclusive range specifications\&. For example, \-\-cpu=1,3,5\-7 will assign CPU1, CPU3, CPU5, CPU6, and CPU7 to the specified cpuset\&.
111
112 Note that cpusets follow certain rules\&. For example, children can only include CPUs that the parents already have\&. If you do not follow those rules, the kernel cpuset subsystem will not let you create that cpuset\&. For example, if you create a cpuset that contains CPU3, and then attempt to create a child of that cpuset with a CPU other than 3, you will get an error, and the cpuset will not be active\&. The error is somewhat cryptic in that it is usually a "Permission denied" error\&.
113
114 Memory nodes are specified with a MEMSPEC in a similar way to the CPUSPEC\&. For example, \-\-mem=1,3\-6 will assign MEM1, MEM3, MEM4, MEM5, and MEM6 to the specified cpuset\&.
115
116 Note that if you attempt to create or modify a cpuset with a memory node specification that is not valid, you may get a cryptic error message, "No space left on device", and the modification will not be allowed\&.
117
118 When you destroy a cpuset, then the tasks running in that set are moved to the parent of that cpuset\&. If this is not what you want, then manually move those tasks to the cpuset of your choice with the \fIcset proc\fR command (see \fIcset proc \-\-help\fR for more information)\&.
119 .SS "EXAMPLES"
120 .PP
121 Create a cpuset with the default memory specification
122 .RS 4
123 \fB# cset set \-\-cpu=2,4,6\-8 \-\-set=new_set\fR
124 .RE
125 This command creates a cpuset called "new_set" located off the root cpuset which holds CPUS 2,4,6,7,8 and node 0 (interleaved) memory\&. Note that \-\-set is optional, and you can just specify the name for the new cpuset after all arguments\&.
126
127 .PP
128 Create a cpuset that specifies both CPUs and memory nodes
129 .RS 4
130 \fB# cset set \-\-cpu=3 \-\-mem=3 /rad/set_one\fR
131 .RE
132 Note that this command uses the full path method to specify the name of the new cpuset "/rad/set_one"\&. It also names the new cpuset implicitly (i\&.e\&. no \-\-set option, although you can use that if you want to)\&. If the "set_one" name is unique, you can subsequently refer to is just by that\&. Memory node 3 is assigned to this cpuset as well as CPU 3\&.
133
134 The above commands will create the new cpusets, or if they already exist, they will modify them to the new specifications\&.
135 .SH "LICENSE"
136 Cpuset is licensed under the GNU GPL V2 only\&.
137 .SH "COPYRIGHT"
138 Copyright (c) 2008\-2011 Novell Inc\&.
139 .SH "AUTHOR"
140 Written by Alex Tsariounov <tsariounov@gmail\&.com>\&.
141 .SH "SEE ALSO"
142 cset(1), cset\-proc(1), cset\-shield(1)
143
144 /usr/share/doc/packages/cpuset/html/tutorial\&.html
145
146 taskset(1), chrt(1)
147
148 /usr/src/linux/Documentation/cpusets\&.txt
149 .SH "AUTHOR"
150 .PP
151 \fBAlex Tsariounov\fR <\&tsariounov@gmail\&.com\&>
152 .RS 4
153 Author.
154 .RE