[Pacemaker] IP Range Failover with IPaddr2 and clone / globally-unique="true"
Anton Melser
melser.anton at gmail.com
Wed Jan 25 18:34:18 CET 2012
On 25 January 2012 17:43, Dejan Muhamedagic <dejanmm at fastmail.fm> wrote:
> On Wed, Jan 25, 2012 at 04:40:38PM +0100, Anton Melser wrote:
>> >> # primitive ClusterIP.144.1 ocf:heartbeat:IPaddr2 params
>> >> ip="10.144.1.1" cidr_netmask="32" clusterip_hash="sourceip" op monitor
>> >> interval="120s"
>> >> # clone CloneIP ClusterIP.144.1 meta globally-unique="true" clone-max="8"
>> >
>> > You have just two nodes so with this configuration you get two
>> > clones. You can add meta clone-node-max=8 (or whatever fits your
>> > needs) to have more clones running per node.
>> >
>> > Thanks,
>> >
>> > Dejan
>> Thank you! I just can't understand what I'm doing wrong here then - I
>> am only getting one actual IP, whatever I'm putting in. I stopped FW2
>> to make sure I have a coherent setup.
>>
>> crm(live)# configure show
>> node FW1
>> node FW2
>> primitive ClusterIP.144.1 ocf:heartbeat:IPaddr2 \
>> params ip="10.144.1.1" cidr_netmask="32" clusterip_hash="sourceip" \
>
> cidr_netmask is not correct (it should be 8). And you need to set
> unique_clone_address to true as already mentioned.
Thanks for this - I have it working!
For future reference, I have issued the following:
crm configure primitive Test1 ocf:heartbeat:IPaddr2 params
ip="10.144.1.1" cidr_netmask="24" clusterip_hash="sourceip" nic="eth0"
iflabel="Test1" unique_clone_address="true" op monitor interval="120"
crm configure primitive Test2 ocf:heartbeat:IPaddr2 params
ip="10.144.2.1" cidr_netmask="24" clusterip_hash="sourceip" nic="eth0"
iflabel="Test2" unique_clone_address="true" op monitor interval="120"
crm configure primitive Test3 ocf:heartbeat:IPaddr2 params
ip="10.144.3.1" cidr_netmask="24" clusterip_hash="sourceip" nic="eth0"
iflabel="Test3" unique_clone_address="true" op monitor interval="120"
crm configure primitive Test4 ocf:heartbeat:IPaddr2 params
ip="10.144.4.1" cidr_netmask="24" clusterip_hash="sourceip" nic="eth0"
iflabel="Test4" unique_clone_address="true" op monitor interval="120"
crm configure primitive Test5 ocf:heartbeat:IPaddr2 params
ip="10.144.5.1" cidr_netmask="24" clusterip_hash="sourceip" nic="eth0"
iflabel="Test5" unique_clone_address="true" op monitor interval="120"
crm configure primitive Test6 ocf:heartbeat:IPaddr2 params
ip="10.144.6.1" cidr_netmask="24" clusterip_hash="sourceip" nic="eth0"
iflabel="Test6" unique_clone_address="true" op monitor interval="120"
crm configure primitive Test7 ocf:heartbeat:IPaddr2 params
ip="10.144.7.1" cidr_netmask="24" clusterip_hash="sourceip" nic="eth0"
iflabel="Test7" unique_clone_address="true" op monitor interval="120"
crm configure primitive Test8 ocf:heartbeat:IPaddr2 params
ip="10.144.8.1" cidr_netmask="24" clusterip_hash="sourceip" nic="eth0"
iflabel="Test8" unique_clone_address="true" op monitor interval="120"
crm configure clone CLTest1 Test1 meta globally-unique="true"
clone-node-max="253" clone-max="253"
crm configure clone CLTest2 Test2 meta globally-unique="true"
clone-node-max="253" clone-max="253"
crm configure clone CLTest3 Test3 meta globally-unique="true"
clone-node-max="253" clone-max="253"
crm configure clone CLTest4 Test4 meta globally-unique="true"
clone-node-max="253" clone-max="253"
crm configure clone CLTest5 Test5 meta globally-unique="true"
clone-node-max="253" clone-max="253"
crm configure clone CLTest6 Test6 meta globally-unique="true"
clone-node-max="253" clone-max="253"
crm configure clone CLTest7 Test7 meta globally-unique="true"
clone-node-max="253" clone-max="253"
crm configure clone CLTest8 Test8 meta globally-unique="true"
clone-node-max="253" clone-max="253"
I actually did 1 to 3 (with both configure primitive and configure
clone) which worked successfully, and then launched the following.
Both FW1 and FW2 are up, and it seems to be distributing the IPs
between the two. The IPs are pingable from external machines. It is
taking aaaaaages though - am I trying to fit a round pole into a
square hole here? Am I never going to get things working smoothly with
the numbers of IPs I need here? Is it worth persisting, or should I be
looking for a cluster solution better adapted to lots and lots of very
simple resources?
Thanks again!
Anton
More information about the Pacemaker
mailing list