{{tag>Brouillon Redhat Cluster FS Watchdog}}
= Cluster Pacemaker et Corosync partition GFS2
**Brouillon**
Voir :
* https://www.lisenet.com/2016/activeactive-high-availability-pacemaker-cluster-with-gfs2-and-iscsi-shared-storage-on-centos-7/
* [[http://www.linux-ha.org/wiki/SBD_Fencing|SBD Fencing watchdog softdog]]
* https://access.redhat.com/documentation/en-US/Red_Hat_Enterprise_Linux/6/html-single/Global_File_System_2/index.html
* [[https://en.wikipedia.org/wiki/GFS2|GFS2]]
* [[https://access.redhat.com/documentation/en-US/Red_Hat_Enterprise_Linux/7/html/Logical_Volume_Manager_Administration/LVM_administration.html|Cluster LVM / CLVM]]
* https://www.justinsilver.com/technology/linux/dual-primary-drbd-centos-6-gfs2-pacemaker/
* https://www.lisenet.com/2016/activepassive-mysql-high-availability-pacemaker-cluster-with-drbd-on-centos-7/
* https://www.morot.fr/cluster-debian-avec-drbd-et-gfs2-glfm-n135/
* https://chiliproject.tetaneutral.net/attachments/download/95/Tuto_DRBDetGFS2_sans_puppet.pdf
* http://connect.ed-diamond.com/GNU-Linux-Magazine/GLMF-135/Cluster-Debian-avec-DRBD-et-GFS2
Voir aussi :
* [[Pb Cluster LVM Err internal cluster locking initialisation failed]]
* [[https://en.wikipedia.org/wiki/OCFS2|OCFS2]]
/sbin/lvmconf --enable-cluster
ou
''/etc/lvm/lvm.conf''
locking_type = 3
sed -i -e "s/use_lvmetad \= 1/use_lvmetad \= 0/g" /etc/lvm/lvm.conf
systemctl stop lvm2-lvmetad.service
dracut -H -f /boot/initramfs-$(uname -r).img $(uname -r)
yum install rgmanager lvm2-cluster gfs2-utils
mkfs.gfs2 -p lock_dlm -t my_cluster:FSName -j 2 /dev/sdb
''-j 2'' \\
**2 journaux** car deux nœuds
Teste
mount -t gfs2 -o locktable="my_cluster:FSName" /dev/sdb /mnt/gfs/
pcs resource create dlm ocf:pacemaker:controld op monitor interval=30s on-fail=fence clone interleave=true ordered=true
pcs resource create clvmd ocf:heartbeat:clvm op monitor interval=30s on-fail=fence clone interleave=true ordered=true
pcs constraint order start dlm-clone then clvmd-clone
pcs constraint colocation add clvmd-clone with dlm-clone
pcs resource create clusterfs Filesystem device="/dev/vg_data/lv_test1" directory="/mnt/gfs" fstype="gfs2" "options=noatime" \
op monitor interval=10s on-fail=fence clone interleave=true
== Pb
[[Pb Cluster LVM Err internal cluster locking initialisation failed]]
=== Transport endpoint is not connected
mount: mount /dev/sdb on /mnt/gfs failed: Transport endpoint is not connected
Solution
systemctl start dlm
systemctl enable dlm