Mailing List Archive

Basic Clone IP configuration not starting automatically
Hi there guys.
I'm new to pacemaker and I'm trying to accomplish an active/active cluster
with a VIP ip address, I used the java frontend for the initial setup, I'm
using LCMC-1.7.6.jar.


This is what I've got:
CentOS release 6.5
pacemaker-libs-1.1.10-14.el6_5.3.x86_64
pacemaker-cli-1.1.10-14.el6_5.3.x86_64
pacemaker-cluster-libs-1.1.10-14.el6_5.3.x86_64
pacemaker-1.1.10-14.el6_5.3.x86_64
pcs-0.9.90-2.el6.centos.3.noarch

Cluster configuration:

Last updated: Thu Feb 5 14:27:41 2015
Last change: Thu Feb 5 14:17:26 2015 via cibadmin on haproxy02
Stack: cman
Current DC: haproxy01 - partition with quorum
Version: 1.1.10-14.el6_5.3-368c726
2 Nodes configured
2 Resources configured


Online: [ haproxy01 haproxy02 ]

Clone Set: cl_IPaddr2_1 [res_IPaddr2_virtualip] (unique)
res_IPaddr2_virtualip:0 (ocf::heartbeat:IPaddr2): Started
haproxy01
res_IPaddr2_virtualip:1 (ocf::heartbeat:IPaddr2): Started
haproxy01

Node Attributes:
* Node haproxy01:
* Node haproxy02:

Clone IP configuration:
pcs resource show cl_IPaddr2_1
Clone: cl_IPaddr2_1
Meta Attrs: clone-max=2 clone-node-max=2 notify=true globally-unique=true
Resource: res_IPaddr2_virtualip (class=ocf provider=heartbeat
type=IPaddr2)
Attributes: ip=1.1.1.1
Meta Attrs: target-role=started
Operations: stop interval=0 timeout=20 (op-res_IPaddr2_virtualip-stop)
monitor interval=5s
(res_IPaddr2_virtualip-monitor-interval-5s)
start interval=0 (res_IPaddr2_virtualip-start-interval-0)

IPTABLES
Chain INPUT (policy ACCEPT)
target prot opt source destination
CLUSTERIP all -- 0.0.0.0/0 1.1.1.1 CLUSTERIP
hashmode=sourceip-sourceport clustermac=51:72:D8:57:74:84 total_nodes=2
local_node=1 hash_init=0

CMAN configuration:

<?xml version="1.0"?>
<cluster config_version="1" name="clustername">
<logging debug="off"/>
<clusternodes>
<clusternode name="haproxy01" nodeid="1">
<fence>
<method name="pcmk-redirect">
<device name="pcmk" port="haproxy01"/>
</method>
</fence>
</clusternode>
<clusternode name="haproxy02" nodeid="2">
<fence>
<method name="pcmk-redirect">
<device name="pcmk" port="haproxy02"/>
</method>
</fence>
</clusternode>
</clusternodes>
<fencedevices>
<fencedevice name="pcmk" agent="fence_pcmk"/>
</fencedevices>
</cluster>


If I do an sshd to the VIP I can see the round robin is woking and it
switches bettween hosts and I can see of course the alias created on the
eth0 iface.

My problem is that when I reboot a server to test it, the alias is not
created automatically and I have to perform a stop/start from the java
frontend.

What am I missing to make it work automatically?

Thanks for your time and support.
Regards
Re: Basic Clone IP configuration not starting automatically [ In reply to ]
Am Donnerstag, 5. Februar 2015, 14:33:52 schrieb Net Warrior:
> Hi there guys.
(...)
> If I do an sshd to the VIP I can see the round robin is woking and it
> switches bettween hosts and I can see of course the alias created on the
> eth0 iface.
>
> My problem is that when I reboot a server to test it, the alias is not
> created automatically and I have to perform a stop/start from the java
> frontend.

What do you mean by "the alias"? The virtual IP address?
What is the outut of crm_mon -1 before the failure and what is it after?
What expect the cluster to do? What actually does it?

Mit freundlichen Grüßen,

Michael Schwartzkopff

--
[*] sys4 AG

http://sys4.de, +49 (89) 30 90 46 64, +49 (162) 165 0044
Franziskanerstraße 15, 81669 München

Sitz der Gesellschaft: München, Amtsgericht München: HRB 199263
Vorstand: Patrick Ben Koetter, Marc Schiffbauer
Aufsichtsratsvorsitzender: Florian Kirstein
Re: Basic Clone IP configuration not starting automatically [ In reply to ]
Hi Michael.

I mean this, when I reboot the server., pacemaker starts automatically but
I do no see the VIP in the eth0, sorry I used the word alias which may have
lead to a confision.

ip addr show
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 16436 qdisc noqueue state UNKNOWN
link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
inet 127.0.0.1/8 scope host lo
inet6 ::1/128 scope host
valid_lft forever preferred_lft forever

2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state
UP qlen 1000
link/ether 00:21:f6:00:00:25 brd ff:ff:ff:ff:ff:ff
inet 1.1.1.2/16 brd 1.1.255.255 scope global eth0 ( example server
service IP )
inet 1.1.1.1/16 brd 1.1.255.255 scope global secondary eth0 ( THIS IS
THE VIP) which is not created/configured automatically.

