Mailing List Archive

Re: IPaddr local_start_script" fails or wrong usage?
Hi,

On Tue, Nov 01, 2011 at 12:25:54PM +0100, Bernd Helber wrote:
> Hi List.
>
> i use a IPaddr Ressource with local_start_script Value.
> I'm kind a wondered, cause if i trigger thoses scripts, from the Console
> it works like a charme.
>
> If i trigger it from the Cluster to failover, it to the other node.
> The Ressource cleanly fails over, but what makes me wonder, the script
> doesn't get triggered.
>
> SO it absolutely unclear to me why it's not triggerd.

Looking at the script, it is clear to me. It simply never gets
invoked. The code was removed at one point, but unfortunately the
parameters remained in the meta-data. It also means that nobody
tried to use this since 2006.

> Or may it be possible that the local_start_script value isn't usable for
> common Shell Scripts?
>
> My current issue, ist that i have to trigger this Script, cause i have to
> tell the Switches at my Weboster with Useranme an Password, that it's a
> regular failover, unfortunately i don't have an alternative, to this
> procedure.

Interesting. What kind of equipment is that?

Thanks,

Dejan

>
>
> primitive class="ocf" id="res_IPaddr_1" provider="heartbeat"
> type="IPaddr">
> <instance_attributes id="res_IPaddr_1-instance_attributes">
> <nvpair id="nvpair-res_IPaddr_1-local_start_script"
> name="local_start_script" value="/etc/start_clusterip.sh"/>
> <nvpair id="nvpair-res_IPaddr_1-ip" name="ip"
> value="xxx.xxx.xxx.xxx"/>
> <nvpair id="nvpair-res_IPaddr_1-nic" name="nic" value="eth0"/>
> <nvpair id="nvpair-res_IPaddr_1-cidr_netmask"
> name="cidr_netmask" value="255.255.255.255"/>
> <nvpair id="nvpair-res_IPaddr_1-broadcast" name="broadcast"
> value="xxx.xxx.xxx.xxx"/>
> <nvpair id="nvpair-res_IPaddr_1-iflabel" name="iflabel"
> value="FloatingIP"/>
> </instance_attributes>
> <operations id="res_IPaddr_1-operations">
> <op id="op-res_IPaddr_1-start" interval="0" name="start"
> timeout="20"/>
> <op id="op-res_IPaddr_1-stop" interval="0" name="stop"
> timeout="20"/>
> <op id="op-res_IPaddr_1-monitor" interval="5" name="monitor"
> start-delay="0" timeout="20"/>
> <op id="op-res_IPaddr_1-validate-all" interval="0"
> name="validate-all" timeout="20"/>
> </operations>
> <meta_attributes id="res_IPaddr_1-meta_attributes">
> <nvpair id="res_IPaddr_1-meta_attributes-target-role"
> name="target-role" value="started"/>
> <nvpair id="res_IPaddr_1-meta_attributes-priority"
> name="priority" value="10"/>
> <nvpair id="res_IPaddr_1-meta_attributes-allow-migrate"
> name="allow-migrate" value="true"/>
> <nvpair id="res_IPaddr_1-meta_attributes-failure-timeout"
> name="failure-timeout" value="60"/>
> <nvpair id="res_IPaddr_1-meta_attributes-is-managed"
> name="is-managed" value="true"/>
>
>
>
> h1906375:~ # crm_mon -1n
> ============
> Last updated: Tue Nov 1 11:23:45 2011
> Stack: openais
> Current DC: nodename1 - partition with quorum
> Version: 1.1.5-ecb6baaf7fc091b023d6d4ba7e0fce26d32cf5c8
> 2 Nodes configured, 2 expected votes
> 4 Resources configured.
> ============
>
> Node nodenmae1: online
> res_IPaddr_1 (ocf::heartbeat:IPaddr) Started
> rhel6vm (ocf::heartbeat:VirtualDomain) Started
> stonith:0 (stonith:external/ssh) Started
> Node nodename1: online
> stonith:1 (stonith:external/ssh) Started
> h1906375:~ #
>
>
>
> Tanks in advance.
>
>
>
>
> _______________________________________________
> 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

_______________________________________________
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
Re: IPaddr local_start_script" fails or wrong usage? [ In reply to ]
> Hi,
>
Hi Dejan,
thanks for the quick Response.

> On Tue, Nov 01, 2011 at 12:25:54PM +0100, Bernd Helber wrote:
> > Hi List.
> >
> > i use a IPaddr Ressource with local_start_script Value.
> > I'm kind a wondered, cause if i trigger thoses scripts, from the Console
> > it works like a charme.
> >
> > If i trigger it from the Cluster to failover, it to the other node.
> > The Ressource cleanly fails over, but what makes me wonder, the script
> > doesn't get triggered.
> >
> > SO it absolutely unclear to me why it's not triggerd.
>
> Looking at the script, it is clear to me. It simply never gets
> invoked. The code was removed at one point, but unfortunately the
> parameters remained in the meta-data. It also means that nobody
> tried to use this since 2006.
>
Thanks for Clarification, as i suspected, but i wasn't sure. Pacemaker isn't
my daily meal.


The issue is solved.

i checked out an old Version of the Agent from Github.
https://github.com/ClusterLabs/resource-
agents/blob/adb868da496127c7784f9a3afdf5ef404d61b317/heartbeat/IPaddr.in

Added this piece of Code at Line t Line 638

###################################################
#added local_start_script_value################
if [ ! -z "${OCF_RESKEY_local_start_script}" ]; then
if [ -x "${OCF_RESKEY_local_start_script}" ]; then
${OCF_RESKEY_local_start_script} $*
fi
fi
####################################################



> > My current issue, ist that i have to trigger this Script, cause i have to
> > tell the Switches at my Weboster with Useranme an Password, that it's a
> > regular failover, unfortunately i don't have an alternative, to this
> > procedure.
>
> Interesting. What kind of equipment is that?
>
Unfortunately i can't tell you what kind of equipment they use.

> Thanks,
>
Thank you too. :-)

> Dejan
>
Kind regards

Bernd



_______________________________________________
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
Re: IPaddr local_start_script" fails or wrong usage? [ In reply to ]
On Fri, Nov 04, 2011 at 02:32:07PM +0100, Bernd Helber wrote:
> > Hi,
> >
> Hi Dejan,
> thanks for the quick Response.
>
> > On Tue, Nov 01, 2011 at 12:25:54PM +0100, Bernd Helber wrote:
> > > Hi List.
> > >
> > > i use a IPaddr Ressource with local_start_script Value.
> > > I'm kind a wondered, cause if i trigger thoses scripts, from the Console
> > > it works like a charme.
> > >
> > > If i trigger it from the Cluster to failover, it to the other node.
> > > The Ressource cleanly fails over, but what makes me wonder, the script
> > > doesn't get triggered.
> > >
> > > SO it absolutely unclear to me why it's not triggerd.
> >
> > Looking at the script, it is clear to me. It simply never gets
> > invoked. The code was removed at one point, but unfortunately the
> > parameters remained in the meta-data. It also means that nobody
> > tried to use this since 2006.
> >
> Thanks for Clarification, as i suspected, but i wasn't sure. Pacemaker isn't
> my daily meal.
>
>
> The issue is solved.
>
> i checked out an old Version of the Agent from Github.
> https://github.com/ClusterLabs/resource-
> agents/blob/adb868da496127c7784f9a3afdf5ef404d61b317/heartbeat/IPaddr.in
>
> Added this piece of Code at Line t Line 638
>
> ###################################################
> #added local_start_script_value################
> if [ ! -z "${OCF_RESKEY_local_start_script}" ]; then
> if [ -x "${OCF_RESKEY_local_start_script}" ]; then
> ${OCF_RESKEY_local_start_script} $*
> fi
> fi
> ####################################################

