<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40"><head><meta http-equiv=Content-Type content="text/html; charset=us-ascii"><meta name=Generator content="Microsoft Word 14 (filtered medium)"><style><!--
/* Font Definitions */
@font-face
{font-family:Wingdings;
panose-1:5 0 0 0 0 0 0 0 0 0;}
@font-face
{font-family:SimSun;
panose-1:2 1 6 0 3 1 1 1 1 1;}
@font-face
{font-family:"Cambria Math";
panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
{font-family:Calibri;
panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
{font-family:Tahoma;
panose-1:2 11 6 4 3 5 4 4 2 4;}
@font-face
{font-family:"\@SimSun";
panose-1:2 1 6 0 3 1 1 1 1 1;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0cm;
margin-bottom:.0001pt;
font-size:11.0pt;
font-family:"Calibri","sans-serif";}
a:link, span.MsoHyperlink
{mso-style-priority:99;
color:blue;
text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
{mso-style-priority:99;
color:purple;
text-decoration:underline;}
p.MsoAcetate, li.MsoAcetate, div.MsoAcetate
{mso-style-priority:99;
mso-style-link:"Balloon Text Char";
margin:0cm;
margin-bottom:.0001pt;
font-size:8.0pt;
font-family:"Tahoma","sans-serif";}
p.MsoListParagraph, li.MsoListParagraph, div.MsoListParagraph
{mso-style-priority:34;
margin-top:0cm;
margin-right:0cm;
margin-bottom:0cm;
margin-left:36.0pt;
margin-bottom:.0001pt;
font-size:11.0pt;
font-family:"Calibri","sans-serif";}
span.EmailStyle17
{mso-style-type:personal-compose;
font-family:"Calibri","sans-serif";
color:windowtext;}
span.BalloonTextChar
{mso-style-name:"Balloon Text Char";
mso-style-priority:99;
mso-style-link:"Balloon Text";
font-family:"Tahoma","sans-serif";}
.MsoChpDefault
{mso-style-type:export-only;}
@page WordSection1
{size:612.0pt 792.0pt;
margin:72.0pt 72.0pt 72.0pt 72.0pt;}
div.WordSection1
{page:WordSection1;}
/* List Definitions */
@list l0
{mso-list-id:1718047019;
mso-list-type:hybrid;
mso-list-template-ids:1709374460 67698689 67698691 67698693 67698689 67698691 67698693 67698689 67698691 67698693;}
@list l0:level1
{mso-level-number-format:bullet;
mso-level-text:\F0B7;
mso-level-tab-stop:none;
mso-level-number-position:left;
text-indent:-18.0pt;
font-family:Symbol;}
@list l0:level2
{mso-level-number-format:bullet;
mso-level-text:o;
mso-level-tab-stop:none;
mso-level-number-position:left;
text-indent:-18.0pt;
font-family:"Courier New";}
@list l0:level3
{mso-level-number-format:bullet;
mso-level-text:\F0A7;
mso-level-tab-stop:none;
mso-level-number-position:left;
text-indent:-18.0pt;
font-family:Wingdings;}
@list l0:level4
{mso-level-number-format:bullet;
mso-level-text:\F0B7;
mso-level-tab-stop:none;
mso-level-number-position:left;
text-indent:-18.0pt;
font-family:Symbol;}
@list l0:level5
{mso-level-number-format:bullet;
mso-level-text:o;
mso-level-tab-stop:none;
mso-level-number-position:left;
text-indent:-18.0pt;
font-family:"Courier New";}
@list l0:level6
{mso-level-number-format:bullet;
mso-level-text:\F0A7;
mso-level-tab-stop:none;
mso-level-number-position:left;
text-indent:-18.0pt;
font-family:Wingdings;}
@list l0:level7
{mso-level-number-format:bullet;
mso-level-text:\F0B7;
mso-level-tab-stop:none;
mso-level-number-position:left;
text-indent:-18.0pt;
font-family:Symbol;}
@list l0:level8
{mso-level-number-format:bullet;
mso-level-text:o;
mso-level-tab-stop:none;
mso-level-number-position:left;
text-indent:-18.0pt;
font-family:"Courier New";}
@list l0:level9
{mso-level-number-format:bullet;
mso-level-text:\F0A7;
mso-level-tab-stop:none;
mso-level-number-position:left;
text-indent:-18.0pt;
font-family:Wingdings;}
ol
{margin-bottom:0cm;}
ul
{margin-bottom:0cm;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]--></head><body lang=EN-US link=blue vlink=purple><div class=WordSection1><p class=MsoNormal><span lang=HU>Hello,<o:p></o:p></span></p><p class=MsoNormal><span lang=HU><o:p> </o:p></span></p><p class=MsoNormal><span lang=HU>I am having a hard time configuring a relatively simple mysql environment.<o:p></o:p></span></p><p class=MsoNormal><span lang=HU><o:p> </o:p></span></p><p class=MsoNormal><span lang=HU>What I</span><span lang=HU style='mso-fareast-language:ZH-CN'>’d like to achieve is:<o:p></o:p></span></p><p class=MsoListParagraph style='text-indent:-18.0pt;mso-list:l0 level1 lfo1'><![if !supportLists]><span lang=HU style='font-family:Symbol;mso-fareast-language:ZH-CN'><span style='mso-list:Ignore'>·<span style='font:7.0pt "Times New Roman"'> </span></span></span><![endif]><span lang=HU style='mso-fareast-language:ZH-CN'>One master and a slave, with replication<o:p></o:p></span></p><p class=MsoListParagraph style='text-indent:-18.0pt;mso-list:l0 level1 lfo1'><![if !supportLists]><span lang=HU style='font-family:Symbol;mso-fareast-language:ZH-CN'><span style='mso-list:Ignore'>·<span style='font:7.0pt "Times New Roman"'> </span></span></span><![endif]><span lang=HU style='mso-fareast-language:ZH-CN'>Relatively quick failover if the master node, or Mysql fail.<o:p></o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'><o:p> </o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'>I tried the Mysql cluster approach, but seemed to be too slow, and to many limitations (foreign keys, triggers, views, etc).<o:p></o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'><o:p> </o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'>I decided to go with the Mysql replication. <o:p></o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'>Tried to use the mysql RA from clusterlabs 3.9.2 – but no luck, replicaiton simply did not work out.<o:p></o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'><o:p> </o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'>The I tried the circular master/master replicaiton approach described in <o:p></o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'><o:p> </o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'><a href="http://www.clusterlabs.org/wiki/Load_Balanced_MySQL_Replicated_Cluster">http://www.clusterlabs.org/wiki/Load_Balanced_MySQL_Replicated_Cluster</a><o:p></o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'><o:p> </o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'>This gave the best results so far, BUT.<o:p></o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'><o:p> </o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'>With this approach, the VIP is floating over the two nodes and if mysql fails ont he node where the VIP is assigned, i am left without mysql<o:p></o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'><o:p> </o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'>I read through all the archives and I did not find anyone else with this problem – is that possible? For me this seemed to be a very basic setup.<o:p></o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'><o:p> </o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'>My question is: if i follow the circular Master/master replication approach, how can I make sure that the VIP is active on a node where I actually have a healty mysql running? Unfortunately i cannot reference a particular member of a clone.<o:p></o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'><o:p> </o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'>My config is:<o:p></o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'><o:p> </o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'>node db1 \<o:p></o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'> attributes IP="10.100.1.31" standby="off"<o:p></o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'>node db2 \<o:p></o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'> attributes IP="10.100.1.32" standby="off"<o:p></o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'>primitive mysql ocf:heartbeat:mysql \<o:p></o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'> params binary="/usr/bin/mysqld_safe" config="/etc/mysql/my.cnf" datadir="/var/lib/mysql" user="mysql" pid="/var/run/mysqld/mysqld.pid" socket="/var/run/mysqld/mysqld.sock" test_passwd="pass" test_table="replicatest.connectioncheck" test_user="slave_user" \<o:p></o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'> op start interval="0" timeout="120s" \<o:p></o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'> op stop interval="0" timeout="120s" \<o:p></o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'> op monitor interval="10" timeout="30s" \<o:p></o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'> meta migration-threshold="10"<o:p></o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'>primitive vip ocf:heartbeat:IPaddr2 \<o:p></o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'> params lvs_support="true" ip="10.100.1.30" cidr_netmask="8" broadcast="10.255.255.255" \<o:p></o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'> op monitor interval="20s" timeout="20s" \<o:p></o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'> meta migration-threshold="10"<o:p></o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'>clone cl_mysql mysql \<o:p></o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'> meta clone-max="2"<o:p></o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'>property $id="cib-bootstrap-options" \<o:p></o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'> dc-version="1.0.9-74392a28b7f31d7ddc86689598bd23114f58978b" \<o:p></o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'> cluster-infrastructure="openais" \<o:p></o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'> expected-quorum-votes="2" \<o:p></o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'> stonith-enabled="false"<o:p></o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'><o:p> </o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'><o:p> </o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'><o:p> </o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'>Thank you in advance!<o:p></o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'><o:p> </o:p></span></p><p class=MsoNormal><span lang=HU style='mso-fareast-language:ZH-CN'>Attila<o:p></o:p></span></p></div></body></html>