Skip to content

Kubernetes Snapshots task failing #12867

@mKlaris

Description

@mKlaris

What happened?

Kubespray version v2.29.1
Task Kubernetes Snapshots | Add Cinder CSI Snapshot Class failing:


TASK [kubernetes_sigs.kubespray.kubernetes-apps/snapshots/snapshot-controller : Snapshot Controller | Apply Manifests] ******************************
ok: [km-upgrade-kubespray-2-control-1] => (item=rbac-snapshot-controller.yml)
ok: [km-upgrade-kubespray-2-control-1] => (item=snapshot-controller.yml)
Tuesday 13 January 2026  15:26:34 +0100 (0:00:02.631)       0:16:59.022 ******* 

TASK [kubernetes_sigs.kubespray.kubernetes-apps/snapshots/cinder-csi : Kubernetes Snapshots | Copy Cinder CSI Snapshot Class template] **************
changed: [km-upgrade-kubespray-2-control-1]
Tuesday 13 January 2026  15:26:35 +0100 (0:00:01.341)       0:17:00.363 ******* 

TASK [kubernetes_sigs.kubespray.kubernetes-apps/snapshots/cinder-csi : Kubernetes Snapshots | Add Cinder CSI Snapshot Class] ************************
fatal: [km-upgrade-kubespray-2-control-1]: FAILED! => {"changed": false, "msg": "error running kubectl (/usr/local/bin/kubectl apply --force --filename=/etc/kubernetes/cinder-csi-snapshot-class.yml) command (rc=1), out='', err='error: resource mapping not found for name: \"cinder-csi-snapshot\" namespace: \"\" from \"/etc/kubernetes/cinder-csi-snapshot-class.yml\": no matches for kind \"VolumeSnapshotClass\" in version \"snapshot.storage.k8s.io/v1beta1\"\nensure CRDs are installed first\n'"}

After the second attempt, the task passes.

What did you expect to happen?

Tasak should pass without error.

How can we reproduce it (as minimally and precisely as possible)?

To use Cinder CSI plugin to provision volumes set this value to true

Make sure to source in the openstack credentials

cinder_csi_enabled: true
cinder_csi_controller_replicas: 1
cinder_application_credential_name: xxxxxxxxxxxxxxxxx

OS

Ubuntu 24

Version of Ansible

ansible [core 2.17.14]

Version of Python

Python 3.12.3

Version of Kubespray (commit)

0c6a295

Network plugin used

calico

Full inventory with variables

https://gist.github.com/mKlaris/e30fde5ab326ac3e1601e784429f6673

Command used to invoke ansible

ansible-playbook -i ../ansible_inventory --user=ubuntu --become --become-user=root cluster.yml

Output of ansible run

https://gist.github.com/mKlaris/07b2fabf6834e7cfc008b74e42114254

Anything else we need to know

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    Ubuntu 24kind/bugCategorizes issue or PR as related to a bug.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions