Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I am trying to enable fail over strategy using pacemaker on a mysql Master-Master replication on two virtual machine running openSUSE 12 created by VritualBox.

I managed to complete the mysql dual-master replication, and it seems to work. Server A has 192.168.X.a as IP while server B's IP is 192.168.X.b. I followed the instruction here, so basically my corosync.conf looks like the one presented in the guide, except the interface section which is written below:

interface {
    ringnumber: 0
    bindnetaddr: 192.168.X.c
    mcastaddr: 226.94.1.1
    mcastport: 5405
    ttl: 1
}

My first question is: what exactly is bindnetaddr:? Is it the virtual IP of my cluster? If not, should it be the other nodes IP or it own IP? (I mean IP of the server has this config or the other server)

My second question is: what are mcastaddr and mcastport and what should they be set to?

Then I tried to add MySQL as a resource, so I did as described here. But when I enter crm configure primitive ip_mysql ocf:heartbeat:IPaddr2 params ip="192.168.X.c" I get

crm configure primitive ip_my ocf:heartbeat:IPaddr2 params ip='192.168.114.8'
crm_verify[23888]: 2012/12/29_12:25:51 WARN: cluster_option: Using deprecated name
'stonith_enabled' for cluster option 'stonith-enabled'
Warnings found during check: config may not be valid 

My third question is: when providing the params ip to configure primitive, should it be the virtual IP? (the one set in the corosync.conf file)

My forth question is: should I ignore the warnings? To be honest I didn't go any further when I faced the warnings, and since I had lots of uncertainties, I thought It's better fisrt to make sure I'm on the right path.

On a different note, I would be more than thankful if anybody could link me to a simple/good tutorial on using Pacemaker/Corosync and mySQL replication NOT DRDB or using XtraDB and ....simple dual-master replication...most of tutorial availabe on web are for DRDB and XtraDB, or other tools. I know the procedure should be the same (adding a resource to pacemaker) but I was not successful on extracting the similarities from those tutorials...

share|improve this question
1  
Nice first post! –  slm Dec 29 '12 at 13:57
    
I think bindnetaddr: 192.168.X.c should be bindnetaddr: 192.168.1.0. It's the network address is it not? –  slm Dec 29 '12 at 14:10
    
yes, bindnetaddr seems to be the network address to bind to. My IP addresses is 192.168.114.x, that is why I set it to bindnetaddr: 192.168.114.c instead of bindnetaddr: 192.168.1.0... am I correct? anyhow, my question would be if this is the virtual IP I have my pacemaker set to. –  mrz Dec 30 '12 at 7:29
    
OK, you're example didn't show the .114 subnet so that makes more sense. Yeah I would expect that param to be the virutal ip. This SF post might be helpful, serverfault.com/questions/418634/… –  slm Dec 30 '12 at 13:55
1  
Also can you compare your setup to this tutorial that shows pacemaker being used to HA apache, andriigrytsenko.net/2011/07/pacemaker-and-apache –  slm Dec 30 '12 at 14:03

1 Answer 1

up vote 1 down vote accepted

Answer of question one bindnetaddr is the network address we want pacemaker/corosync(?) to bind to. So if your servers have A.B.C.x and A.B.C.y as IP address, then in corosync configuration file, you have to assign bindnetaddr to A.B.C.0.

Answer of question two mcastaddr is the IP address to use for multicasting and mcastport is the port to use for cluster communication. In order to communicate with each other, all nodes belonging to the same cluster need to use the same bindnetaddr, mcastaddr and mcastport.

Answer of question three params ip is the virtual IP. If you have set your bindnetaddr to A.B.C.0 then your virtual IP should be A.B.C.z.

Answer of question four Those warnings didn't affect my cluster. SO yes I ignored them.

Beside the links @slm (see resources below) provided in his comments on my question, this tutorial on HeartBeat MySQL resource agent and this high availability guide helped me to setup and configure my cluster.

Resources

share|improve this answer
    
Good answer to your question. Make sure you accept your answer! –  slm Dec 31 '12 at 7:02
    
Thank you, I have to wait 6 hours to accept it. –  mrz Dec 31 '12 at 7:08

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.