Skip to content

[pull] main from containerd:main#391

Merged
pull[bot] merged 9 commits into
meonBot:mainfrom
containerd:main
Jun 26, 2026
Merged

[pull] main from containerd:main#391
pull[bot] merged 9 commits into
meonBot:mainfrom
containerd:main

Conversation

@pull

@pull pull Bot commented Jun 26, 2026

Copy link
Copy Markdown

See Commits and Changes for more details.


Created by pull[bot] (v2.0.0-alpha.4)

Can you help keep this open source service alive? 💖 Please sponsor : )

Mikhail Dmitrichenko and others added 9 commits June 19, 2026 14:16
dmsetup.Status() returns a nil DeviceStatus when it fails.  The mkfs
failure path records that error, but still unconditionally dereferences
status when logging the pool status.

Avoid the panic by logging a fallback status string when dmsetup.Status()
does not return a status.

Found by Linux Verification Center (linuxtesting.org) with SVACE.

Signed-off-by: Mikhail Dmitrichenko <m.dmitrichenko222@gmail.com>
The image_pulling_throughput histogram divided the full image size (all
layers plus config) by wall-clock pull duration. Layers already present
in the content store were counted in the numerator, so the reported
MB/s came out way higher than what was actually fetched. Fully-cached
pulls were the worst case: they "pulled" in milliseconds but reported
the full image size, showing up as huge outliers in the histogram.

Both pull paths (local client.Pull and the transfer service) already
maintain a totalBytesRead counter in pullRequestReporter for progress
and timeout checks. Cached blobs never trigger a fetch, so the counter
naturally excludes them. Plumb that value out of both helpers and use
it in place of image.Size(ctx). Fully-cached pulls (bytesPulled == 0)
are not observed, so they don't produce near-infinite samples.

Also updates the metric's Help text to say the denominator is the
end-to-end pull duration including layer extraction and snapshotter
unpack, not just network transfer.

Addresses #13244

Signed-off-by: Ahmet Alp Balkan <ahmet@linkedin.com>
…hroughput

Address review feedback on the previous commit:

- Use MiB/s (binary, 1024^2) consistently. The divisor was already
  1024*1024; the constant name (mbToByte) and the Help/comment text
  mislabeled the unit.
- Keep image_pulling_throughput for backwards compatibility but mark
  it Deprecated. Its prom.DefBuckets top out at 10 MiB/s, which
  saturates almost immediately on modern hardware.
- Add image_pulling_throughput_mibps with buckets covering 0.1 MiB/s
  through 4000 MiB/s (~31 Gbps), enough for 10G+ NICs. Above that,
  disk write throughput becomes the bottleneck rather than the
  network, so finer buckets aren't worth the cardinality.
- Both metrics observe the same value (fetched bytes / pull duration,
  cached layers excluded; fully-cached pulls skipped). Only the
  buckets and deprecation status differ.

Signed-off-by: Ahmet Alp Balkan <ahmet@linkedin.com>
This test verifies the maximum file-size constraints that were added in
[containerd7b05ec4]. However, github.com/moby/sys@v0.4.1 adds similar
constraints, including a constraint on line-length (1M): [moby/sys@2c56c3d]
that may hit before the file-size limit is reached if the data does not
contain newlines.

This patch updates the test to use data that includes newlines to make
sure it's testing the file-size constraints, not line-limit constraints.

[containerd7b05ec4]: 7b05ec4
[moby/sys@2c56c3d]: moby/sys@2c56c3d

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Go 1.26 adds support for passing Windows file flags via os.OpenFile,
eliminating the need to call windows.CreateFile directly.

github.com/moby/sys/sequential v0.7.0 uses this functionality when
compiled with go1.26, but provides fallbacks for older Go versions.

Given that containerd has go1.26 as a minimum requirement, we can
remove github.com/moby/sys/sequential as an intermediate, and implement
the code locally.

ref:

- moby/sys@9d2fc63
- https://go-review.googlesource.com/c/go/+/699415
- https://go-review.googlesource.com/c/go/+/724621

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
…ched-layers

cri: exclude cached layer bytes from image_pulling_throughput_mibps
…eads

pkg/oci: update TestOpenUserFileCapsReads to use newlined data
pkg/archive: remove redundant github.com/moby/sys/sequential dependency
snapshots/devmapper: avoid nil status deref after mkfs failure
@pull pull Bot locked and limited conversation to collaborators Jun 26, 2026
@pull pull Bot added the ⤵️ pull label Jun 26, 2026
@pull
pull Bot merged commit 484c12c into meonBot:main Jun 26, 2026
2 checks passed
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants