[ClusterLabs] Antw: Resource not starting correctly II

Ulrich Windl Ulrich.Windl at rz.uni-regensburg.de
Tue Apr 16 02:21:37 EDT 2019


>>> JCA <1.41421 at gmail.com> schrieb am 15.04.2019 um 23:30 in Nachricht
<CAFy1yb0w1twHyT_P7NMnapU3q9VvK7GxQGD57HdF-koaru9ROg at mail.gmail.com>:
> Well, I remain puzzled. I added a statement to the end of my script in
> order to capture its return value. Much to my surprise, when I create the
> associated resource (as described in my previous post)  myapp-script gets
> invoked four times in node one (where the resource is created) and two in
> node two. Just as intriguing, the return value in one is, for each instance
> 
> OCF_NOT_RUNNING
> OCF_SUCCESS
> OCF_SUCCESS
> OCF_NOT_RUNNING

It may be help ful to log "$1" (action) together with the exit status...

> 
> while in node two I get
> 
> OCF_NOT_RUNNING
> OCF_SUCCESS
> 
> And now things work, as can be seen in the output from pcs status:
> 
> Cluster name: MyCluster
> Stack: corosync
> Current DC: two (version 1.1.19-8.el7_6.4-c3c624ea3d) - partition with
> quorum
> Last updated: Mon Apr 15 15:21:08 2019
> Last change: Mon Apr 15 15:20:47 2019 by root via cibadmin on one
> 
> 2 nodes configured
> 1 resource configured
> 
> Online: [ one two ]
> 
> Full list of resources:
> 
>  ClusterMyApp (ocf::myapp:myapp-script): Started one
> 
> Daemon Status:
>   corosync: active/disabled
>   pacemaker: active/disabled
>   pcsd: active/enabled
> 
> 
> Can anybody clarify what is going on? And how to guarantee that, assuming
> that my app starts correctly, the creation resource will predictably
> succeed?






More information about the Users mailing list