Repository navigation
Description
Context
Filing from calque (github.com/spore-host/calque), which consumes spawn as a library and calls launcher.Provision with an empty LaunchConfig.AMI (letting spawn auto-select, via GetRecommendedAMI). On every GPU instance I tried (g7e.2xlarge, g6.2xlarge, us-west-2), auto-selection fails. Two distinct bugs.
Bug 1 — DetectGPUInstance misses newer GPU families
pkg/aws/ami.go DetectGPUInstance recognizes:
p5, p4, p3, g6, g5, g4, g5g, inf2, inf1, trn1
Missing: g6e, g7, g7e (and p6). So for a g7e.2xlarge it returns false and resolves a non-GPU AL2023 AMI — an instance that boots without GPU drivers. Silent wrong-AMI, not an error.
Bug 2 — the GPU AL2023 SSM parameter does not exist
For families it does detect as GPU (e.g. g6), GetAL2023AMI resolves:
/aws/service/ami-amazon-linux-latest/al2023-ami-kernel-default-gpu-x86_64
That SSM public parameter does not exist (ParameterNotFound) — verified in us-west-2:
$ aws ssm get-parameter --name /aws/service/ami-amazon-linux-latest/al2023-ami-kernel-default-gpu-x86_64
ParameterNotFound
$ aws ssm get-parameter --name /aws/service/ami-amazon-linux-latest/al2023-ami-kernel-default-x86_64
ami-0b787142aa56d54db # non-GPU resolves fine
AL2023 does not publish a -gpu- variant at that path. So Provision with an empty AMI on ANY correctly-detected GPU instance fails with ParameterNotFound before RunInstances.
Net: launcher.Provision cannot auto-select a working AMI for a GPU instance today — either it picks a non-GPU AMI (bug 1) or errors (bug 2).
Asks
- Add
g6e,g7,g7e(andp6) toDetectGPUInstance. - For GPU instances, resolve a real GPU-capable AMI. Options: the DLAMI SSM params (e.g.
/aws/service/deeplearning/ami/x86_64/base-oss-nvidia-driver-gpu-amazon-linux-2023/latest/ami-id, which resolves), or the AL2 GPU AMI path, or document that GPU callers must pinLaunchConfig.AMI. - Consider surfacing a clear error ("no GPU AMI for family X; pin AMI") instead of a raw
ParameterNotFound, so consumers don't mistake it for a transient failure.
Interim (calque side)
Pinning LaunchConfig.AMI to a Deep Learning AMI (DL Base OSS NVIDIA, Ubuntu 22.04) — which also gives Docker + nvidia-container-toolkit for our container workload. Also hardened our retry classifier so ParameterNotFound is terminal (it was masquerading as a capacity wait and looping).
Not blocking us (pinning works), but auto-select is effectively unusable for GPU instances as-is.
/cc downstream: spore-host/calque
Activity
scttfrdmn commentedon Jul 21, 2026
Fixed by spawn#384, shipped in spawn v0.79.0 (this issue and #384 are the same two bugs; leaving #384 as the canonical reference).
Both bugs from this report are resolved in
pkg/aws/ami.go:DetectGPUInstancenow recognizesg6e,g7,g7e,p6(plusg4dn/p4de/p5e) — sog7e.2xlargeetc. no longer silently fall back to a CPU AMI. Matching is exact-family with explicit multi-letter entries (ag6entry deliberately does not matchg6e). Neuron (inf*/trn*) and AMD (g4ad) are correctly excluded.al2023-ami-kernel-default-gpu-{x86_64,arm64}(which never existed →ParameterNotFound). It resolves the Deep Learning Base OSS Nvidia Driver GPU AMI (AL2023) via thedeeplearningSSM namespace (/aws/service/deeplearning/ami/{x86_64,arm64}/base-oss-nvidia-driver-gpu-amazon-linux-2023/latest/ami-id), which does resolve — solauncher.Provisionwith an empty AMI now works for GPU instances. (Ask 3's rawParameterNotFoundno longer occurs on the GPU path as a result.)Covered by
TestDetectGPUInstanceinpkg/aws/ami_test.go(includesg6e/g7ecases, green). /cc spore-host/calque — auto-select works for GPU now; pinningLaunchConfig.AMIremains valid if you want a specific DLAMI (e.g. Ubuntu + Docker + nvidia-container-toolkit).