That's gotten me a little closer. I'm a bit of a newb when it comes to Pacemaker, on that note, I put the first group of your post (and changed the options to match the network I'm working on, I put this first configuration on the line with the existing group that I have setup.<div>
<br></div><div>That group has stuff like apache, smb, dhcp and some custom software that this existing group is managing. Should I create a new group? Or just keep it in the existing group?</div><div> </div><div>The second configuration entry for constraints is already populated with the contraints for the existing group. Should this configuration be pasted within the existing constraint (<constraint> </constraint>)?</div>
<div><br></div><div>Also, if all my assumptions are correct, then I ran a verify test and got this output:</div><div><br></div><div><div>/tmp/saved-cib.xml:159: element clone: Relax-NG validity error : Element group has extra content: clone</div>
<div>/tmp/saved-cib.xml:41: element group: Relax-NG validity error : Element resources has extra content: group</div><div>/tmp/saved-cib.xml:2: element configuration: Relax-NG validity error : Invalid sequence in interleave</div>
<div>/tmp/saved-cib.xml:2: element configuration: Relax-NG validity error : Element configuration failed to validate content</div><div>/tmp/saved-cib.xml:1: element cib: Relax-NG validity error : Element cib failed to validate content</div>
<div>crm_verify[4016]: 2012/10/17_12:16:10 ERROR: main: CIB did not pass DTD/schema validation</div><div>Errors found during check: config not valid</div><div><br></div><div><br></div><div>Thank you for everything!</div><div>
<br></div><div>Alan</div><br><div class="gmail_quote">On Wed, Oct 17, 2012 at 8:36 AM, Jake Smith <span dir="ltr"><<a href="mailto:jsmith@argotec.com" target="_blank">jsmith@argotec.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
----- Original Message -----<br>
<br>
> From: "Richard \"Alan\" McAlexander" <<a href="mailto:alanmac1982@gmail.com">alanmac1982@gmail.com</a>><br>
> To: "The Pacemaker cluster resource manager"<br>
> <<a href="mailto:pacemaker@oss.clusterlabs.org">pacemaker@oss.clusterlabs.org</a>><br>
> Sent: Tuesday, October 16, 2012 7:23:37 PM<br>
> Subject: Re: [Pacemaker] Unable to add ping resource to pacemaker<br>
> 1.0.12<br>
<div><div class="h5"><br>
> Hi Jake,<br>
> Below is my config. Thank you!<br>
<br>
> <meta_attributes id="group_its-meta_attributes"/><br>
> <primitive id="res_ping_1" class="ocf" provider="pacemaker"<br>
> type="ping"><br>
> <instance_attributes id="res_ping_1-instance_attributes"><br>
> <nvpair id="nvpair-res_ping_1-multiplier" name="multiplier"<br>
> value="1000"/><br>
> <nvpair id="nvpair-res_ping_1-host_list" name="host_list"<br>
> value="10.254.138.1"/><br>
> </instance_attributes><br>
> <operations id="res_ping_1-operations"><br>
> <op interval="0" id="op-res_ping_1-start" name="start" timeout="60"/><br>
> <op interval="0" id="op-res_ping_1-stop" name="stop" timeout="20"/><br>
> <op id="op-res_ping_1-monitor" name="monitor" interval="10"<br>
> timeout="60" start-delay="0"/><br>
> <op interval="0" id="op-res_ping_1-reload" name="reload"<br>
> timeout="80"/><br>
> </operations><br>
> <meta_attributes id="res_ping_1-meta_attributes"><br>
> <nvpair id="res_ping_1-meta_attributes-target-role"<br>
> name="target-role" value="started"/><br>
> <nvpair id="res_ping_1-meta_attributes-migration-threshold"<br>
> name="migration-threshold" value="3"/><br>
> <nvpair id="res_ping_1-meta_attributes-allow-migrate"<br>
> name="allow-migrate" value="true"/><br>
> <nvpair id="res_ping_1-meta_attributes-resource-stickiness"<br>
> name="resource-stickiness" value="-INFINITY"/><br>
> </meta_attributes><br>
> </primitive><br>
<br>
> <rsc_location id="loc_res_ping_1_seaaimsprd1" rsc="res_ping_1"<br>
> node="seaaimsprd1" score="500"/><br>
> <rsc_location id="loc_res_ping_1_seaaimsprd2" rsc="res_ping_1"<br>
> node="seaaimsprd2" score="500"/><br>
<br>
</div></div>So I have two things for you.<br>
<br>
You need to clone the ping resource so that it runs on all nodes. You're location statements would just cancel each other out and the cluster would decide where to put the single res_ping_1 resource.<br>
For example I do this:<br>
<br>
<resources><br>
<clone id="cl_ping"><br>
<meta_attributes id="cl_ping_gateways-meta_attributes"><br>
<nvpair id="cl_ping_gateways-meta_attributes-clone-node-max" name="clone-node-max" value="1"/><br>
<nvpair id="cl_ping_gateways-meta_attributes-interleave" name="interleave" value="true"/><br>
<nvpair id="cl_ping_gateways-meta_attributes-target-role" name="target-role" value="Started"/><br>
</meta_attributes><br>
<primitive class="ocf" id="p_ping_gateways" provider="pacemaker" type="ping"><br>
<instance_attributes id="p_ping_gateways-instance_attributes"><br>
<nvpair id="p_ping_gateways-instance_attributes-host_list" name="host_list" value="xxxxxxx"/><br>
<nvpair id="p_ping_gateways-instance_attributes-multiplier" name="multiplier" value="100"/><br>
<nvpair id="p_ping_gateways-instance_attributes-dampen" name="dampen" value="33s"/><br>
</instance_attributes><br>
<operations><br>
<op id="p_ping_gateways-start-0" interval="0" name="start" timeout="60s"/><br>
<op id="p_ping_gateways-stop-0" interval="0" name="stop" timeout="20s"/><br>
<op id="p_ping_gateways-monitor-10s" interval="10s" name="monitor" timeout="60s"/><br>
</operations><br>
</primitive><br>
</clone><br>
</resources><br>
<br>
Then you will have a clone instance of ping on each node.<br>
<br>
Then you need to create location constraints for other resources in relation to the pingd value.<br>
For example:<br>
<br>
<constraints><br>
<rsc_location id="l_ntp_ip_with_ping" rsc="p_ip_ntp"><br>
<rule boolean-op="or" id="l_ntp_ip_with_ping-rule" score="-INFINITY"><br>
<expression attribute="pingd" id="l_ntp_ip_with_ping-expression" operation="not_defined"/><br>
<expression attribute="pingd" id="l_ntp_ip_with_ping-expression-0" operation="lte" value="0"/><br>
</rule><br>
</rsc_location><br>
</constraints><br>
<br>
This contraint requires that resource "p_ip_ntp" must never run on a node where the value of pingd is undefined or less than 0.<br>
<br>
Here's the crm code for the above:<br>
primitive p_ping_gateways ocf:pacemaker:ping \<br>
params host_list="xxxxx" multiplier="100" dampen="33s" \<br>
op start interval="0" timeout="60s" \<br>
op stop interval="0" timeout="20s" \<br>
op monitor interval="10s" timeout="60s"<br>
<br>
clone cl_ping p_ping_gateways \<br>
meta clone-node-max="1" interleave="true" target-role="Started"<br>
<br>
location l_ntp_ip_with_ping p_ip_ntp \<br>
rule $id="l_ntp_ip_with_ping-rule" -inf: not_defined pingd or pingd lte 0<br>
<br>
<br>
HTH<br>
<span class="HOEnZb"><font color="#888888"><br>
Jake<br>
</font></span><div class="im HOEnZb"><br>
<br>
<br>
> On Mon, Oct 15, 2012 at 9:46 PM, Jake Smith < <a href="mailto:jsmith@argotec.com">jsmith@argotec.com</a> ><br>
> wrote:<br>
<br>
> > Sorry for the top post.<br>
><br>
<br>
> > Hard to say much without pacemaker config but did you configure<br>
> > location constraints for your resources based upon pingd value?<br>
><br>
<br>
> > Post your pacemaker config or pastebin link to it and we'll be able<br>
> > to help more.<br>
><br>
<br>
> > Hth<br>
><br>
<br>
> > Jake<br>
><br>
</div><div class="HOEnZb"><div class="h5">> > From: Richard Alan McAlexander<br>
><br>
> > Sent: Mon, 15/10/2012 06:39 PM<br>
><br>
> > To: <a href="mailto:pacemaker@oss.clusterlabs.org">pacemaker@oss.clusterlabs.org</a><br>
><br>
> > Subject: [Pacemaker] Unable to add ping resource to pacemaker<br>
> > 1.0.12<br>
><br>
<br>
> > _______________________________________________<br>
><br>
> > Pacemaker mailing list: <a href="mailto:Pacemaker@oss.clusterlabs.org">Pacemaker@oss.clusterlabs.org</a><br>
><br>
> > <a href="http://oss.clusterlabs.org/mailman/listinfo/pacemaker" target="_blank">http://oss.clusterlabs.org/mailman/listinfo/pacemaker</a><br>
><br>
<br>
> > Project Home: <a href="http://www.clusterlabs.org" target="_blank">http://www.clusterlabs.org</a><br>
><br>
> > Getting started:<br>
> > <a href="http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf" target="_blank">http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf</a><br>
><br>
> > Bugs: <a href="http://bugs.clusterlabs.org" target="_blank">http://bugs.clusterlabs.org</a><br>
><br>
<br>
> _______________________________________________<br>
> Pacemaker mailing list: <a href="mailto:Pacemaker@oss.clusterlabs.org">Pacemaker@oss.clusterlabs.org</a><br>
> <a href="http://oss.clusterlabs.org/mailman/listinfo/pacemaker" target="_blank">http://oss.clusterlabs.org/mailman/listinfo/pacemaker</a><br>
<br>
> Project Home: <a href="http://www.clusterlabs.org" target="_blank">http://www.clusterlabs.org</a><br>
> Getting started:<br>
> <a href="http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf" target="_blank">http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf</a><br>
> Bugs: <a href="http://bugs.clusterlabs.org" target="_blank">http://bugs.clusterlabs.org</a><br>
<br>
_______________________________________________<br>
Pacemaker mailing list: <a href="mailto:Pacemaker@oss.clusterlabs.org">Pacemaker@oss.clusterlabs.org</a><br>
<a href="http://oss.clusterlabs.org/mailman/listinfo/pacemaker" target="_blank">http://oss.clusterlabs.org/mailman/listinfo/pacemaker</a><br>
<br>
Project Home: <a href="http://www.clusterlabs.org" target="_blank">http://www.clusterlabs.org</a><br>
Getting started: <a href="http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf" target="_blank">http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf</a><br>
Bugs: <a href="http://bugs.clusterlabs.org" target="_blank">http://bugs.clusterlabs.org</a><br>
</div></div></blockquote></div><br></div>