All Topics
All Topics
Technology
Technology
Design
Design
Programming
Programming
Science
Science
News
News
Gaming
Gaming
Entertainment
Entertainment
Business
Business
Finance
Finance
Sports
Sports
Health
Health
Food
Food
Travel
Travel
Art
Art
Music
Music
Books
Books
Education
Education
Politics
Politics
Personal
Personal
No algorithm. No AI slop. No ads. Just RSS. Pro-human. Indie writers. Real journalism. Open web. Chronological. Hand toasted.

Systemd cgroup driver bug: containerd CPU quota calculation mismatch causes container creation failures

By

dropbox_miner

6mo ago· 9 min readenCode

Summary

The article describes a technical bug in container orchestration systems where using the systemd cgroup driver with a CPU limit of 4096m causes intermittent pod creation failures. The issue stems from containerd non-deterministically calculating either 409600 or 410000 microseconds for parent cgroups, while runc consistently calculates 410000 for child cgroups. When these calculations mismatch, the Linux kernel rejects child cgroup creation with an "invalid argument" error. The article provides technical details about the root cause and implications for container management systems.

Key quotes

· 4 pulled
When using the systemd cgroup driver with a CPU limit of 4096m, pod creation fails intermittently because containerd non-deterministically calculates either 409600 or 410000 microseconds for the parent cgroup, while runc consistently calculates 410000 for child cgroups.
When they mismatch, the Linux kernel rejects the child cgroup creation with 'invalid argument'.
Investigation reveals non-deterministic behavior in containerd when converting 4096m to microseconds.
Containerd (when creating pod sandbox) - INCONSISTENT: Sometimes calculates: 4096m → 409600 microseconds
Snippet from the RSS feed
Description When using the systemd cgroup driver with a CPU limit of 4096m, pod creation fails intermittently because containerd non-deterministically calculates either 409600 or 410000 microsecond...

You might also wanna read