Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

cgclassify(1) [centos man page]

CGCLASSIFY(1)							 libcgroup Manual						     CGCLASSIFY(1)

NAME
cgclassify - move running task(s) to given cgroups SYNOPSIS
cgclassify [-g <controllers>:<path>] [--sticky | --cancel-sticky] <pidlist> DESCRIPTION
this command moves processes defined by the list of processes (pidlist) to the given control groups. The pids in the pidlist are separated by spaces -g <controllers>:<path> defines the control groups where the task will be moved. controllers is a list of controllers and path is the relative path to con- trol groups in the given controllers list. This flag can be used multiple times to define multiple pairs of lists of controllers and relative paths. Instead of the list of all mounted controllers, the wildcard * can be used. If this option is not used then cgclassify will automatically move the task to a control group based on /etc/cgrules.conf. --sticky If this option is used, the daemon of service cgred (cgrulesengd process) does not change both the specified pidlist and their chil- dren tasks. Without this option, the daemon does not change the specified pidlist but it automatically changes their child tasks to the right cgroup based on /etc/cgrules.conf. --cancel-sticky If this option is used, the daemon of service cgred (cgrulesengd process) can automatically change both the specified pidlist and their child tasks to the right cgroup based on /etc/cgrules.conf. ENVIRONMENT VARIABLES
CGROUP_LOGLEVEL controls verbosity of the tool. Allowed values are DEBUG, INFO, WARNING or ERROR. FILES
/etc/cgrules.conf default libcgroup configuration file SEE ALSO
cgrules.conf (5), cgexec (1) Linux 2009-03-15 CGCLASSIFY(1)

Check Out this Related Man Page

CGRULES.CONF(5) 						 libcgroup Manual						   CGRULES.CONF(5)

NAME
cgrules.conf - libcgroup configuration file DESCRIPTION
cgrules.conf configuration file is used by libcgroups to define control groups to which a process belongs. The file contains a list of rules which assign to a defined group/user a control group in a subsystem (or control groups in subsystems). Rules have two formats: <user> <controllers> <destination> <user>:<process name> <controllers> <destination> Where: user can be: - a user name - a group name with @group syntax - the wildcard '*', for any user or group - '%', which is equivalent to "ditto" (useful for multi-line rules where different cgroups need to be specified for various hierarchies for a single user) process name is optional and it can be: - a process name - a full command path of a process controllers can be: - comma separated controller names (no spaces) or - * (for all mounted controllers) destination can be: - path relative to the controller hierarchy (ex. pgrp1/gid1/uid1) - following strings will get expanded %u username, uid if name resolving fails %U uid %g group name, gid if name resolving fails %G gid %p process name, pid if name not available %P pid '' can be used to escape '%' First rule which matches the criteria will be executed. Any text starting with '#' is considered as a start of comment line and is ignored. EXAMPLES
student devices /usergroup/students Student's processes in the 'devices' subsystem belong to the control group /usergroup/students. student:cp devices /usergroup/students/cp When student executes 'cp' command, the processes in the 'devices' subsystem belong to the control group /usergroup/students/cp. @admin * admingroup/ Processes started by anybody from admin group no matter in what subsystem belong to the control group admingroup/. peter cpu test1/ % memory test2/ The first line says Peter's task for cpu controller belongs to test1 control group. The second one says Peter's tasks for memory controller belong to test2/ control group. * * default/ All processes in any subsystem belong to the control group default/. Since the earliest matched rule is applied, it makes sense to have this line at the end of the list. It will put a task which was not mentioned in the previous rules to default/ control group. FILES
/etc/cgrules.conf default libcgroup configuration file SEE ALSO
cgconfig.conf (5), cgclassify (1), cgred.conf (5) BUGS
Linux 2009-03-10 CGRULES.CONF(5)
Man Page