hashicorp/nomad · error

no such plugin %q

Error message

no such plugin %q

What it means

CreateSnapshot looks up each volume's CSIPluginID in the state store. If CSIPluginByID returns no error but a nil plugin, Nomad has no record of that plugin and appends 'no such plugin %q' to the multierror, skipping that volume. This means the volume references a plugin that is not registered with the cluster.

Source

Thrown at nomad/csi_endpoint.go:1639

		}
		if vol == nil {
			multierror.Append(&mErr, fmt.Errorf("no such volume %q", snap.SourceVolumeID))
			continue
		}

		pluginID := snap.PluginID
		if pluginID == "" {
			pluginID = vol.PluginID
		}

		plugin, err := state.CSIPluginByID(nil, pluginID)
		if err != nil {
			multierror.Append(&mErr,
				fmt.Errorf("error querying plugin %q: %v", pluginID, err))
			continue
		}
		if plugin == nil {
			multierror.Append(&mErr, fmt.Errorf("no such plugin %q", pluginID))
			continue
		}
		if !plugin.HasControllerCapability(structs.CSIControllerSupportsCreateDeleteSnapshot) {
			multierror.Append(&mErr,
				fmt.Errorf("plugin %q does not support snapshot", pluginID))
			continue
		}

		secrets := vol.Secrets
		// merge request secrets onto volume secrets
		maps.Copy(secrets, snap.Secrets)

		cReq := &cstructs.ClientCSIControllerCreateSnapshotRequest{
			ExternalSourceVolumeID: vol.ExternalID,
			Name:                   snap.Name,
			Secrets:                secrets,
			Parameters:             snap.Parameters,
		}

View on GitHub (pinned to 482b49bf1a)

Solutions

  1. Check the plugin ID with 'nomad volume status <volume-id>' and confirm it exists via 'nomad plugin status'
  2. Re-register the plugin by running its CSI plugin job, then retry the snapshot
  3. If the volume spec has a stale plugin_id, update the volume or use the correct current plugin name

Example fix

// before (volume references removed plugin)
volume "data" { plugin_id = "aws-ebs-old" ... }
// after
volume "data" { plugin_id = "aws-ebs" ... }
nomad volume update data.hcl
Defensive patterns

Strategy: validation

Validate before calling

// verify plugin is registered before snapshotting
plugins, _ := client.Plugins().List()
found := false
for _, p := range plugins { if p.ID == pluginID { found = true } }
if !found { return fmt.Errorf("plugin %q is not registered", pluginID) }

Try / catch

// multierror responses: inspect each message
err := client.Volumes().CreateSnapshot(req)
if err != nil && strings.Contains(err.Error(), "no such plugin") {
    // re-register plugin job, then retry
}

Prevention

When it happens

Trigger: Snapshotting a volume whose CSI plugin was deregistered (all plugin node/controller allocations stopped and the plugin was GC'd), or whose plugin ID was renamed in the volume spec after registration.

Common situations: Plugin jobs stopped/removed before snapshotting; volume spec edited to point at a plugin ID that was never registered; cluster state restored from a snapshot missing the plugin registration; plugin garbage collection after node drain.

Related errors


AI-assisted analysis of hashicorp/nomad@482b49bf1a (2026-09-04). Data as JSON: /api/errors/c47a2aca63eb4bf1. Report an issue: GitHub.