nomad icon indicating copy to clipboard operation
nomad copied to clipboard

CSI plugin is not deregistered when a new version of the plugin job changes the CSI plugin id

Open Jamesits opened this issue 3 months ago • 1 comments

Nomad version

1.7.6

Operating system and Environment details

Ubuntu 22.04

Issue

When a CSI job has a new version with a different CSI plugin id, Nomad is unable to unregister the storage plugin with the old id cleanly.

Reproduction steps

  1. Submit a working CSI storage plugin job
  2. Submit a new version of the job with job.group[].task[].csi_plugin.id changed directly

Expected Result

Web UI -> Storage -> Plugins shows only the new id

Actual Result

Web UI -> Storage -> Plugins have both the old id and new id showing up, and you have no way to remove the old one

I've tried changing the CSI plugin id back, stopping all the plugin jobs, purging the related jobs completely. It worked for one cluster, but does not on another cluster of the same configuration (created with near identical Terraform plans). This might be caused by an unknown issue.

Screenshot from 2024-03-26 17-41-04

Job file (if appropriate)

N/A

Nomad Server logs (if appropriate)

N/A

Nomad Client logs (if appropriate)

N/A

Related https://github.com/hashicorp/nomad/issues/7306

Jamesits avatar Mar 26 '24 09:03 Jamesits

Hi @Jamesits and thanks for raising this issue. It looks like we are not correctly handling the ID update, to perform destructive actions on the original CSI ID. I'll add this to our roadmap.

jrasell avatar Apr 02 '24 09:04 jrasell