Andrew Beekhof schrieb: > On Mon, Jun 8, 2009 at 8:51 AM, Patrick Roßbach > <[email protected]> wrote: > >> Hi, >> >> we are migrating from heartbeat v1 to v2 and also want to use pingd >> instead of ipfail. Our two cluster nodes are connected to redundant >> networks (two switches etc.) to communicate to the rest of the world. >> With v1 ipfail compared the number of successful pings of both cluster >> nodes to let the resources run on the node with best network quality. If >> one switch was faulty, both nodes had less, but equal pings and the >> resources were kept just where they are. In v2 pingd is running and >> configured as follows: >> >> ... >> <nvpair id="nvpair-63c37f35-716a-4541-ac79-aca7252d27d7" >> name="default-resource-stickiness" value="INFINITY"/> >> ... >> <rsc_location id="rsc_location_MyRcs" node="node0" rsc="MyRcs" >> score="1"/> >> <rsc_location rsc="MyRcs" id="rsc_location_MyRcs_pingd"> >> <rule boolean-op="or" id="rsc_location_MyRcs_pingd-rule" >> score-attribute="-INFINITY"> >> > > ^^^^ score="INFINITY" or score-attribute=pingd, but not what you have here > > >> <expression attribute="pingd" >> id="rsc_location_MyRcs_pingd-expression-0" operation="not_defined"/> >> <expression attribute="pingd" >> id="rsc_location_MyRcs_pingd-expression-1" operation="lt" value="2"/> >> > > ^^^^ this is the expression thats preventing you operating when both > sides can only see 1 of the ping nodes. > > What you need to do is reduce default-resource-stickiness to a large > number < INFINITY (INFINITY ::= 1,000,000) > > Then remove the above constraint and create these two: > > <rsc_location rsc="MyRcs" id="need-pingd"> > <!-- Resources are not permitted on nodes with zero connectivity --> > <rule id="rule-1" score="-INFINITY"> > <expression id="exp-1" attribute="pingd" operation="not_defined"/> > <rule> > </rsc_location> > <rsc_location rsc="MyRcs" id="best-pingd"> > <!-- Resources prefer nodes with the most connectivity > Just be sure to chose default-resource-stickiness such that > default-resource-stickiness + pingd < INFINITY > --> > <rule id="rule-2" score-attribute="pingd"> > <expression id="exp-2" attribute="pingd" operation="defined"/> > <rule> > </rsc_location> > > Hope that helps > It helped! Thank you very much. > _______________________________________________ > Linux-HA mailing list > [email protected] > http://lists.linux-ha.org/mailman/listinfo/linux-ha > See also: http://linux-ha.org/ReportingProblems >
_______________________________________________ Linux-HA mailing list [email protected] http://lists.linux-ha.org/mailman/listinfo/linux-ha See also: http://linux-ha.org/ReportingProblems
