# Nutanix CSI Volume Driver

**URL:** <https://forums.suse.com/t/nutanix-csi-volume-driver/16957>\
**Category:** SUSE Rancher Prime\
**Created:** [March 27, 2020, 5:02pm UTC](https://forums.suse.com/t/nutanix-csi-volume-driver/16957 "2020-03-27T17:02:57Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![sike](https://avatars.discourse-cdn.com/v4/letter/s/5daacb/32.png) [@sike](https://forums.suse.com/u/sike)\
**Post date:** [March 27, 2020, 5:02pm UTC](https://forums.suse.com/t/nutanix-csi-volume-driver/16957/1 "2020-03-27T17:02:57Z")

</div>

Hi,

currently I am trying to install the [\> Nutanix CSI Volume Driver 1.1](https://github.com/nutanix/csi-plugin) on a Kubernetes cluster, which was provisionied by RKE. The underlying GuestOS is RancherOS.

On my woker nodes I installed the iSCSI package with the following commands:  
ros service enable open-iscsi  
ros service up open-iscsi

Also I have added /lib/modules to the extra\_binds of the kubelet and changed the volume paths of the ntnx-csi-node.yaml to /var/lib/kubelet/volumeplugins, /opt/rke/var/lib/kubelet/plugins/com.nutanix.csi/ and /opt/rke/var/lib/kubelet/

I can’t find any documentation about kubelet and two paths /var/lib/kubelet and /opt/rke/var/lib/kubelet. Maybe someone can explain the concept behind it?

The CSI provisioner and also the CSI node plugin pods are running. And I can create a PVC and the PV is created as expected, but it can’t be attached to the pod. I get the following error:

MountVolume.MountDevice failed for volume “pvc-1f686380-0639-4e85-92cf-462fdda7f5f4” : [kubernetes.io/csi:](http://kubernetes.io/csi:) attacher.MountDevice failed to create newCsiDriverClient: driver name com.nutanix.csi not found in the list of registered CSI drivers

Is there any documentation how I can add a custom provisioner to Rancher?

Best regards,  
sike

---

<div class="post-metadata">

**Author:** ![sike](https://avatars.discourse-cdn.com/v4/letter/s/5daacb/32.png) [@sike](https://forums.suse.com/u/sike)\
**Post date:** [March 30, 2020, 12:52pm UTC](https://forums.suse.com/t/nutanix-csi-volume-driver/16957/2 "2020-03-30T12:52:19Z")

</div>

In the meantime I solved this problem. Therefore I changed the volumes to the following:

- name: registration-dir  
hostPath:  
path: /opt/rke/var/lib/kubelet/plugins\_registry/  
type: Directory
- name: plugin-dir  
hostPath:  
path: /opt/rke/var/lib/kubelet/plugins/com.nutanix.csi/  
type: DirectoryOrCreate
- name: pods-mount-dir  
hostPath:  
path: /opt/rke/var/lib/kubelet/  
type: Directory

Additionally I had to change the DRIVER\_REG\_SOCK\_PATH environment variable of the driver-registrar container to /opt/rke/var/lib/kubelet/plugins/com.nutanix.csi/csi.sock.

But now I have a fundamental problem. The open-iscsi service is also bundled as container and therefore the iscsiadm script looks like the following:  
#!/bin/sh

exec system-docker run --rm --privileged   
–pid host   
–net host   
–ipc host   
-v /mnt:/mnt:shared   
-v /media:/media:shared   
-v /dev:/host/dev   
-v /run:/run   
-v /etc/iscsi/nodes/:/etc/iscsi/nodes/   
-v /etc/iscsi/send\_targets/:/etc/iscsi/send\_targets/   
iscsi-tools $(basename 0) @

So the csi-node-ntnx-plugin container can not use the script unless I mount the system-docker and the socket file. Is there any solution for this problem? Does nobody used the open-iscsi service before? What is the use case for this service?
