using a direct network connection for 2-node cluster communication

dms

New Member
Nov 9, 2011
4
0
1
Hey there. I'm working on a 2-node-cluster setup using a direct network connection between the nodes which is meant for cluster communication in addition to the external network from which the cluster content is accessed. The interface eth0 goes to an external network, while eth2 is used for a direct connection between the nodes.

Even though I got it to work in the end, it wasn't clear what had to be done at first because when you add the 2nd node to the cluster via "pvecm add 192.168.12.3" (let's say the 2-node-network is 192.168.12.0) the cluster configuration software automatically sets the node ip to 123.456.789.3 anyway which is the ip to the external network at eth0. The solution was to make changes to /etc/hosts and add an entry for the internal network between the nodes.

before:
Code:
[FONT=&amp]127.0.0.1 localhost.localdomain localhost
[B][FONT=&amp][B]123[/B][/FONT][/B].456.789.3 node2.vserver.mydomain node2 pvelocalhost[/FONT]
after:
Code:
[FONT=&amp]127.0.0.1 localhost.localdomain localhost
[U][B][FONT=&amp]192.168.12.3 node2.vserver.mydomain node2 pvelocalhost[/FONT][/B][/U]
123.456.789.3 node2.vserver.mydomain[/FONT]

It seems the cluster configuration software gets the ip address of the each of the nodes from /etc/hosts even when another address is specified using the "pvecm add" command. I just wanted to share this bit of information in case anyone else who wants to have the cluster communication on a separate network runs into the same problem. Also, you might not have been aware of this and may want to include the functionality into pvecm.
 
Last edited:
It seems the cluster configuration software gets the ip address of the each of the nodes from /etc/hosts even when another address is specified using the "pvecm add" command.

Yes, that is how corosync/cman gets the address.
 
Question: Is it likely that this kind of setup will cause problems/conflicts later concerning the configuration or other?
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!