[Pacemaker] running a resource on any node in an asymmetric cluster

Brian J. Murrell brian at interlinx.bc.ca
Wed Oct 26 14:19:00 UTC 2011


I want to be able to run a resource on any node in an asymmetric
cluster so I tried creating a rule to run it on any node not named
"foo" since there are no nodes named foo in my cluster:

# cat /tmp/foo.xml
<rsc_location id="run-bar-anywhere" rsc="bar">
  <rule id="run-bar-anywhere-rule" score=100>
    <expression id="run-bar-anywhere-expr" attribute="#uname" operation="ne" value="foo"/>
  </rule>
</rsc_location>

for the resource bar:

primitive bar stonith:fence_virsh \
	params ipaddr="192.168.122.1" login="root" identity_file="/root/.ssh/id_rsa-virsh" port="node2" action="reboot" secure="true" pcmk_host_list="node2" pcmk_host_check="static-list" pcmk_host_map=""

and apply that with:

# cibadmin -o constraints -C -x /tmp/foo.xml

I get:

Call cib_create failed (-47): Update does not conform to the configured schema/DTD

Can anyone point out why?  I thought I followed Example 8.9 from

http://www.clusterlabs.org/doc/en-US/Pacemaker/1.1/html/Pacemaker_Explained/s-rules-location.html

I even tried substituting the node foo for "node2" (since it doesn't
make much sense to run a stonith resource for node2 on node2 but that
doesn't change the result of cibadmin.

Cheers and thanks,
b.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 262 bytes
Desc: OpenPGP digital signature
URL: <https://lists.clusterlabs.org/pipermail/pacemaker/attachments/20111026/1934dfe2/attachment-0003.sig>


More information about the Pacemaker mailing list