[Pacemaker] pacemaker + cman - node names and bind address
Digimer
lists at alteeve.ca
Thu Dec 5 07:36:36 UTC 2013
On 05/12/13 02:28, Nikola Ciprich wrote:
> Hello,
>
> not sure whether this shouldn't be asked in some different
> conference, if so, I'm sorry in advance..
>
> Since this seems to be recommended solution for RHEL6 and since I
> need to use CLVMD, I switched my cluster from corosync + pacemaker
> to cman+pacemaker.
>
> I usually use two-nodes clusters, where hostnames resolve to lan
> uplink addresses, and nodes are interconnected using crosslink (to
> be exact, multiple crosslinks with bonding).
>
> I'd like to use hostnames as cluster node names, but I'd like
> cluster communication to go over crosslinks. Is there a way I could
> force this in cluster.conf?
>
> cluster.conf manpage is quite brief on this..
>
> Could somebody please give me an advice?
>
> thanks a lot in advance
>
> BR
>
> nik
Hello,
This list is fine to ask.
I speak mainly as a cman user, but I will make an educated guess on
the pacemaker side of things.
First, cman does not replace corosync. Both pacemaker and cman use
corosync for cluster communications and membership. The difference is
that cman configures and starts corosync for you, behind the scenes.
The node names you set in cluster.conf's "<clusternode
name="an-c05n01.alteeve.ca" nodeid="1"> ... </clusternode>"
(an-c05n01.alteeve.ca in this case) is resolved to an IP address. This
IP address/subnet is then looked for of your network and, once found,
the associated network card is used.
Generally, it's advised that you set the cluster names to match each
node's 'uname -n' hostname. If you did that, then the following bit of
bash will tell you which interface will be used for the cluster (on
RHEL/CentOS 6, anyway);
ifconfig |grep -B 1 $(gethostip -d $(uname -n)) | grep HWaddr | awk '{
print $1 }'
Once you've identified the network, you will want to make sure that,
if it is bonded, it is a supported bond mode. Prior to 6.3 (iirc),
only mode=1 (active/passive) bonding was supported. With 6.4, mode=0
and mode=2 support was added. All other bond modes are not supported
under corosync.
As for pacemaker integration; Be sure to setup stonith in pacemaker
and make sure it is working. Then use the 'fence_pcmk' fence agent in
cluster.conf itself. This way, should cman detect a node failure, it
will call pacemaker and ask it to fence the target node, saving you
from having to keep the real fencing configured in two places at once.
hth
digimer
--
Digimer
Papers and Projects: https://alteeve.ca/w/
What if the cure for cancer is trapped in the mind of a person without
access to education?
More information about the Pacemaker
mailing list