On 06/13/2016 10:13 PM, Kevin THIERRY wrote: > Hello, > > I've been trying to setup pacemaker to get a HA system for a web > application but I am having a hard time with DRBD.
This worked for me: First, make sure your drbd resource is consistent/up to date and finished syncing. IME initial setup never worked wile it's syncing. I normally do mkfs on it then, too. Second, write it to file then push the whole file in one transaction. Otherwise it'll put drbd-master and drbd-fs on the different nodes and you'll have much fun unfscking that. pcs cluster cib drbd_cib pcs -f drbd_cib resource create drbd_storage ocf:linbit:drbd \ drbd_resource=raid op monitor interval=29s role="Master" \ op monitor interval=31s role="Slave" pcs -f drbd_cib resource master drbd_storage_sync drbd_storage \ master-max=1 master-node-max=1 clone-max=2 clone-node-max=1 notify=true pcs -f drbd_cib resource create drbd_filesystem Filesystem \ device="/dev/drbd0" directory="/raid" fstype="ext4" pcs -f drbd_cib constraint colocation add drbd_filesystem \ drbd_storage_sync INFINITY with-rsc-role=Master pcs -f drbd_cib constraint order promote drbd_storage_sync then \ start drbd_filesystem pcs -f drbd_cib constraint location drbd_filesystem prefers \ <YOUR PRIMARY NODE>=INFINITY pcs -f drbd_cib constraint colocation add drbd_filesystem floating_ip \ INFINITY pcs -f drbd_cib constraint order drbd_filesystem then floating_ip pcs cluster cib-push drbd_cib -- Dimitri Maziuk Programmer/sysadmin BioMagResBank, UW-Madison -- http://www.bmrb.wisc.edu
signature.asc
Description: OpenPGP digital signature
_______________________________________________ Users mailing list: Users@clusterlabs.org http://clusterlabs.org/mailman/listinfo/users Project Home: http://www.clusterlabs.org Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf Bugs: http://bugs.clusterlabs.org