[ClusterLabs] Floating IP active in both nodes

Dileep V Nair dilenair at in.ibm.com
Fri Oct 26 09:27:30 EDT 2018


Hello Gabriel,

I have a similar cluster configuration running fine. I am using the virtual
IP to NFS mount a filesystem from Node 1 to node 2. The differences I could
see from your configuration ..

  > primitive site_one_ip ocf:heartbeat:IPaddr \
  > params ip="192.168.2.200" cidr_netmask="255.255.252.0" nic="eth0" \
  > op monitor interval="40s" timeout="20s"


  I use ocf:heartbeat:IPaddr2
  I have given only the IP parameter, no netmask and nic
  I have a virtual hostname associated with the IP addr using /etc/hosts
  and use the virtual hostname to connect.



Thanks & Regards

Dileep Nair
Squad Lead - SAP Base
IBM Services for Managed Applications
+91 98450 22258 Mobile
dilenair at in.ibm.com

IBM Services



From:	Gabriel Buades <gbuades at soffid.com>
To:	users at clusterlabs.org
Date:	10/26/2018 06:34 PM
Subject:	Re: [ClusterLabs] Floating IP active in both nodes
Sent by:	"Users" <users-bounces at clusterlabs.org>



Hello Andrei.


I did not add lvs_support at first. I added it later when noticed the
problem to test if something changes, but I got same result

Gabriel


El vie., 26 oct. 2018 a las 11:47, Andrei Borzenkov (<arvidjaar at gmail.com>)
escribió:
  26.10.2018 11:14, Gabriel Buades пишет:
  > Dear cluster labs team.
  >
  > I previously configured a two nodes cluster with replicated maria Db.
  > To use one database as the active, and the other one as failover, I
  > configured a cluster using heartbeat:
  >
  > root at logpmgid01v:~$ sudo crm configure show
  > node $id="59bbdb76-be67-4be0-aedb-9e27d65f371e" logpmgid01v
  > node $id="adbc5972-c491-4fc4-b87d-8170e1b2d4d0" logpmgid02v \
  > attributes standby="off"
  > primitive site_one_ip ocf:heartbeat:IPaddr \
  > params ip="192.168.2.200" cidr_netmask="255.255.252.0" nic="eth0" \
  > op monitor interval="40s" timeout="20s"
  > location site_one_ip_pref site_one_ip 100: logpmgid01v
  > property $id="cib-bootstrap-options" \
  > dc-version="1.1.10-42f2063" \
  > cluster-infrastructure="heartbeat" \
  > stonith-enabled="false"
  >
  > Now, I've done a similar setup using corosync:
  > root at 908soffid02:~# crm configure show
  > node 1: 908soffid01
  > node 2: 908soffid02
  > primitive site_one_ip IPaddr \
  > params ip=10.6.12.118 cidr_netmask=255.255.0.0 nic=ens160
  lvs_support=true \

  What is the reason you added lvs_support? Previous configuration did not
  have it.

  > meta target-role=Started is-managed=true
  > location cli-prefer-site_one_ip site_one_ip role=Started inf:
  908soffid01
  > location site_one_ip_pref site_one_ip 100: 908soffid01
  > property cib-bootstrap-options: \
  > have-watchdog=false \
  > dc-version=1.1.14-70404b0 \
  > cluster-infrastructure=corosync \
  > cluster-name=debian \
  > stonith-enabled=false \
  > no-quorum-policy=ignore \
  > maintenance-mode=false
  >
  > Apparently, it works fine, and floating IP address is active in node1:
  > root at 908soffid02:~# crm_mon -1
  > Last updated: Fri Oct 26 10:06:12 2018 Last change: Fri Oct 26 10:02:53
  > 2018 by root via cibadmin on 908soffid02
  > Stack: corosync
  > Current DC: 908soffid01 (version 1.1.14-70404b0) - partition with
  quorum
  > 2 nodes and 1 resource configured
  >
  > Online: [ 908soffid01 908soffid02 ]
  >
  >  site_one_ip (ocf::heartbeat:IPaddr): Started 908soffid01
  >
  > But when node2 tries to connect to the floating IP address, it gets
  > connected to itself, despite the IP address is bound to the first node:
  > root at 908soffid02:~# ssh root at 10.6.12.118 hostname
  > root at soffiddb's password:
  > 908soffid02
  >
  > I'd want the second node connects to the actual floating IP address,
  but I
  > cannot see how to set it up. Any help is welcome.
  >
  > I am using pacemaker 1.1.14-2ubuntu1.4 and corosync 2.3.5-3ubuntu2.1
  >
  > Kind regards.
  >
  >
  >
  > Gabriel Buades
  >
  >
  > _______________________________________________
  > Users mailing list: Users at clusterlabs.org
  > https://lists.clusterlabs.org/mailman/listinfo/users
  >
  > Project Home: http://www.clusterlabs.org
  > Getting started:
  http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
  > Bugs: http://bugs.clusterlabs.org
  >

  _______________________________________________
  Users mailing list: Users at clusterlabs.org
  https://lists.clusterlabs.org/mailman/listinfo/users

  Project Home: http://www.clusterlabs.org
  Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
  Bugs: http://bugs.clusterlabs.org
  _______________________________________________
  Users mailing list: Users at clusterlabs.org
  https://lists.clusterlabs.org/mailman/listinfo/users


  Project Home:
  http://www.clusterlabs.org

  Getting started:
  http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf

  Bugs:
  http://bugs.clusterlabs.org



-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.clusterlabs.org/pipermail/users/attachments/20181026/473a627a/attachment-0002.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: graycol.gif
Type: image/gif
Size: 105 bytes
Desc: not available
URL: <https://lists.clusterlabs.org/pipermail/users/attachments/20181026/473a627a/attachment-0002.gif>


More information about the Users mailing list