[Gluster-users] Fwd: Capturing config in a file

Carlos Capriotti capriotti.carlos at gmail.com
Mon Mar 31 13:55:57 UTC 2014


Adding the list, in order to have other people's opinions...

Today, the Monday after day light saving time change, I have only half a
neuron on duty, so, "reply to all" is a task next-to-impossible.

---------- Forwarded message ----------
From: Carlos Capriotti <capriotti.carlos at gmail.com>
Date: Mon, Mar 31, 2014 at 2:50 PM
Subject: Re: [Gluster-users] Capturing config in a file
To: Steve Thomas <sthomas at rpstechnologysolutions.co.uk>


Steve:

Capturing config on a file CAN be done, BUt, using that config is another
story.

What I did when I needed it:



gluster volume info <yourvolumenamehere> >> glusterconf.txt


next edit that file, trimming whatever unnecessary info it has, untill it
looks like this:



nfs.trusted-sync on
nfs.addr-namelookup off
nfs.nlm off
network.ping-timeout 20
performance.quick-read off
performance.read-ahead off
performance.io-cache off
performance.stat-prefetch off
cluster.eager-lock enable
network.remote-dio on
performance.cache-max-file-size 2MB
performance.cache-refresh-timeout 4
performance.cache-size 1GB
performance.write-behind-window-size 4MB
performance.io-thread-count 32






And then use this very simple script, using your glusterconf.txt file as a
parameter,  to duplicate your settings on your volume:

#!/bin/bash

while read line; do
        echo $line
        gluster volume set vmdata $line
done < $1

Of course there is a lot of room for improvement, but that gets the job
done.


Cheers,
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://supercolony.gluster.org/pipermail/gluster-users/attachments/20140331/579f0aff/attachment.html>


More information about the Gluster-users mailing list