My guess is default stickiness being > 0.

>>> Alastair Basden <[email protected]> schrieb am 12.05.2021 um 11:58
in
Nachricht <alpine.DEB.2.22.394.2105121045380.3533@xps14>:
> Hi all,
> 
> Some help required with master/slave moving please...
> 
> I have set up a resource with:
> pcs resource create resourcedrbd ocf:linbit:drbd drbd_resource=disk1 op 
> monitor interval=60s
> pcs resource master resourcedrbdClne resourcedrbd master‑max=1 
> master‑node‑max=1 clone‑max=2 clone‑node‑max=1 notify=true
> pcs constraint location resourcedrbdClone prefers node1=100
> pcs constraint location resourcedrbdClone prefers node1=50
> pcs constraint location resourcedrbdClone avoids node3
> pcs constraint location resourcedrbdClone avoids node4
> pcs resource op add resourcedrbd monitor interval=61s role=Master
> pcs constraint location resourcedrbdClone rule role=master score=100 \#uname

> eq node1
> pcs constraint location resourcedrbdClone rule role=master score=50 \#uname

> eq node2
> 
> 
> If I put node1 into standby:
> pcs cluster standby node1
> It works, and moves the resource to node2.
> 
> However, when I bring it back:
> pcs cluster unstandby node1
> the resource remains on node2.
> 
> I want the resource to move back to node1.
> 
> What have I missed?  I thought the location rule should have sorted this 
> out.
> 
> I have also tried:
> pcs constraint rule add location‑resourcedrbdClone‑1 role=master score=100 
> \#uname eq node1
> (getting the location‑resourcedrbdClone‑1 ID from 
> /var/lib/pacemaker/cib/cib.xml ‑ though I guess there might be a better 
> way to get the ID through pcs)
> 
> And this doesn't help.
> 
> Thanks,
> Alastair.
> 
> _______________________________________________
> Manage your subscription:
> https://lists.clusterlabs.org/mailman/listinfo/users 
> 
> ClusterLabs home: https://www.clusterlabs.org/ 



_______________________________________________
Manage your subscription:
https://lists.clusterlabs.org/mailman/listinfo/users

ClusterLabs home: https://www.clusterlabs.org/

Reply via email to