Openebs

From UVOO Tech Wiki
Revision as of 00:02, 19 June 2021 by Busk (talk | contribs)
Jump to navigation Jump to search

Ubuntu Microk8s

sudo systemctl status iscsid
# sudo systemctl enable --now iscsid
sudo systemctl status iscsid | grep inactive && sudo systemctl enable --now iscsid
sudo microk8s dns ingress rbac openebs
watch sudo microk8s kubectl get pod -n openebs
kubectl patch storageclass openebs-jiva-default -p '{"metadata": {"annotations":{"storageclass.kubernetes.io/is-default-class":"true"}}}'
kubectl patch storageclass microk8s-hostpath -p '{"metadata": {"annotations":{"storageclass.kubernetes.io/is-default-class":"false"}}}'
An example of creating a PersistentVolumeClaim utilizing the openebs-hostpath StorageClass


kind: PersistentVolumeClaim
apiVersion: v1
metadata:
  name: local-hostpath-pvc
spec:
  storageClassName: openebs-hostpath
  accessModes:
    - ReadWriteOnce
  resources:
    requests:
      storage: 5G



-----------------------

If you are planning to use OpenEBS with multi nodes, you can use the openebs-jiva-default StorageClass.
An example of creating a PersistentVolumeClaim utilizing the openebs-jiva-default StorageClass


kind: PersistentVolumeClaim
apiVersion: v1
metadata:
  name: jiva-volume-claim
spec:
  storageClassName: openebs-jiva-default
  accessModes:
    - ReadWriteOnce
  resources:
    requests:
      storage: 5G

Example