<div dir="ltr">I spent many, many hours tackling the two-node problem and I had exactly the same symptoms (only able to get the resource to move if I moved it manually) until I did the following:<div><br></div><div>* Switch to DRBD 9 (added LINBIT repo because DRBD 8 is the default in the Ubuntu repo)</div><div>* Build a third diskless quorum arbitration node.</div><div><br></div><div>My DRBD configuration now looks like this:</div><div><br></div><div>





<p class="gmail-p1" style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-stretch:normal;line-height:normal;font-family:"Courier New";color:rgb(255,238,149);background-color:rgb(21,102,47)"><span class="gmail-s2" style="font-variant-ligatures:no-common-ligatures">hatst2:$ sudo drbdadm status</span></p>
<p class="gmail-p1" style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-stretch:normal;line-height:normal;font-family:"Courier New";color:rgb(255,238,149);background-color:rgb(21,102,47)"><span class="gmail-s2" style="font-variant-ligatures:no-common-ligatures">r0 role:</span><span class="gmail-s4" style="font-variant-ligatures:no-common-ligatures;color:rgb(86,219,233)"><b>Primary</b></span></p>
<p class="gmail-p2" style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-stretch:normal;line-height:normal;font-family:"Courier New";color:rgb(88,229,64);background-color:rgb(21,102,47)"><span class="gmail-s5" style="font-variant-ligatures:no-common-ligatures;color:rgb(255,238,149)"><span class="gmail-Apple-converted-space">  </span>disk:</span><span class="gmail-s2" style="font-variant-ligatures:no-common-ligatures"><b>UpToDate</b></span></p>
<p class="gmail-p1" style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-stretch:normal;line-height:normal;font-family:"Courier New";color:rgb(255,238,149);background-color:rgb(21,102,47)"><span class="gmail-s2" style="font-variant-ligatures:no-common-ligatures"><span class="gmail-Apple-converted-space">  </span>hatst1 role:Secondary</span></p>
<p class="gmail-p1" style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-stretch:normal;line-height:normal;font-family:"Courier New";color:rgb(255,238,149);background-color:rgb(21,102,47)"><span class="gmail-s2" style="font-variant-ligatures:no-common-ligatures"><span class="gmail-Apple-converted-space">    </span>peer-disk:</span><span class="gmail-s1" style="font-variant-ligatures:no-common-ligatures;color:rgb(88,229,64)">UpToDate</span></p>
<p class="gmail-p1" style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-stretch:normal;line-height:normal;font-family:"Courier New";color:rgb(255,238,149);background-color:rgb(21,102,47)"><span class="gmail-s2" style="font-variant-ligatures:no-common-ligatures"><span class="gmail-Apple-converted-space">  </span>hatst4 role:Secondary</span></p>
<p class="gmail-p1" style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-stretch:normal;line-height:normal;font-family:"Courier New";color:rgb(255,238,149);background-color:rgb(21,102,47)"><span class="gmail-s2" style="font-variant-ligatures:no-common-ligatures"><span class="gmail-Apple-converted-space">    </span>peer-disk:</span><span class="gmail-s1" style="font-variant-ligatures:no-common-ligatures;color:rgb(88,229,64)">Diskless</span></p></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Wed, Feb 26, 2020 at 6:59 AM Jaap Winius <<a href="mailto:jwinius@umrk.nl">jwinius@umrk.nl</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><br>
Hi folks,<br>
<br>
My 2-node test system has a DRBD resource that is configured as follows:<br>
<br>
~# pcs resource defaults resource-stickiness=100 ; \<br>
    pcs resource create drbd ocf:linbit:drbd drbd_resource=r0 \<br>
        op monitor interval=60s ; \<br>
    pcs resource master drbd master-max=1 master-node-max=1 \<br>
        clone-max=2 clone-node-max=1 notify=true<br>
<br>
The resource-stickiness setting is to prevent failbacks. I've got that  <br>
to work with NFS and and VIP resources, but not with DRBD. Moreover,  <br>
when configured as shown above, the DRBD master does not even want to  <br>
fail over when the node it started up on is shut down.<br>
<br>
Any idea what I'm missing or doing wrong?<br>
<br>
Thanks,<br>
<br>
Jaap<br>
<br>
PS -- I can only get it to fail over if I first move the DRBD resource  <br>
to the other node, which creates a "cli-prefer-drbd-master" location  <br>
constraint for that node, but then it ignores the resource-stickiness  <br>
setting and always performs the failbacks.<br>
<br>
PPS -- I'm using CentOS 7.7.1908, DRBD 9.10.0, Corosync 2.4.3,  <br>
Pacemaker 1.1.20 and PCS 0.9.167.<br>
<br>
_______________________________________________<br>
Manage your subscription:<br>
<a href="https://lists.clusterlabs.org/mailman/listinfo/users" rel="noreferrer" target="_blank">https://lists.clusterlabs.org/mailman/listinfo/users</a><br>
<br>
ClusterLabs home: <a href="https://www.clusterlabs.org/" rel="noreferrer" target="_blank">https://www.clusterlabs.org/</a><br>
<br>
</blockquote></div>