-
Notifications
You must be signed in to change notification settings - Fork 54
NFS Ganesha share with disperse volume
Sachidananda Urs edited this page Jun 26, 2018
·
1 revision
A NFS share can be created on different volume types. This example shows how to create a NFS share on a disperse volume.
- name: Setup NFS Ganesha
hosts: servers
remote_user: root
gather_facts: false
vars:
gluster_features_ganesha_masternode: "{{ groups['servers'][0] }}"
gluster_features_ganesha_clusternodes: "{{ groups['servers'] }}"
# This has to be hostnames
gluster_features_ganesha_haname: ganesha-ha-13-apr
gluster_features_ganesha_volume: 'ganeshavol'
gluster_features_ganesha_hostnames: "server1,server2,server3"
gluster_features_ganesha_viplist: 10.70.44.121,10.70.44.122
# Variables for backendsetup
gluster_infra_stripe_unit_size: 128
gluster_infra_pvs: /dev/vdb,/dev/vdc
# Create a thin volume
gluster_infra_lv_logicalvols:
- { lvname: 'glusterstore_thinlv', lvsize: '500G' }
gluster_infra_mount_devices:
- { path: '/storage/ganesha', lv: glusterstore_thinlv }
# GlusterFS volume
gluster_cluster_hosts: "{{ groups['hosts'] }}"
gluster_cluster_volume: ganeshavol
gluster_cluster_disperse_count: 4
gluster_cluster_force: 'yes'
gluster_cluster_transport: 'tcp'
gluster_cluster_bricks: '/mnt/thinv/store'
roles:
- gluster.infra
- gluster.cluster
- gluster.features
The above playbook makes use of three roles: infra, cluster, and features for setting up backend, creating volume, and setting up NFS Ganesha respectively.
See gluster.cluster for setting up different types of volumes. And gluster.features for different variables and documentation on NFS Ganesha.