Skip to content

Commit 820bc9a

Browse files
authored
Merge pull request #23730 from dvdksn/engine-29-limitnofile
engine: document LimitNOFILE change in engine v29 / containerd v2.1.5
2 parents e21ee9d + 60a2669 commit 820bc9a

File tree

2 files changed

+29
-3
lines changed

2 files changed

+29
-3
lines changed

content/manuals/engine/release-notes/25.0.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -217,9 +217,9 @@ For a full list of pull requests and changes in this release, refer to the relev
217217
`LimitNOFILE=1048576`.
218218
219219
This change currently only affects build containers created with `docker
220-
build` when using BuildKit with the `docker` driver. Future versions of
221-
containerd will also use this limit, which will cause this behavior to affect
222-
all containers, not only build containers.
220+
build` when using BuildKit with the `docker` driver. Starting with Docker
221+
Engine v29.0 (containerd v2.1.5), this limit applies to all containers, not
222+
only build containers.
223223
224224
If you're experiencing issues with the higher ulimit in systemd v240 or later,
225225
consider adding a system `drop-in` or `override` file to configure the ulimit

content/manuals/engine/release-notes/29.md

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -98,6 +98,32 @@ For a full list of pull requests and changes in this release, refer to the relev
9898
- The Windows overlay network driver now supports option `--dns`. [moby/moby#51229](https://github.com/moby/moby/pull/51229)
9999
- Update BuildKit to [v0.25.2](https://github.com/moby/buildkit/releases/tag/v0.25.2). [moby/moby#51397](https://github.com/moby/moby/pull/51397)
100100
- Update containerd to [v2.1.5](https://github.com/containerd/containerd/releases/tag/v2.1.5). [moby/moby#51409](https://github.com/moby/moby/pull/51409)
101+
102+
containerd v2.1.5 now uses systemd's default `LimitNOFILE` for containers,
103+
changing the open file descriptor limit (`ulimit -n`) from `1048576` to
104+
`1024`. This extends a change introduced in Docker Engine v25.0 for build
105+
containers to all containers.
106+
107+
This prevents programs that adjust behavior based on ulimits from consuming
108+
excessive memory when the limit is set to `infinity`. Containers now behave
109+
the same way as programs running on the host.
110+
111+
If your workload needs a higher limit, use `--ulimit` with `docker run`, or
112+
set defaults in `/etc/docker/daemon.json`:
113+
114+
```json
115+
{
116+
"default-ulimits": {
117+
"nofile": {
118+
"Name": "nofile",
119+
"Soft": 1048576,
120+
"Hard": 1048576
121+
}
122+
}
123+
}
124+
```
125+
126+
For more information, see [moby#51485](https://github.com/moby/moby/issues/51485).
101127
- Update Go runtime to [1.25.4](https://go.dev/doc/devel/release#go1.25.4). [moby/moby#51418](https://github.com/moby/moby/pull/51418), [docker/cli#6632](https://github.com/docker/cli/pull/6632)
102128
- Users can request a specific prefix size for networks allocated from the default pools by using the unspecified address, for example `--subnet 0.0.0.0/24 --subnet ::/96`. [moby/moby#50114](https://github.com/moby/moby/pull/50114)
103129

0 commit comments

Comments
 (0)