hashicorp/nomad · error
minimum MemoryMB value is %d; got %d
Error message
minimum MemoryMB value is %d; got %d
What it means
Resources.MeetsMinResources() verifies MemoryMB meets the floor from MinResources(). Task memory below the documented minimum is rejected at job validation time because drivers and the scheduler assume a viable baseline footprint.
Source
Thrown at nomad/structs/structs.go:2605
for _, n := range r.Networks {
n.Canonicalize()
}
r.NUMA.Canonicalize()
}
// MeetsMinResources returns an error if the resources specified are less than
// the minimum allowed.
// This is based on the minimums defined in the Resources type
// COMPAT(0.10): Remove in 0.10
func (r *Resources) MeetsMinResources() error {
var mErr multierror.Error
minResources := MinResources()
if r.CPU < minResources.CPU && r.Cores == 0 {
mErr.Errors = append(mErr.Errors, fmt.Errorf("minimum CPU value is %d; got %d", minResources.CPU, r.CPU))
}
if r.MemoryMB < minResources.MemoryMB {
mErr.Errors = append(mErr.Errors, fmt.Errorf("minimum MemoryMB value is %d; got %d", minResources.MemoryMB, r.MemoryMB))
}
return mErr.ErrorOrNil()
}
// Copy returns a deep copy of the resources
func (r *Resources) Copy() *Resources {
if r == nil {
return nil
}
return &Resources{
CPU: r.CPU,
Cores: r.Cores,
MemoryMB: r.MemoryMB,
MemoryMaxMB: r.MemoryMaxMB,
DiskMB: r.DiskMB,
IOPS: r.IOPS,
Networks: r.Networks.Copy(),
Devices: r.Devices.Copy(),View on GitHub (pinned to 482b49bf1a)
Solutions
- Raise MemoryMB (memory) to at least the minimum shown in the error message
- Update saved job templates to the current minimum value
- Check nomad job validate output for the exact required minimum in your version
Example fix
// before
resources {
memory = 10
}
// after
resources {
memory = 128
} Defensive patterns
Strategy: validation
Validate before calling
min := structs.MinResources()
if r.MemoryMB < min.MemoryMB {
return fmt.Errorf("memory must be >= %d", min.MemoryMB)
} Type guard
func meetsMinMemory(r *structs.Resources) bool { return r.MemoryMB >= structs.MinResources().MemoryMB } Prevention
- Set memory to realistic minimums (>= 128MB) in templates
- Run nomad job validate in CI
- Avoid hand-tuning memory below documented minimums
When it happens
Trigger: Submitting a job whose task Resources.MemoryMB is less than MinResources().MemoryMB, e.g. memory = 10 with minimum 128.
Common situations: Specifying unrealistically tiny memory to overpack nodes; legacy specs from older Nomad versions with smaller minimums; typos (memory = 12 instead of 128).
Related errors
- MemoryMaxMB value (%d) should be larger than MemoryMB value
- SecretsMB value (%d) cannot be larger than MemoryMB value (%
- Missing task resources
- QEMU memory assignment out of bounds
- Memory oversubscription is not enabled; Task "%v.%v" memory_
AI-assisted analysis of hashicorp/nomad@482b49bf1a (2026-09-04).
Data as JSON: /api/errors/1935a998084d33a0.
Report an issue: GitHub.