I am using rancher v2.5.7 on a CentOS 7 server, in this Rancher I have several clusters added with vSphere.
In one of these clusters I am trying to create a workload with a vsphere volume following the documentation: https://rancher.com/docs/rancher/v2.5/en/cluster-admin/volumes-and-storage/examples/vsphere/ /
-
First I go to the global view and open the cluster where I want to provide vSphere storage:
-
In the main menu of the cluster I select Storage → Storage Classes:
-
I click on add class inside Storage Classes:
-
I put a name to the Storage Class and in the Provisioner I put VMWare vSphere Volume:
-
The other options of the Storage Class are by default:
-
I click on Save, I go to Projects / Namespaces and I go to my default project:
-
In my default project I go to Deploy:
-
I select the Workload Type of Stateful set of 1 pod:
-
I go to volumes and select Add a new persistent volume (claim):
-
I select Use a Storage Class to provision a new persistent volume and request for a 1 GiB Storage, then I click Define:
-
In the mount point I put /persistent:
-
I deploy the workload:
-
And the pod gives me the following error: 0/3 nodes are available: 3 pod has unbound immediate PersistentVolumeClaims
-
Now I get this error ‘Failed to provision volume with StorageClass “fast”: cloud provider not initialized properly’ when launching the following command ‘kubectl describe pvc pvcsc-vsan’:
How can I fix that?