Hi All,
We confirmed it about negative setting of colocation.
It is colocation with with-rsc-role designation.
We checked it in the next procedure.
Step1) Start the first node. And we send cib.
============
Last updated: Wed Jun 27 22:58:15 2012
Stack: Heartbeat
Current DC: rh62-test1 (4a7c480c-ad95-4238-8506-7e5f75c551a4) - partition with
quorum
Version: 1.0.12-unknown
1 Nodes configured, unknown expected votes
2 Resources configured.
============
Online: [ rh62-test1 ]
vipCheck (ocf::pacemaker:Dummy): Started rh62-test1
Master/Slave Set: msPostgresql
Masters: [ rh62-test1 ]
Stopped: [ postgresql:1 ]
Node Attributes:
* Node rh62-test1:
+ master-postgresql:0 : 10
Migration summary:
* Node rh62-test1:
Step2) Start the second node next.
[root@rh62-test1 ~]# ptest -x pe-input-5 -VVV
ptest[29213]: 2012/06/27_23:30:43 notice: unpack_config: On loss of CCM Quorum:
Ignore
ptest[29213]: 2012/06/27_23:30:43 WARN: unpack_nodes: Blind faith: not fencing
unseen nodes
ptest[29213]: 2012/06/27_23:30:43 notice: native_print: vipCheck
(ocf::pacemaker:Dummy): Started rh62-test1
ptest[29213]: 2012/06/27_23:30:43 notice: clone_print: Master/Slave Set:
msPostgresql
ptest[29213]: 2012/06/27_23:30:43 notice: short_print: Masters: [
rh62-test1 ]
ptest[29213]: 2012/06/27_23:30:43 notice: short_print: Stopped: [
postgresql:1 ]
ptest[29213]: 2012/06/27_23:30:43 notice: RecurringOp: Start recurring monitor
(10s) for postgresql:0 on rh62-test2
ptest[29213]: 2012/06/27_23:30:43 notice: RecurringOp: Start recurring monitor
(9s) for postgresql:1 on rh62-test1
ptest[29213]: 2012/06/27_23:30:43 notice: RecurringOp: Start recurring monitor
(10s) for postgresql:0 on rh62-test2
ptest[29213]: 2012/06/27_23:30:43 notice: RecurringOp: Start recurring monitor
(9s) for postgresql:1 on rh62-test1
ptest[29213]: 2012/06/27_23:30:43 notice: LogActions: Leave resource vipCheck
(Started rh62-test1)
ptest[29213]: 2012/06/27_23:30:43 notice: LogActions: Demote postgresql:0
(Master -> Slave rh62-test1)
ptest[29213]: 2012/06/27_23:30:43 notice: LogActions: Stop resource
postgresql:0 (rh62-test1)
ptest[29213]: 2012/06/27_23:30:43 notice: LogActions: Start postgresql:0
(rh62-test2)
ptest[29213]: 2012/06/27_23:30:43 notice: LogActions: Start postgresql:1
(rh62-test1)
ptest[29213]: 2012/06/27_23:30:43 notice: LogActions: Promote postgresql:1
(Stopped -> Master rh62-test1)
However, as for the "postgresql:0" resource, it is done Demote.
And replaced with "postgresql:1" resource and am done Promote.
This replacement has a problem by useless movement.
And the cluster repeats Promote,Demote after this and does not constitute a
resource definitely.
Does it work definitely to set -INFINITY by with-rsc-role designation in
colocation?
Is it a mistake to appoint it in specifications?
<rsc_colocation id="rsc_colocation-7" rsc="msPostgresql"
rsc-role="Master" score="INFINITY" with-rsc="vipCheck"/>
<rsc_colocation id="rsc_colocation-8" rsc="vipCheck" score="-INFINITY"
with-rsc="msPostgresql" with-rsc-role="Slave"/>
<rsc_order first="vipCheck" first-action="start" id="rsc_order-7"
score="INFINITY" then="msPostgresql" then-action="promote"/>
Or is this a bug?
* I confirmed it in ptest of Pacemaker1.1.7, but the result was the same.
Best Regards,
Hideo Yamauchi.
<cib epoch="684" num_updates="5" admin_epoch="0" validate-with="pacemaker-1.0"
crm_feature_set="3.0.1" have-quorum="1"
dc-uuid="4a7c480c-ad95-4238-8506-7e5f75c551a4" cib-last-written="Wed Jun 27
23:01:23 2012">
<configuration>
<crm_config>
<cluster_property_set id="cib-bootstrap-options">
<nvpair id="cib-bootstrap-options-dc-version" name="dc-version"
value="1.0.12-unknown"/>
<nvpair id="cib-bootstrap-options-cluster-infrastructure"
name="cluster-infrastructure" value="Heartbeat"/>
<nvpair id="cib-bootstrap-options-no-quorum-policy"
name="no-quorum-policy" value="ignore"/>
<nvpair id="cib-bootstrap-options-stonith-enabled"
name="stonith-enabled" value="false"/>
<nvpair id="cib-bootstrap-options-startup-fencing"
name="startup-fencing" value="false"/>
<nvpair id="cib-bootstrap-options-stonith-timeout"
name="stonith-timeout" value="710s"/>
<nvpair id="cib-bootstrap-options-crmd-transition-delay"
name="crmd-transition-delay" value="2s"/>
</cluster_property_set>
</crm_config>
<nodes>
<node id="4a7c480c-ad95-4238-8506-7e5f75c551a4" uname="rh62-test1"
type="normal"/>
<node id="0790f60e-21ea-4a5f-bb22-46e694842903" uname="rh62-test2"
type="normal"/>
</nodes>
<resources>
<primitive class="ocf" id="vipCheck" provider="pacemaker" type="Dummy">
<instance_attributes id="vipCheck-instance_attributes"/>
<operations>
<op id="vipCheck-start-0s" interval="0s" name="start"
on-fail="restart" start-delay="4s" timeout="90s"/>
</operations>
</primitive>
<master id="msPostgresql">
<meta_attributes id="msPostgresql-meta_attributes">
<nvpair id="msPostgresql-meta_attributes-master-max"
name="master-max" value="1"/>
<nvpair id="msPostgresql-meta_attributes-master-node-max"
name="master-node-max" value="1"/>
<nvpair id="msPostgresql-meta_attributes-clone-max" name="clone-max"
value="2"/>
<nvpair id="msPostgresql-meta_attributes-clone-node-max"
name="clone-node-max" value="1"/>
<nvpair id="msPostgresql-meta_attributes-notify" name="notify"
value="true"/>
</meta_attributes>
<primitive class="ocf" id="postgresql" provider="pacemaker"
type="Stateful">
<instance_attributes id="postgresql-instance_attributes"/>
<operations>
<op id="postgresql-start-0s" interval="0s" name="start"
on-fail="restart" timeout="60s"/>
<op id="postgresql-monitor-10s" interval="10s" name="monitor"
on-fail="restart" timeout="60s"/>
<op id="postgresql-monitor-9s" interval="9s" name="monitor"
on-fail="restart" role="Master" timeout="60s"/>
<op id="postgresql-promote-0s" interval="0s" name="promote"
on-fail="restart" timeout="60s"/>
<op id="postgresql-demote-0s" interval="0s" name="demote"
on-fail="block" timeout="60s"/>
<op id="postgresql-stop-0s" interval="0s" name="stop"
on-fail="block" timeout="60s"/>
<op id="postgresql-notify-0s" interval="0s" name="notify"
timeout="60s"/>
</operations>
</primitive>
</master>
</resources>
<constraints>
<rsc_location id="rsc_location-1" rsc="msPostgresql">
<rule id="rsc_location-1-rule" role="master" score="200">
<expression attribute="#uname" id="rsc_location-1-expression"
operation="eq" value="rh62-test1"/>
</rule>
<rule id="rsc_location-1-rule-0" role="master" score="100">
<expression attribute="#uname" id="rsc_location-1-expression-0"
operation="eq" value="rh62-test2"/>
</rule>
</rsc_location>
<rsc_colocation id="rsc_colocation-7" rsc="msPostgresql"
rsc-role="Master" score="INFINITY" with-rsc="vipCheck"/>
<rsc_colocation id="rsc_colocation-8" rsc="vipCheck" score="-INFINITY"
with-rsc="msPostgresql" with-rsc-role="Slave"/>
<rsc_order first="vipCheck" first-action="start" id="rsc_order-7"
score="INFINITY" then="msPostgresql" then-action="promote"/>
</constraints>
<rsc_defaults>
<meta_attributes id="rsc-options">
<nvpair id="rsc-options-resource-stickiness" name="resource-stickiness"
value="INFINITY"/>
<nvpair id="rsc-options-migration-threshold" name="migration-threshold"
value="1"/>
</meta_attributes>
</rsc_defaults>
</configuration>
<status>
<node_state id="4a7c480c-ad95-4238-8506-7e5f75c551a4" uname="rh62-test1"
ha="active" in_ccm="true" crmd="online" join="member" expected="member"
crm-debug-origin="do_state_transition" shutdown="0">
<transient_attributes id="4a7c480c-ad95-4238-8506-7e5f75c551a4">
<instance_attributes id="status-4a7c480c-ad95-4238-8506-7e5f75c551a4">
<nvpair
id="status-4a7c480c-ad95-4238-8506-7e5f75c551a4-probe_complete"
name="probe_complete" value="true"/>
<nvpair
id="status-4a7c480c-ad95-4238-8506-7e5f75c551a4-master-postgresql:0"
name="master-postgresql:0" value="10"/>
<nvpair
id="status-4a7c480c-ad95-4238-8506-7e5f75c551a4-rh62-test2-eth1"
name="rh62-test2-eth1" value="up"/>
<nvpair
id="status-4a7c480c-ad95-4238-8506-7e5f75c551a4-rh62-test2-eth2"
name="rh62-test2-eth2" value="up"/>
</instance_attributes>
</transient_attributes>
<lrm id="4a7c480c-ad95-4238-8506-7e5f75c551a4">
<lrm_resources>
<lrm_resource id="vipCheck" type="Dummy" class="ocf"
provider="pacemaker">
<lrm_rsc_op id="vipCheck_monitor_0" operation="monitor"
crm-debug-origin="build_active_RAs" crm_feature_set="3.0.1"
transition-key="4:1:7:d50ad4d6-a80c-49e1-a1a1-5783c5c9a4a9"
transition-magic="0:7;4:1:7:d50ad4d6-a80c-49e1-a1a1-5783c5c9a4a9" call-id="2"
rc-code="7" op-status="0" interval="0" last-run="1340805477"
last-rc-change="1340805477" exec-time="10" queue-time="0"
op-digest="f2317cad3d54cec5d7d7aa7d0bf35cf8"/>
<lrm_rsc_op id="vipCheck_start_0" operation="start"
crm-debug-origin="build_active_RAs" crm_feature_set="3.0.1"
transition-key="6:1:0:d50ad4d6-a80c-49e1-a1a1-5783c5c9a4a9"
transition-magic="0:0;6:1:0:d50ad4d6-a80c-49e1-a1a1-5783c5c9a4a9" call-id="4"
rc-code="0" op-status="0" interval="0" last-run="1340805481"
last-rc-change="1340805481" exec-time="20" queue-time="0"
op-digest="f2317cad3d54cec5d7d7aa7d0bf35cf8" op-force-restart=" state "
op-restart-digest="f2317cad3d54cec5d7d7aa7d0bf35cf8"/>
</lrm_resource>
<lrm_resource id="postgresql:0" type="Stateful" class="ocf"
provider="pacemaker">
<lrm_rsc_op id="postgresql:0_monitor_0" operation="monitor"
crm-debug-origin="build_active_RAs" crm_feature_set="3.0.1"
transition-key="5:1:7:d50ad4d6-a80c-49e1-a1a1-5783c5c9a4a9"
transition-magic="0:7;5:1:7:d50ad4d6-a80c-49e1-a1a1-5783c5c9a4a9" call-id="3"
rc-code="7" op-status="0" interval="0" last-run="1340805477"
last-rc-change="1340805477" exec-time="10" queue-time="0"
op-digest="f2317cad3d54cec5d7d7aa7d0bf35cf8"/>
<lrm_rsc_op id="postgresql:0_start_0" operation="start"
crm-debug-origin="build_active_RAs" crm_feature_set="3.0.1"
transition-key="7:1:0:d50ad4d6-a80c-49e1-a1a1-5783c5c9a4a9"
transition-magic="0:0;7:1:0:d50ad4d6-a80c-49e1-a1a1-5783c5c9a4a9" call-id="5"
rc-code="0" op-status="0" interval="0" last-run="1340805477"
last-rc-change="1340805477" exec-time="20" queue-time="0"
op-digest="f2317cad3d54cec5d7d7aa7d0bf35cf8"/>
<lrm_rsc_op id="postgresql:0_promote_0" operation="promote"
crm-debug-origin="build_active_RAs" crm_feature_set="3.0.1"
transition-key="9:2:0:d50ad4d6-a80c-49e1-a1a1-5783c5c9a4a9"
transition-magic="0:0;9:2:0:d50ad4d6-a80c-49e1-a1a1-5783c5c9a4a9" call-id="8"
rc-code="0" op-status="0" interval="0" last-run="1340805483"
last-rc-change="1340805483" exec-time="20" queue-time="0"
op-digest="f2317cad3d54cec5d7d7aa7d0bf35cf8"/>
<lrm_rsc_op id="postgresql:0_post_notify_promote_0"
operation="notify" crm-debug-origin="build_active_RAs" crm_feature_set="3.0.1"
transition-key="46:2:0:d50ad4d6-a80c-49e1-a1a1-5783c5c9a4a9"
transition-magic="0:0;46:2:0:d50ad4d6-a80c-49e1-a1a1-5783c5c9a4a9" call-id="9"
rc-code="0" op-status="0" interval="0" last-run="1340805483"
last-rc-change="1340805483" exec-time="10" queue-time="0"
op-digest="f2317cad3d54cec5d7d7aa7d0bf35cf8"/>
<lrm_rsc_op id="postgresql:0_monitor_9000" operation="monitor"
crm-debug-origin="build_active_RAs" crm_feature_set="3.0.1"
transition-key="10:3:8:d50ad4d6-a80c-49e1-a1a1-5783c5c9a4a9"
transition-magic="0:8;10:3:8:d50ad4d6-a80c-49e1-a1a1-5783c5c9a4a9" call-id="10"
rc-code="8" op-status="0" interval="9000" last-rc-change="1340805485"
exec-time="20" queue-time="0" op-digest="873ed4f07792aa8ff18f3254244675ea"/>
</lrm_resource>
</lrm_resources>
</lrm>
</node_state>
<node_state id="0790f60e-21ea-4a5f-bb22-46e694842903" uname="rh62-test2"
ha="active" join="member" crm-debug-origin="do_state_transition" crmd="online"
shutdown="0" in_ccm="true" expected="member">
<lrm id="0790f60e-21ea-4a5f-bb22-46e694842903">
<lrm_resources/>
</lrm>
</node_state>
</status>
</cib>
_______________________________________________
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://bugs.clusterlabs.org