GlusterFS is an open source, distributed file system capable of scaling to several petabytes (actually, 72 brontobytes!) and handling thousands of clients. GlusterFS clusters together storage building blocks over Infiniband RDMA or TCP/IP interconnect, aggregating disk and memory resources and managing data in a single global namespace. GlusterFS is based on a stackable user space design and can deliver exceptional performance for diverse workloads.
GlusterFS Tools
Installation and usage is simplified with the new release of glusterfs-tools, refer this blog for more details.
From Gluster website
Gluster CLI has limited features to view and filter the volume info. I started a small project to enhance Gluster CLI for personal use. As of now it consists of a tool to list Gluster volumes in tabular format. Other intersesting features includes filtering the output based on name, type, status, bricks etc.
Clone the project(I cloned it to /home/aravinda/sandbox/
)
cd /home/aravinda/sandbox
git clone https://github.com/aravindavk/glusterfs-tools.git
Create a shellscript to call gftools /usr/local/bin/gfvolumes
#!/bin/bash
python /home/aravinda/sandbox/glusterfs-tools/gftools/volumes.py "$@"
Make gfvolumes executable
chmod +x /usr/local/bin/gfvolumes
Now we can run sudo gfvolumes
to see the list of glusterfs volumes. Type gfvolumes --help
for help.
Additionally it can output filtered details in JSON format.
We can easily import this in our python script.
#!/usr/bin/python
from gftools import volumes
gfvols = volumes.GfVolumes()
ok, vols = gfvols.get(name='^gv[0-9]$', status='down') # Various filters available
if ok:
# Do action
Note: root permission is required to run gluster command, so run gfvolumes as root(sudo gfvolumes
)
Future plans:
-
Adding more filters
-
Adding more admin tools
-
Creating RPM/DEB packages
C & S Welcome.
About Aravinda Vishwanathapura
Co-Founder & CTO at Kadalu Technologies, Creator of Sanka, Creator of Chitra, GlusterFS core team member, Maintainer of Kadalu Storage