Am Tuesday, 14. August 2007 16:54 schrieb James Oakley: > On Tuesday 14 August 2007 8:29 am, Andrew Beekhof wrote: > > I'm guessing that the resource failed to stop > > And since stonith is not enabled there is nothing we can do (since > > it's not safe to start it somewhere else while its still, potentially, > > active on the first node). > > Ah. I see that the stop failure is a special case. I was trying to induce a > start failure. I just tried again, renaming the cups config file instead of > the daemon binary so that the stop action would succeed. > > It still doesn't failover, though. > > > But thats just a guess since you didn't include logs or the complete CIB > > I have attached both this time. > > Thanks,
Hi,
we have no solution, but a problem that looks very similar:
We have a drbd master/slave resource and a resource group
including an IPAddr.
We want the resource group to run on the node that is drbd-master
and need these failover behaviours:
1. Master role moves (e.g. after stopping drbd on the Master node),
the group should follow.
2. If the group fails (e.g. after ifconfig bond0:0 down),
drbd Master and after that the resource group itself
should move to the other node.
With these colocation and order constraints:
<rsc_colocation id="group_on_drbd0" from="group" to_role="Master" to="ms_drbd"
score="INFINITY"/>
<rsc_colocation id="group_on_drbd1" from="ms_drbd" from_role="Stopped"
to="group" score="-INFINITY"/>
<rsc_colocation id="group_on_drbd2" from="ms_drbd" from_role="Slave"
to="group" score="-INFINITY"/>
<rsc_order id="drbd_promote" from="group" action="start" to="ms_drbd"
to_action="promote"/>
<rsc_order id="drbd_demote" from="ms_drbd" action="demote" to="group"
to_action="stop"/>
only behaviour 1. is achieved (in fact, the first colocation and the first
order rule are enough for that).
How do we achieve behaviour 2.? Do we need any rule with from="ms_drbd"
at all? You have none such rule in your cib.xml but if I understand right you
also expect the drbd Master to move in case of a failure of any other
resource, right?
Thanks for your help!
Klemens
--
Klemens Kittan
Systemadministrator
Uni-Potsdam, Inst. f. Informatik
August-Bebel-Str. 89
14482 Potsdam
Tel. : +49-331-977/3125
Fax. : +49-331-977/3122
eMail : [EMAIL PROTECTED]
gpg --recv-keys --keyserver wwwkeys.de.pgp.net 6EA09333
<cib admin_epoch="0" epoch="3" num_updates="1" generated="false" have_quorum="false" ignore_dtd="false" num_peers="0" cib-last-written="Mon Aug 13 13:38:29 2007" cib_feature_revision="1.3">
<configuration>
<crm_config>
<cluster_property_set id="cib-bootstrap-options">
<attributes>
<nvpair id="cib-bootstrap-options-symmetric-cluster" name="symmetric-cluster" value="true"/>
<nvpair id="cib-bootstrap-options-no_quorum-policy" name="no_quorum-policy" value="stop"/>
<nvpair id="cib-bootstrap-options-default-resource-stickiness" name="default-resource-stickiness" value="INFINITY"/>
<nvpair id="cib-bootstrap-options-default-resource-failure-stickiness" name="default-resource-failure-stickiness" value="-INFINITY"/>
<nvpair id="cib-bootstrap-options-stonith-enabled" name="stonith-enabled" value="false"/>
<nvpair id="cib-bootstrap-options-stonith-action" name="stonith-action" value="reboot"/>
<nvpair id="cib-bootstrap-options-stop-orphan-resources" name="stop-orphan-resources" value="true"/>
<nvpair id="cib-bootstrap-options-stop-orphan-actions" name="stop-orphan-actions" value="true"/>
<nvpair id="cib-bootstrap-options-remove-after-stop" name="remove-after-stop" value="false"/>
<nvpair id="cib-bootstrap-options-short-resource-names" name="short-resource-names" value="true"/>
<nvpair id="cib-bootstrap-options-transition-idle-timeout" name="transition-idle-timeout" value="5min"/>
<nvpair id="cib-bootstrap-options-default-action-timeout" name="default-action-timeout" value="5s"/>
<nvpair id="cib-bootstrap-options-is-managed-default" name="is-managed-default" value="true"/>
<nvpair name="last-lrm-refresh" id="cib-bootstrap-options-last-lrm-refresh" value="1187003772"/>
</attributes>
</cluster_property_set>
</crm_config>
<nodes>
<node id="356346cd-d590-454c-bf29-4b8427fb0a2c" uname="frigg" type="normal"/>
<node id="a7d30f67-3efd-4d20-8774-fd2b82566b2e" uname="odin" type="normal"/>
</nodes>
<resources>
<master_slave id="ms_drbd">
<meta_attributes id="ma_ms_drbd">
<attributes>
<nvpair id="ma_ms_drbd_0" name="clone_max" value="2"/>
<nvpair id="ma_ms_drbd_1" name="clone_node_max" value="1"/>
<nvpair id="ma_ms_drbd_2" name="master_max" value="1"/>
<nvpair id="ma_ms_drbd_3" name="master_node_max" value="1"/>
<nvpair id="ma_ms_drbd_4" name="notify" value="yes"/>
<nvpair id="ma_ms_drbd_5" name="globally_unique" value="false"/>
<nvpair id="ma_ms_drbd_6" name="target_role" value="Started"/>
</attributes>
</meta_attributes>
<primitive id="drbd0" class="ocf" provider="heartbeat" type="drbd">
<instance_attributes id="drbd0_ia">
<attributes>
<nvpair id="drbd0_ia_0" name="drbd_resource" value="r0"/>
</attributes>
</instance_attributes>
<operations>
<op id="drbd0_mon_0" name="monitor" interval="12s" timeout="5s"/>
<op id="drbd0_mon_1" name="monitor" interval="10s" timeout="5s" role="Master"/>
</operations>
</primitive>
</master_slave>
<group id="group">
<primitive id="IPaddr0" class="ocf" provider="heartbeat" type="IPaddr">
<instance_attributes id="IPaddr0_ia">
<attributes>
<nvpair id="IPaddr0_ia_0" name="ip" value="141.89.59.22"/>
<nvpair id="IPaddr0_ia_1" name="netmask" value="24"/>
<nvpair id="IPaddr0_ia_2" name="nic" value="bond0"/>
</attributes>
</instance_attributes>
<operations>
<op id="IPaddr0_mon" interval="5s" name="monitor" timeout="5s"/>
</operations>
</primitive>
<primitive id="MailTo" class="ocf" provider="heartbeat" type="MailTo">
<instance_attributes id="MailTo_ia">
<attributes>
<nvpair id="MailTo_ia_0" name="email" value="[EMAIL PROTECTED]"/>
</attributes>
</instance_attributes>
</primitive>
</group>
</resources>
<constraints>
<rsc_location id="location" rsc="ms_drbd">
<rule id="location_rule" score="-INFINITY">
<expression id="location_rule_0" attribute="#uname" operation="ne" value="odin"/>
<expression id="location_rule_1" attribute="#uname" operation="ne" value="frigg"/>
</rule>
</rsc_location>
<rsc_location id="connected" rsc="ms_drbd">
<rule id="connected_rule" score="-INFINITY" boolean_op="or">
<expression id="connected_rule_undefined" attribute="pingd" operation="not_defined"/>
<expression id="connected_rule_zero" attribute="pingd" operation="lte" value="0"/>
</rule>
</rsc_location>
<rsc_colocation id="group_on_drbd0" from="group" to_role="Master" to="ms_drbd" score="INFINITY"/>
<rsc_colocation id="group_on_drbd1" from="ms_drbd" from_role="Stopped" to="group" score="-INFINITY"/>
<rsc_colocation id="group_on_drbd2" from="ms_drbd" from_role="Slave" to="group" score="-INFINITY"/>
<rsc_order id="drbd_promote" from="group" action="start" to="ms_drbd" to_action="promote"/>
<rsc_order id="drbd_demote" from="ms_drbd" action="demote" to="group" to_action="stop"/>
</constraints>
</configuration>
</cib>
pgpDOhxgy4bLA.pgp
Description: PGP signature
_______________________________________________ Linux-HA mailing list [email protected] http://lists.linux-ha.org/mailman/listinfo/linux-ha See also: http://linux-ha.org/ReportingProblems
