{"record":{"id":"b4f3e2ee2d9ed53b","repo":"hashicorp/nomad","slug":"node-s-is-not-feasible-for-volume","errorCode":null,"errorMessage":"node %s is not feasible for volume","messagePattern":"node (.+?) is not feasible for volume","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"nomad/host_volume_endpoint.go","lineNumber":557,"sourceCode":"\t\tsemverCache:  make(map[string]feasible.VerConstraints),\n\t}\n\tconstraints := []*structs.Constraint{{\n\t\tLTarget: fmt.Sprintf(\"${attr.plugins.host_volume.%s.version}\", vol.PluginID),\n\t\tOperand: \"is_set\",\n\t}}\n\tconstraints = append(constraints, vol.Constraints...)\n\tchecker := feasible.NewConstraintChecker(ctx, constraints)\n\n\tif vol.NodeID != \"\" {\n\t\tnode, err := snap.NodeByID(nil, vol.NodeID)\n\t\tif err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t\tif node == nil {\n\t\t\treturn nil, fmt.Errorf(\"no such node %s\", vol.NodeID)\n\t\t}\n\t\tif ok := checker.Feasible(node); !ok {\n\t\t\treturn nil, fmt.Errorf(\"node %s is not feasible for volume\", vol.NodeID)\n\t\t}\n\n\t\tvol.NodePool = node.NodePool\n\t\treturn node, nil\n\t}\n\n\tpoolFilterFn, err := v.enterpriseNodePoolFilter(snap, vol)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\tvar iter memdb.ResultIterator\n\tif vol.NodePool != \"\" {\n\t\tif !poolFilterFn(vol.NodePool) {\n\t\t\treturn nil, fmt.Errorf(\"namespace %q does not allow volumes to use node pool %q\",\n\t\t\t\tvol.Namespace, vol.NodePool)\n\t\t}\n\t\titer, err = snap.NodesByNodePool(nil, vol.NodePool)","sourceCodeStart":539,"sourceCodeEnd":575,"githubUrl":"https://github.com/hashicorp/nomad/blob/482b49bf1aec006f089bcfc7e632d8f6ac303e5e/nomad/host_volume_endpoint.go#L539-L575","documentation":"When a NodeID is given, the node must satisfy the volume's constraints — including an implicit constraint that the node runs a host-volume plugin with the volume's PluginID (attr.plugins.host_volume.<plugin>.version is_set) plus any user constraints. If checker.Feasible(node) fails, Create is rejected with this message.","triggerScenarios":"Creating a host volume pinned to a node that lacks the CSI/host-volume plugin driver, runs an incompatible plugin version, or fails an explicit constraint in vol.Constraints (e.g. datacenter, meta labels, OS).","commonSituations":"Plugin not started on that client or plugin_id typo; wrong plugin version installed; constraint referencing node meta attributes that the target node doesn't have; volume spec copied from another node with different attributes.","solutions":["Verify the host-volume plugin is running on the target node and its plugin_id matches the volume's PluginID (`nomad node status <id>` shows attributes).","Remove or relax the constraints on the volume that the node cannot satisfy.","Omit NodeID and let placement find a feasible node automatically."],"exampleFix":"// before\nhv := &api.HostVolume{ PluginID: \"docker-plugin\", NodeID: nodeId, Constraints: [{\"${node.datacenter}\", \"=\", \"dc2\"}] }\n// after — node is in dc1\nhv := &api.HostVolume{ PluginID: \"docker-plugin\", NodeID: nodeId }","handlingStrategy":"validation","validationCode":"node, _, err := client.Nodes().Info(vol.NodeID, nil)\nif err != nil { return err }\nattr, ok := node.Attributes[fmt.Sprintf(\"plugins.host_volume.%s.version\", vol.PluginID)]\nif !ok {\n    return fmt.Errorf(\"node %s lacks host_volume plugin %q\", vol.NodeID, vol.PluginID)\n}","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Confirm the host-volume plugin is running on pinned nodes before creating volumes.","Match plugin_id exactly against the client's plugin configuration.","Check volume constraints against node attributes/datacenter before pinning."],"tags":["nomad","host-volumes","constraints","placement"],"backgroundTag":"constraint-not-satisfied","analyzedSha":"482b49bf1aec006f089bcfc7e632d8f6ac303e5e","analyzedAt":"2026-09-04T07:54:14.808Z","contentChangedAt":"2026-09-04T07:54:14.808Z","schemaVersion":2},"datasetVersion":"2026-09-08T10:18:20.063Z"}