System information

Kernel Control Groups 125
# Create a child cgroup:
mkdir /freezer/0
# Put a task into this cgroup:
echo $task_pid > /freezer/0/tasks
# Freeze it:
echo FROZEN > /freezer/0/freezer.state
# Unfreeze (thaw) it:
echo THAWED > /freezer/0/freezer.state
Checkpoint/Restart (Control)
Save the state of all processes in a cgroup to a dump file. Restart it later (or just
save the state and continue).
Move a “saved container” between physical machines (as VM can do).
Dump all process images of a cgroup to a file.
Devices (Isolation)
A system administrator can provide a list of devices that can be accessed by
processes under cgroups.
It limits access to a device or a file system on a device to only tasks that belong
to the specified cgroup. For more information, see /usr/src/linux/Docu
mentation/cgroups/devices.txt.
Cpuacct (Control)
The CPU accounting controller groups tasks using cgroups and accounts the CPU
usage of these groups. For more information, see /usr/src/linux/Docu
mentation/cgroups/cpuacct.txt.
CPU (Resource Control)
Share CPU bandwidth between groups with the group scheduling function of CFS
(the scheduler). Mechanically complicated.
Memory (Resource Control)
Limits memory usage of user space processes.
Control swap usage by setting swapaccount=1 as a kernel boot para-
meter.
Limit LRU (Least Recently Used) pages.