Sent: Sat Nov 13 2010 04:20:56 GMT-0700 (Mountain Standard Time)
From: Andrew Beekhof <and...@beekhof.net>
To: The Pacemaker cluster resource manager <pacemaker@oss.clusterlabs.org>
Subject: Re: [Pacemaker] symmetric anti-collocation
On Fri, Nov 12, 2010 at 5:27 PM, Alan Jones <falanclus...@gmail.com> wrote:
On Thu, Nov 11, 2010 at 11:31 PM, Andrew Beekhof <and...@beekhof.net> wrote:
colocation X-Y -2: X Y
colocation Y-X -2: Y X
the second one is implied by the first and is therefore redundant
If only that were true!

It is. I know exactly how my code works in this regard.
More than likely a score of -2 is simply too low to have any effect.
I'm going to have to side with Alan here, his pasted statements are *NOT* redundant and also do *NOT* work. Please be a little more accepting that your code might have problems.

Exhibit A:
crm(live)# configure show
node nas01 \
       attributes standby="off"
node nas02 \
       attributes standby="off"
node nas03 \
       attributes standby="on"
primitive d1 ocf:pacemaker:Dummy
primitive d2 ocf:pacemaker:Dummy
colocation co1 -inf: d1 d2
colocation co2 -inf: d2 d1
property $id="cib-bootstrap-options" \
       dc-version="1.0.10-da7075976b5ff0bee71074385f8fd02f296ec8a3" \
       cluster-infrastructure="openais" \
       expected-quorum-votes="3" \
       stonith-enabled="false" \
       default-resource-stickiness="INFINITY"




crm(live)# status
============
Last updated: Mon Dec 20 21:03:49 2010
Stack: openais
Current DC: nas01 - partition with quorum
Version: 1.0.10-da7075976b5ff0bee71074385f8fd02f296ec8a3
3 Nodes configured, 3 expected votes
2 Resources configured.
============

Node nas03: standby
Online: [ nas01 nas02 ]

d1     (ocf::pacemaker:Dummy): Started nas01
d2     (ocf::pacemaker:Dummy): Started nas02




crm(live)# node standby nas02
crm(live)# status
============
Last updated: Mon Dec 20 21:04:14 2010
Stack: openais
Current DC: nas01 - partition with quorum
Version: 1.0.10-da7075976b5ff0bee71074385f8fd02f296ec8a3
3 Nodes configured, 3 expected votes
2 Resources configured.
============

Node nas02: standby
Node nas03: standby
Online: [ nas01 ]

d2     (ocf::pacemaker:Dummy): Started nas01


Notice how resource 'd1' got evicted from node 'nas01' and 'd2' replaced it. This would indicate that the 'co2' rule is being completely ignored. In fact if you delete the co2 rule, you get the exact same behavior. If you were to delete the co1 rule, and put 'nas02' in standby, d1 would have stayed running on 'nas01' instead of being replaced. This would indicate that the constraints are NOT redundant and NOT implied by eachother.

I'm not trying to be disrespectful or rude, its just that nobody is perfect.
_______________________________________________
Pacemaker mailing list: Pacemaker@oss.clusterlabs.org
http://oss.clusterlabs.org/mailman/listinfo/pacemaker

Project Home: http://www.clusterlabs.org
Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
Bugs: http://developerbugs.linux-foundation.org/enter_bug.cgi?product=Pacemaker

Reply via email to