[Pacemaker] [pacemaker] configuring Multi state resource in pacemaker/HA

rakesh k rakirocker4236 at gmail.com
Fri May 6 05:30:13 UTC 2011


Hi All

I had configured Mysql process in Linux Ha framework.

Please find the HA configuration for mysql process.

primitive Mysql ocf:heartbeat:mysql \
        params binary="/usr/bin/mysqld_safe" config="/etc/my.cnf"
datadir="/var/lib/mysql" user="mysql" pid="/var/lib/mysql/mysql.pid"
socket="/var/lib/mysql/mysql.sock" test_passwd="slavepass"
test_table="test.msf_list" test_user="repl" replication_user="repl"
replication_passwd="slavepass" \
        op start interval="0" timeout="120s" \
        op stop interval="0" timeout="120s" \
        op monitor interval="10s" role="Master" timeout="8s" \
        op monitor interval="12s" timeout="8s"
primitive MysqlVIP ocf:heartbeat:IPaddr3 \
        params ip="192.168.254.217" eth_num="eth0:3"
vip_cleanup_file="/var/run/bigha.pid" \
        op start interval="0" timeout="120s" \
        op stop interval="0" timeout="60s" \
        op monitor interval="30s" \
        meta target-role="Started"
ms MS_Mysql Mysql \
        meta notify="true" target-role="Started"
location L_Master MS_Mysql \
        rule $id="L_Master-rule" $role="Master" 100: #uname eq mysql2 \
        rule $id="L_Master-rule1" $role="Master" 100: #uname eq mysql3

Here are my scenarios

1) when i started the Ha process on both the nodes , Mysql process has been
sarted
2) The Master is pointing to mysql2 node
3) now i stopped the HA process on node mysql2, then Master mysql has been
migrated to mysql3
4)The data is stored in *mysql3* node
5) Now again i stopped HA process on mysql3 node .
6) And started HA process in Mysql2, Now here i found there is data
inconsistent at this point of time on both the nodes, where if we update the
mysql2 node and start the HA process on mysql3 node , found there is
inconsistent of data on both the nodes.

Is there is a way to dynamically change the score values of the mysql
process such that when ever both the nodes started the last mysql master
will act as a master mysql process.


Looking forward for your help, thank you very much

Regards
Rakesh
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.clusterlabs.org/pipermail/pacemaker/attachments/20110506/061ea9df/attachment-0003.html>


More information about the Pacemaker mailing list