Pacemaker 2 floatingIP

high-availabilitypacemaker

I'm triying to config a cluster with two servers, each of them with two interfaces, and i want to config two floatings ips, one private and other public.
The idea is, if some of two interface fail in one server fails, cluster swicths to the other server.

I'm using pacemaker but until now, i've just made it work with one floating IP. With two, until now, no way.
I'm configuring two resources (2 float ip) and two rings.

Have somebody tried this? Or somebody can guide me?

Thanks in advance!

Best Answer

Should be fairly simple. Just configure up another IPaddr2 primitive. If you need to specify which interface the virtual IP binds to this can be done fairly easily via the nic= parameter. Naturally, the interface names on both nodes will need to match if using nic= parameter. for example:

primitive p_ip_private IPaddr2 \
    params ip=192.168.35.5 cidr_netmask=255.255.255.0 nic=eth1 \
    op start interval=0 timeout=20 \
    op stop interval=0 timeout=20s \
    op monitor interval=20 timeout=20

You need not use the nic= parameter though. The IPaddr2 resource agent should be smart enough to properly choose the right interface based upon the network and subnet already assigned to the interface.

Related Topic