Skip to content

atelet OOMs on multi-layer multi-GB images #120

Closed

Description

@azr

atelet's image-pull goes through memorypullcache.Fetch → mutate.Extract. On multi-GB multi-layer images, atelet OOMs: mutate.Extract has a defer layerReader.Close() inside its layer loop, and so, all decompressors and HTTP response bodies stay alive until extraction finishes.

I hit this with big enough image. Atelet OOMed at the default 64 GiB pod memory limit. Bumping the limit to 100 GiB unblocked me.

A fix PR is already open upstream: https://github.com/google/go-containerregistry/pull/2190 (CLA cleared in January, just waiting for maintainer review).

Workarounds in the meantime:

  • bump atelet's pod memory limit
  • carry a fork-local patch (happy to share)

Activity

  1. azr commented on May 29, 2026

    @azr
    ContributorAuthor
  2. dims commented on May 29, 2026

    @dims
    Collaborator

    Adrien Delorme (@azr) will this help? google/go-containerregistry@38d6e4087c

    looks like it was added in v0.21.6

  3. added
    kind/bug
    on May 29, 2026
  4. added
    prio/P1
    on May 31, 2026
  5. dberkov commented on Jul 19, 2026

    @dberkov
    Collaborator

    #463 covers this: Phase 0 bumps go-containerregistry ≥ v0.21.6 for immediate relief, and the redesign drops mutate.Extract in favor of streaming per-layer unpack (via containerd archive.Apply, as suggested above), making memory use independent of image size.

  6. added a commit that references this issue on Jul 20, 2026
    0be5cfe
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    area/nodekind/bugprio/P1

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions