hashicorp/nomad · error
unable to lookup job summary for job id %q in namespace %q:
Error message
unable to lookup job summary for job id %q in namespace %q: %v
What it means
Wraps a txn.First error when looking up the JobSummary for an allocation's job inside updateDeploymentWithAlloc / alloc summary update. This is a read failure (memdb error), distinct from the summary simply not existing, which is handled separately.
Source
Thrown at nomad/state/state_store.go:6058
return err
}
return nil
}
// updateSummaryWithAlloc updates the job summary when allocations are updated
// or inserted
func (s *StateStore) updateSummaryWithAlloc(index uint64, alloc *structs.Allocation,
existingAlloc *structs.Allocation, txn *txn) error {
// We don't have to update the summary if the job is missing
if alloc.Job == nil {
return nil
}
summaryRaw, err := txn.First("job_summary", "id", alloc.Namespace, alloc.JobID)
if err != nil {
return fmt.Errorf("unable to lookup job summary for job id %q in namespace %q: %v", alloc.JobID, alloc.Namespace, err)
}
if summaryRaw == nil {
// Check if the job is de-registered
rawJob, err := txn.First("jobs", "id", alloc.Namespace, alloc.JobID)
if err != nil {
return fmt.Errorf("unable to query job: %v", err)
}
// If the job is de-registered then we skip updating it's summary
if rawJob == nil {
return nil
}
return fmt.Errorf("job summary for job %q in namespace %q is not present", alloc.JobID, alloc.Namespace)
}
// Get a copy of the existing summaryView on GitHub (pinned to 482b49bf1a)
Solutions
- Inspect the wrapped inner error for the memdb cause
- Retry the alloc update (client heartbeats will resend)
- Check server logs for state store health issues
Defensive patterns
Strategy: retry
Try / catch
if err != nil && strings.Contains(err.Error(), "unable to lookup job summary") {
// alloc updates are re-sent by the client heartbeat; back off and retry
time.AfterFunc(time.Second, func() { retryAllocUpdate(alloc) })
} Prevention
- Let Nomad clients' built-in heartbeat handle retries
- Ensure sufficient server memory for memdb
- Watch for state store errors in server logs
When it happens
Trigger: Alloc update paths (client alloc updates, deployment health updates) where txn.First("job_summary", "id", alloc.Namespace, alloc.JobID) returns an error.
Common situations: Alloc status updates arriving on servers under memdb stress; race with job GC is handled via nil check, so errors here are internal.
Related errors
- error getting job summary: %v
- unable to create job summary: %v
- job_summary lookup failed: %v
- job summary lookup failed: %v
- error inserting job summary: %v
AI-assisted analysis of hashicorp/nomad@482b49bf1a (2026-09-04).
Data as JSON: /api/errors/5bfd19acc7b47220.
Report an issue: GitHub.