[Pacemaker] RE : Service automatically restart after IP moving
CHAMLEY Stephane
Stephane.CHAMLEY at coe.int
Fri Jul 13 05:50:41 UTC 2012
Exactly, I also found it :/
I asked to stop making clones, but it's really not nice! I'll make a bug reporting.
Thank you
Stéphane.
________________________________________
De : Vadym Chepkov [vchepkov at gmail.com]
Date d'envoi : vendredi 13 juillet 2012 5:49
À : The Pacemaker cluster resource manager
Objet : Re: [Pacemaker] Service automatically restart after IP moving
On Jul 12, 2012, at 3:18 AM, CHAMLEY Stephane wrote:
> Ah, Thanx you ! :)
>
> But it is not working ... : (
I think it's a bug. I saw the same behavior in 1.0.12 as well. I ended up defining independent resources, not clone.
What's interesting though, if you stop ipv_test resource, the monclone will properly stop too, as expected.
Cheers,
Vadym
> I did this test configuration (see below) and then I made a shift in the resouce IP (crm resource migrate).
> Yet the process "ntp" is always the old date..
>
> CLI conf:
> ++++++++
> node $id="19838a79-4459-4e2d-864e-53b8c103f011" v-testweb02
> node $id="e7fe4f86-081a-4092-9d50-bcfbcfc02ae4" v-testweb01
> primitive ipv_test ocf:heartbeat:IPaddr \
> params ip="10.10.10.10" cidr_netmask="255.255.255.0" \
> meta migration-threshold="2" \
> op monitor interval="10s"
> primitive ntp lsb:ntp \
> op monitor interval="60s"
> clone monclone ntp \
> meta target-role="Started"
> order testorder inf: ipv_test monclone
> property $id="cib-bootstrap-options" \
> dc-version="1.0.9-74392a28b7f31d7ddc86689598bd23114f58978b" \
> cluster-infrastructure="Heartbeat" \
> stonith-enabled="false" \
> no-quorum-policy="ignore" \
> default-resource-stickiness="1" \
> last-lrm-refresh="1331635194"
>
>
> XML conf:
> +++++++++
> <?xml version="1.0" ?>
> <cib admin_epoch="0" cib-last-written="Thu Jul 12 09:15:43 2012" crm_feature_set="3.0.1" dc-uuid="19838a79-4459-4e2d-864e-53b8c103f011" epoch="111" have-quorum="1" num_updates="1" validate-with="pacemaker-1.0">
> <configuration>
> <crm_config>
> <cluster_property_set id="cib-bootstrap-options">
> <nvpair id="cib-bootstrap-options-dc-version" name="dc-version" value="1.0.9-74392a28b7f31d7ddc86689598bd23114f58978b"/>
> <nvpair id="cib-bootstrap-options-cluster-infrastructure" name="cluster-infrastructure" value="Heartbeat"/>
> <nvpair id="cib-bootstrap-options-stonith-enabled" name="stonith-enabled" value="false"/>
> <nvpair id="cib-bootstrap-options-no-quorum-policy" name="no-quorum-policy" value="ignore"/>
> <nvpair id="cib-bootstrap-options-default-resource-stickiness" name="default-resource-stickiness" value="1"/>
> <nvpair id="cib-bootstrap-options-last-lrm-refresh" name="last-lrm-refresh" value="1331635194"/>
> </cluster_property_set>
> </crm_config>
> <rsc_defaults/>
> <op_defaults/>
> <nodes>
> <node id="19838a79-4459-4e2d-864e-53b8c103f011" type="normal" uname="v-testweb02"/>
> <node id="e7fe4f86-081a-4092-9d50-bcfbcfc02ae4" type="normal" uname="v-testweb01"/>
> </nodes>
> <resources>
> <primitive class="ocf" id="ipv_test" provider="heartbeat" type="IPaddr">
> <instance_attributes id="ipv_test-instance_attributes">
> <nvpair id="ipv_test-instance_attributes-ip" name="ip" value="10.10.10.10"/>
> <nvpair id="ipv_test-instance_attributes-cidr_netmask" name="cidr_netmask" value="255.255.255.0"/>
> </instance_attributes>
> <meta_attributes id="ipv_test-meta_attributes">
> <nvpair id="ipv_test-meta_attributes-migration-threshold" name="migration-threshold" value="2"/>
> </meta_attributes>
> <operations>
> <op id="ipv_test-monitor-10s" interval="10s" name="monitor"/>
> </operations>
> </primitive>
> <clone id="monclone">
> <meta_attributes id="monclone-meta_attributes">
> <nvpair id="monclone-meta_attributes-target-role" name="target-role" value="Started"/>
> </meta_attributes>
> <primitive class="lsb" id="ntp" type="ntp">
> <operations>
> <op id="ntp-monitor-60s" interval="60s" name="monitor"/>
> </operations>
> </primitive>
> </clone>
> </resources>
> <constraints>
> <rsc_order first="ipv_test" id="testorder" score="INFINITY" then="monclone"/>
> </constraints>
> </configuration>
> </cib>
>
> -----Original Message-----
> From: David Vossel [mailto:dvossel at redhat.com]
> Sent: mercredi 11 juillet 2012 21:01
> To: The Pacemaker cluster resource manager
> Subject: Re: [Pacemaker] Service automatically restart after IP moving
>
>
>
> ----- Original Message -----
>> From: "CHAMLEY Stephane" <Stephane.CHAMLEY at coe.int>
>> To: "pacemaker at oss.clusterlabs.org" <pacemaker at oss.clusterlabs.org>
>> Sent: Wednesday, July 11, 2012 1:59:58 AM
>> Subject: Re: [Pacemaker] Service automatically restart after IP moving
>>
>>
>>
>>
>>
>> Nobody ? :S
>
> use an order constraint.
>
> http://www.clusterlabs.org/doc/en-US/Pacemaker/1.1/html/Pacemaker_Explained/s-resource-ordering.html
>
> "If the first resource is (re)started while the then resource is running, the then resource will be stopped and restarted."
>
> So if an ip is stopped and started somewhere else, the 'then' resource should restart. is that what you were looking for?
>
> _______________________________________________
> Pacemaker mailing list: Pacemaker at 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
>
> _______________________________________________
> Pacemaker mailing list: Pacemaker at 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
More information about the Pacemaker
mailing list