cgroups

package
v0.1.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 22, 2026 License: AGPL-3.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const DefaultCgroupRoot = "/sys/fs/cgroup"

DefaultCgroupRoot is the standard cgroup v2 root

Variables

This section is empty.

Functions

func FindContainerCgroupPath

func FindContainerCgroupPath(cgroupRoot, podUID, containerID string) (string, error)

FindContainerCgroupPath attempts to find the cgroup path for a container ID. Tries well-known patterns first, then falls back to walking the cgroup tree.

func GetCgroupInodeFromPath

func GetCgroupInodeFromPath(path string) (uint64, error)

GetCgroupInodeFromPath returns the inode number of a cgroup directory on Linux.

func ReadCgroupProcs

func ReadCgroupProcs(cgroupPath string) ([]int, error)

ReadCgroupProcs reads the PIDs from a cgroup's cgroup.procs file.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL