[Linux-HA] Command line for building cib.xml?

Andrew Beekhof beekhof at gmail.com
Tue Dec 11 02:59:18 MST 2007


On Dec 10, 2007, at 10:50 PM, Jason Qualkenbush wrote:

> I have a vanilla cluster built, and that gives me a cib.xml that looks
> like this:
>
> <cib generated="true" admin_epoch="0" epoch="7" num_updates="51"
> have_quorum="false" num_peers="1" cib_feature_revision="1.3"
> cib-last-written="Tue Dec 11 06:37:32 2007" ccm_transition="1"
> dc_uuid="970ac2a1-9569-40e2-87c7-b7acbac8782a">
>   <configuration>
>     <crm_config/>
>     <nodes>
>       <node id="970ac2a1-9569-40e2-87c7-b7acbac8782a" uname="deb1"
> type="normal"/>
>       <node id="7156322d-e209-40a7-ab6e-7496186442e2" uname="deb2"
> type="normal"/>
>       <node id="661129dd-6219-4958-a086-65153ddace44" uname="deb3"
> type="normal"/>
>     </nodes>
>     <resources/>
>     <constraints/>
>   </configuration>
> </cib>
>
> I'm looking at the simple configurations and I would like to throw in
> a cluster IP addres into my cluster.
>
> <primitive id="WebServerIP" class="ocf" type="IPaddr"  
> provider="heartbeat">
>    <instance_attributes>
>        <attributes>
>            <nvpair name="ip" value="127.0.0.26"/>
>        </attributes>
>     </instance_attributes>
> </primitive>
>
>> From the page: http://www.linux-ha.org/v2/AdminTools/cibadmin
> It looks like I'm limited to building an XML file by hand, and then
> importing that into my configuration.  Is there something...  I guess
> like IPTables that can inject a resource into the configuration?
> Maybe I missed it in the documentation.  Something like:
>
> somecommand --id=WebServerIP --class=ocf --type=IPaddr
> --provider=heartbeat --attribute="name=ip,value=127.0.0.26"


look for a script called: crm_primitive.py

it will produce the XML which you can then load into the CIB with  
cibadmin

>
>
> Am I making sense?
>
> -Jason
> _______________________________________________
> Linux-HA mailing list
> Linux-HA at lists.linux-ha.or



More information about the Linux-HA mailing list