So I have to start it with
*:/usr/sbin/crm_resource --meta -t primitive -r res_IPaddr2_virtualip -p
target-role -v started*
Or from the LCMC java frontend I have to perform an stop/start.

The output of crm_mon looks like this on both situations, the resources
are shown as started but the VIP is not brought up
automatically when the servers boots up eventhough pacemaker starts
automatically.

Clone Set: cl_IPaddr2_1 [res_IPaddr2_virtualip] (unique)
res_IPaddr2_virtualip:0 (ocf::heartbeat:IPaddr2): Started
haproxy02
res_IPaddr2_virtualip:1 (ocf::heartbeat:IPaddr2): Started
haproxy02


Thanks for your time and support
Regards



2015-02-05 20:21 GMT-03:00 Michael Schwartzkopff <ms@sys4.de>:

> Am Donnerstag, 5. Februar 2015, 14:33:52 schrieb Net Warrior:
> > Hi there guys.
> (...)
> > If I do an sshd to the VIP I can see the round robin is woking and it
> > switches bettween hosts and I can see of course the alias created on the
> > eth0 iface.
> >
> > My problem is that when I reboot a server to test it, the alias is not
> > created automatically and I have to perform a stop/start from the java
> > frontend.
>
> What do you mean by "the alias"? The virtual IP address?
> What is the outut of crm_mon -1 before the failure and what is it after?
> What expect the cluster to do? What actually does it?
>
> Mit freundlichen Grüßen,
>
> Michael Schwartzkopff
>
> --
> [*] sys4 AG
>
> http://sys4.de, +49 (89) 30 90 46 64, +49 (162) 165 0044
> Franziskanerstraße 15, 81669 München
>
> Sitz der Gesellschaft: München, Amtsgericht München: HRB 199263
> Vorstand: Patrick Ben Koetter, Marc Schiffbauer
> Aufsichtsratsvorsitzender: Florian Kirstein
> _______________________________________________
> Pacemaker mailing list: Pacemaker@oss.clusterlabs.org
> http://oss.clusterlabs.org/mailman/listinfo/pacemaker
>
> Project Home: http://www.clusterlabs.org
> Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
> Bugs: http://bugs.clusterlabs.org
>
>
Re: Basic Clone IP configuration not starting automatically [ In reply to ]
I solved the issue:

I had to configure resrouce-stickness option to 0 and now whatever hosts I
reboot the resources are back and stay like this:
ClusterVIP:0 (ocf::heartbeat:IPaddr2): Started haproxy01
ClusterVIP:1 (ocf::heartbeat:IPaddr2): Started haproxy02

Regads
Thanks for your time and support.

2015-02-06 15:04 GMT-03:00 Michael Schwartzkopff <ms@sys4.de>:

> Am Freitag, 6. Februar 2015, 08:14:22 schrieben Sie:
> > Hi Michael.
> >
> > I mean this, when I reboot the server., pacemaker starts automatically
> but
> > I do no see the VIP in the eth0, sorry I used the word alias which may
> have
> > lead to a confision.
> >
> > ip addr show
> > 1: lo: <LOOPBACK,UP,LOWER_UP> mtu 16436 qdisc noqueue state UNKNOWN
> > link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
> > inet 127.0.0.1/8 scope host lo
> > inet6 ::1/128 scope host
> > valid_lft forever preferred_lft forever
> >
> > 2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast
> state
> > UP qlen 1000
> > link/ether 00:21:f6:00:00:25 brd ff:ff:ff:ff:ff:ff
> > inet 1.1.1.2/16 brd 1.1.255.255 scope global eth0 ( example server
> > service IP )
> > inet 1.1.1.1/16 brd 1.1.255.255 scope global secondary eth0 ( THIS
> IS
> > THE VIP) which is not created/configured automatically.
> >
> > So I have to start it with
> > *:/usr/sbin/crm_resource --meta -t primitive -r res_IPaddr2_virtualip -p
> > target-role -v started*
> > Or from the LCMC java frontend I have to perform an stop/start.
> >
> > The output of crm_mon looks like this on both situations, the resources
> > are shown as started but the VIP is not brought up
> > automatically when the servers boots up eventhough pacemaker starts
> > automatically.
> >
> > Clone Set: cl_IPaddr2_1 [res_IPaddr2_virtualip] (unique)
> > res_IPaddr2_virtualip:0 (ocf::heartbeat:IPaddr2): Started
> > haproxy02
> > res_IPaddr2_virtualip:1 (ocf::heartbeat:IPaddr2): Started
> > haproxy02
>
> Are you sure that the second IP address res_IPaddr_vitualip:1 no not
> started?
> Perhaps it is only started on the second node? As you see above both
> instances
> of the clone ...:0 and ...:1 are started in the same node haproxy02.
>
> Mit freundlichen Grüßen,
>
> Michael Schwartzkopff
>
> --
> [*] sys4 AG
>
> http://sys4.de, +49 (89) 30 90 46 64, +49 (162) 165 0044
> Franziskanerstraße 15, 81669 München
>
> Sitz der Gesellschaft: München, Amtsgericht München: HRB 199263
> Vorstand: Patrick Ben Koetter, Marc Schiffbauer
> Aufsichtsratsvorsitzender: Florian Kirstein
>