[Pacemaker] configuring pingd and hbaping with CentOS 5's heartbeat rpms.

Lundgren, Andrew Andrew.Lundgren at Level3.com
Thu Jun 18 18:45:29 EDT 2009


> 
> Are you sure that the attribute is called "pingd"? You can check
> in the CIB status section what is being set.
> 
Thanks for your reply

Based on your input I looked at the output in the cibstatus.  To make sure I was looking in the right place, I downed the interface, did a query and then brought it back up and did another query.  The following is the output:

-- down if--
#cibadmin -Q > 6
-- up if
#cibadmin -Q > 7
# diff 6 7
--snip--
<              <nvpair id="status-3c4db0b2-54e9-4dc5-9b9e-493b90866836-pingd-gateway" name="pingd-gateway" value="0"/>
---
>              <nvpair id="status-3c4db0b2-54e9-4dc5-9b9e-493b90866836-pingd-gateway" name="pingd-gateway" value="1000"/>

So based on that I think the attribute is called pingd-gateway.  No?

I went back in and changed my XML to look like the following:

...

       <rsc_location rsc="Filesystem_mount" id="MDS-no-connectivity">
         <rule score="-INFINITY" id="pingd-exclude-rule">
           <expression operation="not_defined" id="pingd-exclude" attribute="pingd-gateway"/>
         </rule>
       </rsc_location>
       <rsc_location id="rsc_location_Filesystem_mount" rsc="Filesystem_mount">
         <rule id="prefered_location_Filesystem_mount" score="100">
           <expression attribute="#uname" id="prefered_location_Filesystem_mount_expr" operation="eq" value="hostA"/>
         </rule>
       </rsc_location>

The following remain unchanged:

       <primitive class="ocf" provider="heartbeat" type="Filesystem" id="Filesystem_mount">
         <operations>
           <op name="monitor" timeout="60s" start_delay="0" disabled="false" role="Started" id="Filesystem_mount_mon" interval="120s" on_fail="restart"/>
         </operations>
         <instance_attributes id="Filesystem_mount_inst_attr">
           <attributes>
             <nvpair id="Filesystem_mount_attr_0" name="device" value="/dev/ExHwRaid10VolGroup/mdt"/>
             <nvpair id="Filesystem_mount_attr_1" name="directory" value="/mdt"/>
             <nvpair id="Filesystem_mount_attr_2" name="fstype" value="ext3"/>
           </attributes>
         </instance_attribues>
         <meta_attributes id="Filesystem_mount_meta_attrs">
           <attributes>
             <nvpair id="Filesystem_mount_metaattr_resource_stickiness" name="resource_stickiness" value="INFINITY"/>
             <nvpair id="Filesystem_mount_metaattr_description" name="description" value="MDT/MGS"/>
             <nvpair id="Filesystem_mount_metaattr_target_role" name="target_role" value="started"/>
           </attributes>
         </meta_attributes>
       </primitive>

...

       <clone id="pingd-clone">
         <primitive id="pingd" provider="heartbeat" class="ocf" type="pingd">
           <instance_attributes id="pingd-attrs">
             <attributes>
               <nvpair id="pingd-name" name="name" value="pingd-gateway"/>
               <nvpair id="pingd-dampen" name="dampen" value="5s"/>
               <nvpair id="pingd-multiplier" name="multiplier" value="1000"/>
               <nvpair id="pingd-hosts" name="host_list" value="192.168.1.1"/>
             </attributes>
           </instance_attributes>
         </primitive>
       </clone>
...

When I start and stop the interface, the status change is detected and recorded, but my resource still doesn't move.

I feel like I am missing the connection between the ping and the resource, but I don't know what is missing.  The constraint looks correct to me.

Thank you.

--
Andrew






More information about the Pacemaker mailing list