Pacemaker & Corosync

pacemaker + corosync

reason: heartbeat is no longer being developed.

Please note, that you have to remove user id 65 (cluster) manually, if you want to use the pacemaker ebuild. Both /etc/passwd and /etc/group

configure corosync.conf
/usr/lib64/heartbeat/haresources2cib.py /etc/ha.d/haresources
chown hacluster:haclient /var/lib/heartbeat/crm
chown hacluster:haclient /var/lib/pengine
chmod 760 /var/lib/pengine
/etc/init.d/corosync start

cibadmin --upgrade --force
cibadmin --cib_query > /tmp/tmp.xml

/etc/init.d/corossync stop

mv /var/lib/heartbeat/crm/cib.xml /var/lib/heartbeat/crm/cib.xml.old
cp /tmp/tmp.xml /var/lib/heartbeat/crm/cib.xml

NOTE: must be run on the console not thru ssh!     corosync-authkey

/etc/init.d/corosync start

configure property no-quorum-policy=ignore

node2~: sudo mv ~/authkey /etc/corosync/authkey
node2~: sudo chown root:root /etc/corosync/authkey
node2~: sudo chmod 400 /etc/corosync/authkey


references:
http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
http://clusterlabs.org/wiki/Example_XML_configurations
http://clusterlabs.org/wiki/Example_configurations

create a tunnel for the multicast is you have issues with smart swiches

on server1:
/sbin/modprobe ip_gre
/sbin/ip tunnel add netb mode gre remote 192.168.122.XX local 192.168.122.YY ttl 255
/sbin/ip link set netb up
/sbin/ip addr add 172.16.22.1 dev netb
/sbin/ip route add 172.16.23.0/24 dev netb
/sbin/ifconfig netb multicast
/sbin/ip route add 226.94.1.0/24 dev netb


on server2:
/sbin/modprobe ip_gre
/sbin/ip tunnel add neta mode gre remote 192.168.122.YY local 192.168.122.XX ttl 255
/sbin/ip link set neta up
/sbin/ip addr add 172.16.23.1 dev neta
/sbin/ip route add 172.16.22.0/24 dev neta
/sbin/ifconfig neta multicast
/sbin/ip route add 226.94.1.0/24 dev neta

note:
both corosync.conf files will need there config to reflect the local side of the tunnel bindnetaddr: 172.16.23.0

change cib.xml and get pacemaker to accept it

crm_verify -VVVVV -x newcib.xml
cibadmin -R -o cib -x newcib.xml
cibadmin -Q | less

removal of this version

emerge -C cluster-glue resource-agents pacemaker corosync
pacemaker_corosync.txt · Last modified: 2011/04/27 12:35 by paulsmith
 
Except where otherwise noted, content on this wiki is licensed under the following license: CC Attribution-Noncommercial-Share Alike 4.0 International
Recent changes RSS feed Donate Powered by PHP Valid XHTML 1.0 Valid CSS Driven by DokuWiki