hashicorp/nomad · error
Error querying host volumes: %w
Error message
Error querying host volumes: %w
What it means
Fires in hostVolumeList when the API call listing dynamic host volumes fails (server error, bad node/node-pool filter, or connectivity problem), so the volume listing cannot be shown.
Source
Thrown at command/volume_status_host.go:67
str, err := formatHostVolume(vol, opts)
if err != nil {
return fmt.Errorf("Error formatting host volume: %w", err)
}
c.Ui.Output(c.Colorize().Color(str))
return nil
}
func (c *VolumeStatusCommand) hostVolumeList(client *api.Client, nodeID, nodePool string, opts formatOpts) error {
if !(opts.json || len(opts.template) > 0) {
c.Ui.Output(c.Colorize().Color("[bold]Dynamic Host Volumes[reset]"))
}
vols, _, err := client.HostVolumes().List(&api.HostVolumeListRequest{
NodeID: nodeID,
NodePool: nodePool,
}, nil)
if err != nil {
return fmt.Errorf("Error querying host volumes: %w", err)
}
if len(vols) == 0 {
c.Ui.Error("No dynamic host volumes")
return nil // empty is not an error
}
str, err := formatHostVolumes(vols, opts)
if err != nil {
return fmt.Errorf("Error formatting host volumes: %w", err)
}
c.Ui.Output(c.Colorize().Color(str))
return nil
}
func getHostVolumeByPrefix(client *api.Client, prefix, ns string) (*api.HostVolumeStub, []*api.HostVolumeStub, error) {
vols, _, err := client.HostVolumes().List(nil, &api.QueryOptions{
Prefix: prefix,
Namespace: ns,View on GitHub (pinned to 482b49bf1a)
Solutions
- Verify cluster connectivity and ACL token permissions for host volumes
- Check the node ID / node pool filter values are valid
- Retry if the server was temporarily unavailable
Defensive patterns
Strategy: try-catch
When it happens
Trigger: Thrown at command/volume_status_host.go:67 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of hashicorp/nomad@482b49bf1a (2026-09-04).
Data as JSON: /api/errors/9fcea77e23873ee9.
Report an issue: GitHub.