[Gluster-users] Setup with replica 3 for imagestorage

Ravishankar N ravishankar at redhat.com
Wed Jul 15 12:49:18 UTC 2015



On 07/15/2015 05:48 PM, Gregor Burck wrote:
> Hi,
>
> I still testing glusterfs for use for storing of images from virtual 
> machines.
>
> I start with 2 machines for stora and vm-host:
>
> two machines:
> gf001 and gf002
>
> Both:
> debian 8
> glusterfs 3.7
>
> /dev/sda - root
> /dev/sdb - /export/vbstore
>
> My volume info:
> root at gf001  :~# gluster volume info vbstore
>
> Volume Name: vbstore
> Type: Replicate
> Volume ID: 7bf8aa42-8fd9-4535-888d-dacea4f14a83
> Status: Started
> Number of Bricks: 1 x 2 = 2
> Transport-type: tcp
> Bricks:
> Brick1: gf001.mvz.ffm:/export/vbstore
> Brick2: gf002.mvz.ffm:/export/vbstore
>
>
>
> mounting on gf001:
> mount -t glusterfs gf001:/vbstore /import/vbstore
> or via fstab:
> gf001:/vbstore        /import/vbstore glusterfs defaults 0 0
>
> The same on gf002 with gf002 as server.
>
> Creating an virtualbox VM in /import/vbstore.
>
> Starting VM on gf001 OR gf002 work right.
>
> After I learned, that if I restart an server, the filesystem go 
> readonly I add an additional brick:
>
> gluster volume add-brick vbstore replica 3 edgf006:/export/vbstore
>
> and set following Options:
>
> cluster.quorum-count: 1
> cluster.server-quorum-type: server
> cluster.quorum-type: none
> network.remote-dio: enable
> cluster.eager-lock: enable
> performance.stat-prefetch: off
> performance.io-cache: off
> performance.read-ahead: off
> performance.quick-read: off
> performance.readdir-ahead: on
> cluster.server-quorum-ratio: 51
>
> When I restart gf004 or gf005 the virtualmachine got an error and made 
> filesystem readonly.
>
> A glusterfs volume heal vbstore info give this:
>
> Brick edgf004:/export/vbstore/
> Number of entries: 0
>
> Brick edgf005:/export/vbstore/
> /gftest/gftest.vdi - Possibly undergoing heal
>
> Number of entries: 1
>
> Brick edgf006:/export/vbstore/
> /gftest/gftest.vdi - Possibly undergoing heal
>
> Number of entries: 1
>
> My questions:
> 1. Which Options should I took for storing virtual images.


You can create a normal replica 3 volume and then use it for VM images, 
instead of doing an add brick (thus avoiding the need to heal the vm 
image file  to the newly added brick). client quorm 
(cluster.quorum-type) should be set to `auto`.
glusterfs 3.7 onwards has support for a special type of replica 3 
configuration called arbiter volumes where the disk space consumed is 
less than a conventional  replica 3 volume . It would be great if you 
can try that out for your VM images and provide some feedback! Details 
on arbiter volumes can be found here: 
https://github.com/gluster/glusterfs/blob/master/doc/features/afr-arbiter-volumes.md



> 2. How to reset all options, I think I've played a little bit to much.

gluster volume reset <VOLNAME> <option name>


Thanks,
Ravi


>
> Bye
>
> Gregor
>
> _______________________________________________
> Gluster-users mailing list
> Gluster-users at gluster.org
> http://www.gluster.org/mailman/listinfo/gluster-users



More information about the Gluster-users mailing list