The containerd.io package for ubuntu 24.04 was upgraded on 2025-11-10 from 1.7.29 to 2.1.5.
This version’s /usr/lib/systemd/system/containerd.service removed:
LimitNOFILE=infinity
As a consequence it seems that containerd now starts with systemd’s default soft limit of 1024 and Docker Swarm inherits these limits. The old behavior (soft=hard=infinity) disappeared.
One can detect this inside a container checking the applied limits on the processes doing e.g.
cat /proc/1/limits
In my case i saw Max open files 1024 524288 .
Checking the containerd version using
$ containerd --version
containerd containerd.io v2.1.5 fcd43222d6b07379a4be9786bda52438f0dd16a1
I could see the containerd version increased to 2.1.5 .
Potential ways to fix
Option 1: Systemd override (global)
We can change this specific behavior while keeping the current containerd version if we reintroduce the LimitNOFILE field into the container.service by doing this:
sudo systemctl edit containerd.service
Then we add the field with a higher number
[Service]
LimitNOFILE=64000
and reload
sudo systemctl daemon-reload
sudo systemctl restart containerd
sudo systemctl restart docker
Option 2: in docker stack YAML
Just add the limits in the yaml file you want to deploy
ulimits:
nofile:
soft: 64000
hard: 64000
Option 3: Downgrading container.io
I did not try this, but a clean uninstall and reinstall of container.io should resolve the issue too.
Note: The issue persists even if you downgrade Docker because containerd.io stays upgraded unless you downgrade manually.