Where to start First steps track · 15 stages
Linux Labs

cgroups and namespaces — how containers work

cheat sheet · Linux · cgroups v2 https://lab.dimsanych.ru/en/wiki/cgroups-namespaces/

Cheat sheet

  • lsns namespaces (isolation)
  • systemd-cgls cgroup tree
  • systemd-cgtop per-cgroup resource usage
  • sudo nsenter -t PID -a bash enter all namespaces of a process
  • sudo systemctl set-property nginx.service MemoryMax=512M CPUQuota=50% TasksMax=100
  • systemctl show nginx.service -p MemoryCurrent -p MemoryMax
Loading…