MCPcopy Create free account
hub / github.com/containerd/cgroups / Subsystems

Function Subsystems

cgroup1/subsystem.go:49–70  ·  view source on GitHub ↗

Subsystems returns a complete list of the default cgroups available on most linux systems

()

Source from the content-addressed store, hash-verified

47// Subsystems returns a complete list of the default cgroups
48// available on most linux systems
49func Subsystems() []Name {
50 n := []Name{
51 Freezer,
52 Pids,
53 NetCLS,
54 NetPrio,
55 PerfEvent,
56 Cpuset,
57 Cpu,
58 Cpuacct,
59 Memory,
60 Blkio,
61 Rdma,
62 }
63 if !userns.RunningInUserNS() {
64 n = append(n, Devices)
65 }
66 if _, err := os.Stat("/sys/kernel/mm/hugepages"); err == nil {
67 n = append(n, Hugetlb)
68 }
69 return n
70}
71
72type Subsystem interface {
73 Name() Name

Callers 8

TestCreateFunction · 0.85
TestAddFunction · 0.85
TestAddTaskFunction · 0.85
TestListPidsFunction · 0.85
TestListTasksPidsFunction · 0.85
TestCreateSubCgroupFunction · 0.85
TestSubsystemsFunction · 0.85

Calls 1

StatMethod · 0.65

Tested by 8

TestCreateFunction · 0.68
TestAddFunction · 0.68
TestAddTaskFunction · 0.68
TestListPidsFunction · 0.68
TestListTasksPidsFunction · 0.68
TestCreateSubCgroupFunction · 0.68
TestSubsystemsFunction · 0.68

Used in the wild real call sites across dependent graphs

searching dependent graphs…