OK. Added back the missing code. Don't like the feature
particularly, but if somebody wants to use it...

Thanks,

Dejan

> > > My current issue, ist that i have to trigger this Script, cause i have to
> > > tell the Switches at my Weboster with Useranme an Password, that it's a
> > > regular failover, unfortunately i don't have an alternative, to this
> > > procedure.
> >
> > Interesting. What kind of equipment is that?
> >
> Unfortunately i can't tell you what kind of equipment they use.
>
> > Thanks,
> >
> Thank you too. :-)
>
> > Dejan
> >
> Kind regards
>
> Bernd
>
>
>
> _______________________________________________
> 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

_______________________________________________
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
Re: IPaddr local_start_script" fails or wrong usage? [ In reply to ]
Hello Dejan,

If the LVS support is not there, then stop script part doesn't work. I
have added below piece of code to line 587, just before line beginning with
delete_route.

if [ ! -z "${OCF_RESKEY_local_stop_script}" ]; then
if [ -x "${OCF_RESKEY_local_stop_script}" ]; then
${OCF_RESKEY_local_stop_script} $*
fi
fi


I have tested it in my environment (Centos 6.2, Pacemaker 1.1.6) and it
works.

thanks,

huseyin


On Mon, Nov 7, 2011 at 5:50 PM, Dejan Muhamedagic <dejanmm@fastmail.fm>wrote:

> On Fri, Nov 04, 2011 at 02:32:07PM +0100, Bernd Helber wrote:
> > > Hi,
> > >
> > Hi Dejan,
> > thanks for the quick Response.
> >
> > > On Tue, Nov 01, 2011 at 12:25:54PM +0100, Bernd Helber wrote:
> > > > Hi List.
> > > >
> > > > i use a IPaddr Ressource with local_start_script Value.
> > > > I'm kind a wondered, cause if i trigger thoses scripts, from the
> Console
> > > > it works like a charme.
> > > >
> > > > If i trigger it from the Cluster to failover, it to the other node.
> > > > The Ressource cleanly fails over, but what makes me wonder, the
> script
> > > > doesn't get triggered.
> > > >
> > > > SO it absolutely unclear to me why it's not triggerd.
> > >
> > > Looking at the script, it is clear to me. It simply never gets
> > > invoked. The code was removed at one point, but unfortunately the
> > > parameters remained in the meta-data. It also means that nobody
> > > tried to use this since 2006.
> > >
> > Thanks for Clarification, as i suspected, but i wasn't sure. Pacemaker
> isn't
> > my daily meal.
> >
> >
> > The issue is solved.
> >
> > i checked out an old Version of the Agent from Github.
> > https://github.com/ClusterLabs/resource-
> > agents/blob/adb868da496127c7784f9a3afdf5ef404d61b317/heartbeat/IPaddr.in
> >
> > Added this piece of Code at Line t Line 638
> >
> > ###################################################
> > #added local_start_script_value################
> > if [ ! -z "${OCF_RESKEY_local_start_script}" ]; then
> > if [ -x "${OCF_RESKEY_local_start_script}" ]; then
> > ${OCF_RESKEY_local_start_script} $*
> > fi
> > fi
> > ####################################################
>
> OK. Added back the missing code. Don't like the feature
> particularly, but if somebody wants to use it...
>
> Thanks,
>
> Dejan
>
> > > > My current issue, ist that i have to trigger this Script, cause i
> have to
> > > > tell the Switches at my Weboster with Useranme an Password, that
> it's a
> > > > regular failover, unfortunately i don't have an alternative, to this
> > > > procedure.
> > >
> > > Interesting. What kind of equipment is that?
> > >
> > Unfortunately i can't tell you what kind of equipment they use.
> >
> > > Thanks,
> > >
> > Thank you too. :-)
> >
> > > Dejan
> > >
> > Kind regards
> >
> > Bernd
> >
> >
> >
> > _______________________________________________
> > 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
>
> _______________________________________________
> 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
>
Re: IPaddr local_start_script" fails or wrong usage? [ In reply to ]
On Fri, Apr 13, 2012 at 06:30:38PM +0300, Huseyin ALTUN wrote:
> Hello Dejan,
>
> If the LVS support is not there, then stop script part doesn't work. I
> have added below piece of code to line 587, just before line beginning with
> delete_route.
>
> if [ ! -z "${OCF_RESKEY_local_stop_script}" ]; then
> if [ -x "${OCF_RESKEY_local_stop_script}" ]; then
> ${OCF_RESKEY_local_stop_script} $*
> fi
> fi
>
>
> I have tested it in my environment (Centos 6.2, Pacemaker 1.1.6) and it
> works.

