Search code examples
kubernetesstorageopenebs

Where can I find the directories and files stored on my host(s) by OpenEBS?


I have installed OpenEBS with replica count 3 in a 3-node k8s cluster. I need to find where the files are being stored.


Solution

  • The location of the data depends on the type of the OpenEBS Volume. The device location/path can be determined by querying the storage pool information. It is either hostPath (for jiva volumes) or a device path (for cstor volumes).

    OpenEBS Jiva Volumes: The path can be also obtained by describing the replica pod/deployment.

    kubectl get deployment <volumename-name>-rep -n <pvc-namespace> -o yaml
    

    OpenEBS cStor Volumes: The path depends on the disks used by the Storage Pool. Find the disks associated with the cStor Storage Pool and then get the device information by obtaining the details on the "disk" object. Commands to be used:

    kubectl get storageclass <pvc-storage-class> -o yaml
    #get the storage pool claim name 
    kubectl get storagepool <storage-pool-claim-name>-<uid> -o yaml
    #get disk name under disk list
    kubectl get disk <disk-name> -o yaml