[Pacemaker] ocf_is_probe() problem on debian

Tom Weber l_pacemaker at mail2news.4t2.com
Mon Feb 15 11:46:28 UTC 2010


Hello,

the setup:
debian lenny based pacemaker cluster.
these packages from http://people.debian.org/~madkiss/ha

cluster-agents     1:1.0.2-1~bpo50+1
cluster-glue       1.0.3-1~bpo50+1
pacemaker          1.0.7+hg20100203-1~bpo50+1
libheartbeat2      1:3.0.2-1~bpo50+1
corosync           1.2.0-1~bpo50+1
libcorosync4       1.2.0-1~bpo50+1     

I'm using ocf::heartbeat:IPaddr2 and ocf::heartbeat:Route in a resource
Group. The IPaddr2 defines the interface for which i want to set up the
route.
During startup of the resource Group, the probe of the Route Ressource
fails with OCF_ERR_INSTALLED.

Digging into the shell scripts i found in
/usr/lib/ocf/resource.d/heartbeat/.ocf-shellfuncs:
~line 355 

# returns true if the CRM is currently running a probe. A probe is
# defined as a monitor operation with a monitoring interval of zero.
ocf_is_probe() {
    [ "$__OCF_ACTION" = "monitor" -a "$OCF_RESKEY_CRM_meta_interval" = 0 ]
}

The problem seems to be that during a probe OCF_RESKEY_CRM_meta_interval
is not set at all / empty, so ocf_is_probe() always fails.

According to the comment in the source something seems to not setup the
environment correctly. Maybe it's just combination of packages in the
repository.

As this is my first contact with pacemaker I've got plenty other
interesting stuff to learn, so i first uglyfixed this by adding 
test -z "$OCF_RESKEY_CRM_meta_interval" && OCF_RESKEY_CRM_meta_interval=0
to the Route agent. Later on another agent failed with the same problem,
so i moved this into ocf_is_probe() - which is for sure not the correct
way and place to fix this.

  Tom







More information about the Pacemaker mailing list