1CGXSET(1)                      libcgroup Manual                      CGXSET(1)
2
3
4

NAME

6       cgxset - set the parameters of given cgroup(s)
7
8

SYNOPSIS

10       cgxset [-1] [-2] [-i] [-r <name=value>] <cgroup_path> ...
11       cgxset --copy-from <source_cgroup_path> <cgroup_path> ...
12
13

DESCRIPTION

15       Set the parameters of input cgroups.  When the request's cgroup version
16       differs from the system's cgroup version, cgxset will attempt to trans‐
17       late  from  one  version  to the other.  If the request version and the
18       system's version are the same, no translation is done and  cgxset  will
19       behave like cgset.  If no version is specified by the user (either [-1]
20       or [-2]) and the [-r] flag is specified,  the  behavior  is  undefined.
21       --copy-from does not require the cgroup version to be specified.
22
23
24       <path> is the name of the cgroup which should be changed.  This parame‐
25              ter can be used multiple times.
26
27
28       -1, --v1
29              data in/out of cgxset is in cgroup v1 format.  In this mode, the
30              user  will provide values in cgroup v1 format and receive values
31              in v1 format.  format.  If the system is running  in  cgroup  v2
32              mode, libcgroup will convert the data as necessary
33
34
35       -2, --v2
36              data in/out of cgxset is in cgroup v2 format.  In this mode, the
37              user will provide values in cgroup v2 format and receive  values
38              in v2 format.  If the system is running in cgroup v1 mode, libc‐
39              group will convert the data as necessary
40
41
42       -i, --ignore-unmappable
43              ignore errors for values that cannot be converted from v1 to  v2
44              or vice versa
45
46
47       -r <name=value>
48              defines  the  name of the file to set and the value which should
49              be written to that file.  This parameter can  be  used  multiple
50              times.
51
52
53       --copy-from <source_cgroup_path>
54              defines  the  name of the cgroup whose parameters will be copied
55              to the input cgroup.
56
57

ENVIRONMENT VARIABLES

59       CGROUP_LOGLEVEL
60              controls verbosity of the tool. Allowed values are DEBUG,  INFO,
61              WARNING or ERROR.
62
63

EXAMPLES

65       cgxset -1 -r cpuset.cpus=0-1 student
66              set  variable  cpus in control group student (controller cpuset)
67              to 0-1
68
69
70       cgxset -2 -r cpu.weight=42 first
71              set variable weight in control group first (controller  cpu)  to
72              42
73
74
75       cgxset --copy-from group1/ group2/
76              copy  all  parameters  of  group group1 to group group2 (for all
77              path where both cgroups are defined)
78
79
80

SEE ALSO

82       cgrules.conf (1), cgcreate (1), cgget (1), cgset (1), cgxget (1)
83
84
85
86Linux                             2022-08-03                         CGXSET(1)
Impressum