OK. The same code is upstream, but inserted elsewhere, i.e.
where it used to be in the first place before it got, probably
erroneously, removed. You can also check the github.com version.

Thanks,

Dejan

> thanks,
>
> huseyin
>
>
> On Mon, Nov 7, 2011 at 5:50 PM, Dejan Muhamedagic <dejanmm@fastmail.fm>wrote:
>
> > On Fri, Nov 04, 2011 at 02:32:07PM +0100, Bernd Helber wrote:
> > > > Hi,
> > > >
> > > Hi Dejan,
> > > thanks for the quick Response.
> > >
> > > > On Tue, Nov 01, 2011 at 12:25:54PM +0100, Bernd Helber wrote:
> > > > > Hi List.
> > > > >
> > > > > i use a IPaddr Ressource with local_start_script Value.
> > > > > I'm kind a wondered, cause if i trigger thoses scripts, from the
> > Console
> > > > > it works like a charme.
> > > > >
> > > > > If i trigger it from the Cluster to failover, it to the other node.
> > > > > The Ressource cleanly fails over, but what makes me wonder, the
> > script
> > > > > doesn't get triggered.
> > > > >
> > > > > SO it absolutely unclear to me why it's not triggerd.
> > > >
> > > > Looking at the script, it is clear to me. It simply never gets
> > > > invoked. The code was removed at one point, but unfortunately the
> > > > parameters remained in the meta-data. It also means that nobody
> > > > tried to use this since 2006.
> > > >
> > > Thanks for Clarification, as i suspected, but i wasn't sure. Pacemaker
> > isn't
> > > my daily meal.
> > >
> > >
> > > The issue is solved.
> > >
> > > i checked out an old Version of the Agent from Github.
> > > https://github.com/ClusterLabs/resource-
> > > agents/blob/adb868da496127c7784f9a3afdf5ef404d61b317/heartbeat/IPaddr.in
> > >
> > > Added this piece of Code at Line t Line 638
> > >
> > > ###################################################
> > > #added local_start_script_value################
> > > if [ ! -z "${OCF_RESKEY_local_start_script}" ]; then
> > > if [ -x "${OCF_RESKEY_local_start_script}" ]; then
> > > ${OCF_RESKEY_local_start_script} $*
> > > fi
> > > fi
> > > ####################################################
> >
> > OK. Added back the missing code. Don't like the feature
> > particularly, but if somebody wants to use it...
> >
> > Thanks,
> >
> > Dejan
> >
> > > > > My current issue, ist that i have to trigger this Script, cause i
> > have to
> > > > > tell the Switches at my Weboster with Useranme an Password, that
> > it's a
> > > > > regular failover, unfortunately i don't have an alternative, to this
> > > > > procedure.
> > > >
> > > > Interesting. What kind of equipment is that?
> > > >
> > > Unfortunately i can't tell you what kind of equipment they use.
> > >
> > > > Thanks,
> > > >
> > > Thank you too. :-)
> > >
> > > > Dejan
> > > >
> > > Kind regards
> > >
> > > Bernd
> > >
> > >
> > >
> > > _______________________________________________
> > > 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
> >
> > _______________________________________________
> > 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
> >

> _______________________________________________
> 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


_______________________________________________
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