Glusterfs on top of linux zfs

Glusterfs on top of linux zfs

Glusterfs on top of linux zfs

img src: Link GNU Affero General Public License, version 3.

Did you ever wanted to know how to setup Glusterfs on top of linux zfs or other filesystems? In this article i will describe this in a few easy steps based on my earlier mentioned how to about zfs on linux.

 

First of all let me tell you something about where to use glusterfs

Let’s say you need a heavy write intense network share in a clustered web environment where multiple web server instances needs to get access to same directory, glusterfs would be a good solution to handle that. If you need a network share for reading small files you should prefer use nfs instead of using glusterfs native client.

In my how-to we setup the glusterfs-server on a single instance.

Prerequisites:

  • ZFS on Openstack or ZFS on Proxmox
  • glusterfs-server package for the server
  • glusterfs-client for all the clients
  • nfs-common on clients if you want to use glusterfs nfs shares

 

Install the necessary packages:

On the Server:

aptitude install glusterfs-server

On all your Clients:

aptitude install glusterfs-client

Optional if you want to use glusterfs with nfs:

aptitude install nfs-common


Optional: Only for ZFS Users. You need to create a new filesystem on your zfs storage pool like this, or use an existing one.

zfs create storage/images

 

Create your first Volume on glusterfs server

gluster volume create images 192.168.1.1:/storage/images
gluster volume start images

Check your gluster volume status

gluster volume status

 

Mount your created Volumes on the glusterfs clients

Modify your /etc/fstab in your prefered editor and enter following:

192.168.1.1:/images /storage glusterfs defaults,_netdev 0 0

or optional use nfs for glusterfs mounting:

192.168.1.1:/images /storage nfs defaults,_netdev 0 0

 

After saving type:

mount -a

And that’s it!

Rating: 5.0/5. From 1 vote.
Please wait...
Jules

Jules

Jules is the owner and author of ISPIRE.ME. He's a Linux System Engineer, Tech fanatic and an Open Source fan.

You may also like...

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.