# GlusterFS / BeeGFS on Rancher?

**URL:** <https://forums.suse.com/t/glusterfs-beegfs-on-rancher/6441>\
**Category:** Rancher 1.x\
**Created:** [May 23, 2017, 11:40am UTC](https://forums.suse.com/t/glusterfs-beegfs-on-rancher/6441 "2017-05-23T11:40:17Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![kirreen](https://sea2.discourse-cdn.com/flex022/user_avatar/forums.suse.com/kirreen/32/2479_2.png) [@kirreen](https://forums.suse.com/u/kirreen)\
**Post date:** [May 23, 2017, 11:40am UTC](https://forums.suse.com/t/glusterfs-beegfs-on-rancher/6441/1 "2017-05-23T11:40:17Z")

</div>

Hi! I’m trying to set up GlusterFS and BeeGFS on rancher for testing with a containerized web server stack. However, I can’t really find any information on setting them up on rancher, so how do I set them up? Any good docs to read?

---

<div class="post-metadata">

**Author:** ![laszlocloud](https://sea2.discourse-cdn.com/flex022/user_avatar/forums.suse.com/laszlocloud/32/2439_2.png) [@laszlocloud](https://forums.suse.com/u/laszlocloud)\
**Post date:** [May 23, 2017, 12:59pm UTC](https://forums.suse.com/t/glusterfs-beegfs-on-rancher/6441/2 "2017-05-23T12:59:59Z")

</div>

UPDATE: I wrote an extended version of this entry on my website: [https://laszlo.cloud/Rancher-Kubernetes-persistence-with-GlusterFS](https://laszlo.cloud/Rancher-Kubernetes-persistence-with-GlusterFS)

* * *

For Kubernetes or Cattle?

For Kube I just did it quickly.

I’d set gluster up on dedicated nodes first. With this one page guide, it’s like one hour to create a dummy cluster [http://gluster.readthedocs.io/en/latest/Quick-Start-Guide/Quickstart/](http://gluster.readthedocs.io/en/latest/Quick-Start-Guide/Quickstart/)

Then define the Persistent Volumes(PV) and the claims (PVC) just like on any Kube [http://docs.rancher.com/rancher/v1.6/en/kubernetes/storage/](http://docs.rancher.com/rancher/v1.6/en/kubernetes/storage/)

40-gluster-endpoint.yml  
apiVersion: v1  
kind: Endpoints  
metadata:  
name: glusterfs-cluster  
subsets:

- addresses:
  - ip: 10.0.1.102  
ports:
  - port: 1

- addresses:
  - ip: 10.0.1.103  
ports:
  - port: 1

40-gluster-svc.yml  
apiVersion: v1  
kind: Service  
metadata:  
name: glusterfs-cluster  
spec:  
ports:

- port: 1

40-persistent-volume.yml  
apiVersion: v1  
kind: PersistentVolume  
metadata:  
name: fileupload-vol  
labels:  
dev: dev  
spec:  
accessModes:

- ReadWriteMany  
capacity:  
storage: 500M  
glusterfs:  
endpoints: glusterfs-cluster  
path: gv0  
persistentVolumeReclaimPolicy: Recycle

40-pvc.yml  
apiVersion: v1  
kind: PersistentVolume  
metadata:  
name: fileupload-vol  
labels:  
dev: dev  
spec:  
accessModes:

- ReadWriteMany  
capacity:  
storage: 500M  
glusterfs:  
endpoints: glusterfs-cluster  
path: gv0  
persistentVolumeReclaimPolicy: Recycle

Then in your service yaml  
volumeMounts:  
- mountPath: /mnt/test  
name: dir-1  
volumes:  
- name: dir-1  
persistentVolumeClaim:  
claimName: file-upload-claim

---

<div class="post-metadata">

**Author:** ![kirreen](https://sea2.discourse-cdn.com/flex022/user_avatar/forums.suse.com/kirreen/32/2479_2.png) [@kirreen](https://forums.suse.com/u/kirreen)\
**Post date:** [May 23, 2017, 1:15pm UTC](https://forums.suse.com/t/glusterfs-beegfs-on-rancher/6441/3 "2017-05-23T13:15:07Z")

</div>

Thanks! Sorry for not specifying, I’ve mostly tested Cattle yet, but I guess it doesn’t matter too much. Great asnwer though and it will help me set up gluster on Kube at least!
