So I created a cluster using kubespray with vsphere as a storage plugin, it worked fine since my cluster is deployed on an ESXi hypervisor. Then I added new nodes(VMs) to the cluster, the new nodes do not run on vsphere, I deleted the storage plugin part in the “kubelet.env” file on those nodes so the kubelet can start normally.
The problems started to show when I used a storage class that is based on vsphere provider. When I create a PVC I have an error message saying that no “NO VM FOUND”
When I looked into the logs I found out that the vsphere plugin is trying to locate the new vms using theirs UUI, and since those VMs are not running on the vsphere cluster he cannot find them. and he fire an error and stop the pvc creation. even when I created the a vmdk manually and attached it to a PV the problem persiste.
is there a way to create a PVC using the vsphere storage class. with this setup ?
The vsphere csi driver, installed on each node, maps vmfs ‘disks’ to pods on the respective node, as k8s volumes. This can only work for nodes that are running as VMs on VMWare hosts that have access to the vsphere_datastore
In your case, it sounds like you’ve added a node that’s not running as a VM on the VMWare cluster that holds vsphere_datastore, therefore the vsphere CSI driver is a) not running on that node (you had to remove it from the kubelet config), and b) there’s no way for the node to reach the VMFS datastore because it’s outside the VMWare cluster.
You could work around this issue by using a different storage provider, such as NFS, Rook or OpenEBS