pcs cluster cib test_drbd
pcs -f test_drbd property set stonith-enabled=false
pcs -f test_drbd property set no-quorum-policy=stop
pcs -f test_drbd resource defaults resource-stickiness=200
pcs -f test_drbd resource create drbd_res ocf:linbit:drbd \
drbd_resource=www \
require_drbd_module_version_lt=10.0.0 \
op monitor role=Master interval=110 timeout=30 \
op monitor role=Slave interval=120 timeout=30 \
op start timeout=120 \
op stop timeout=60
pcs -f test_drbd resource promotable drbd_res \
master-max=1 master-node-max=1 \
clone-max=2 clone-node-max=1 \
notify=true
pcs -f test_drbd resource create mystore_FS Filesystem \
device="/dev/drbd0" \
directory="/wp-storage" \
fstype="ext4"
pcs -f test_drbd constraint colocation add mystore_FS with drbd_res-clone INFINITY with-rsc-role=Master
pcs -f test_drbd constraint order promote drbd_res-clone then start mystore_FS
pcs -f test_drbd resource create health_check ocf:heartbeat:anything binfile=/path/to/shellscript.sh op monitor interval=5s
pcs -f test_drbd constraint colocation add health_check with drbd_res-clone INFINITY with-rsc-role=Master
pcs -f test_drbd constraint order promote drbd_res-clone then start health_check
pcs -f test_drbd alert create id=drbd_cleanup_file description="Monitor DRBD events and perform post cleanup" path=/var/lib/pacemaker/drbd_cleanup.sh
pcs -f test_drbd alert recipient add drbd_cleanup_file id=logfile value=/var/log/pacemaker_drbd_file.log
pcs cluster cib-push test_drbd
{"html5":"htmlmixed","css":"css","javascript":"javascript","php":"php","python":"python","ruby":"ruby","lua":"text\/x-lua","bash":"text\/x-sh","go":"go","c":"text\/x-csrc","cpp":"text\/x-c++src","diff":"diff","latex":"stex","sql":"sql","xml":"xml","apl":"apl","asterisk":"asterisk","c_loadrunner":"text\/x-csrc","c_mac":"text\/x-csrc","coffeescript":"text\/x-coffeescript","csharp":"text\/x-csharp","d":"d","ecmascript":"javascript","erlang":"erlang","groovy":"text\/x-groovy","haskell":"text\/x-haskell","haxe":"text\/x-haxe","html4strict":"htmlmixed","java":"text\/x-java","java5":"text\/x-java","jquery":"javascript","mirc":"mirc","mysql":"sql","ocaml":"text\/x-ocaml","pascal":"text\/x-pascal","perl":"perl","perl6":"perl","plsql":"sql","properties":"text\/x-properties","q":"text\/x-q","scala":"scala","scheme":"text\/x-scheme","tcl":"text\/x-tcl","vb":"text\/x-vb","verilog":"text\/x-verilog","yaml":"text\/x-yaml","z80":"text\/x-z80"}