<table cellspacing="0" cellpadding="0" border="0" ><tr><td valign="top" style="font: inherit;"><blockquote style="border-left: 2px solid rgb(16, 16, 255); margin-left: 5px; padding-left: 5px;"><div class="plainMail"><br>> >> Liang Ma<br>> >> Contractuel | Consultant | SED Systems Inc.<br>> >> Ground Systems Analyst<br>> >> Agence spatiale canadienne | Canadian Space Agency<br>> >> 6767, Route de l'A?roport, Longueuil (St-Hubert), QC, Canada, J3Y 8Y9<br>> >> T?l/Tel : (450) 926-5099 | T?l?c/Fax: (450) 926-5083<br>> >> Courriel/E-mail : [liang.ma <<a href="http://liang.ma" target="_blank">http://liang.ma</a>>@space.gc.ca<br>> <<a href="http://space.gc.ca"
target="_blank">http://space.gc.ca</a>>]<br>> >> Site web/Web site : [www.space.gc.ca <<a href="http://www.space.gc.ca" target="_blank">http://www.space.gc.ca</a>> ]<br>> >><br>> >><br>> >><br>> >><br>> >> -----Original Message-----<br>> >> From: Dejan Muhamedagic [mailto:<a ymailto="mailto:dejanmm@fastmail.fm" href="/mc/compose?to=dejanmm@fastmail.fm">dejanmm@fastmail.fm</a><br>> <mailto:<a ymailto="mailto:dejanmm@fastmail.fm" href="/mc/compose?to=dejanmm@fastmail.fm">dejanmm@fastmail.fm</a>>]<br>> >> Sent: January 28, 2011 8:26 AM<br>> >> To: The Pacemaker cluster resource manager<br>>
>> Subject: Re: [Pacemaker] pacemaker won't start mysql in the<br>> second node<br>> >><br>> >> Hi,<br>> >><br>> >> On Thu, Jan 27, 2011 at 11:51:31AM -0500, <a ymailto="mailto:Liang.Ma@asc-csa.gc.ca" href="/mc/compose?to=Liang.Ma@asc-csa.gc.ca">Liang.Ma@asc-csa.gc.ca</a><br>> <mailto:<a ymailto="mailto:Liang.Ma@asc-csa.gc.ca" href="/mc/compose?to=Liang.Ma@asc-csa.gc.ca">Liang.Ma@asc-csa.gc.ca</a>> wrote:<br>> >>><br>> >>><br>> >>> Hi There,<br>> >>></div><div class="plainMail"><br></div><div class="plainMail"><br></div><div class="plainMail">HI your LAMP is linux+apache+mysql+php?</div><div
class="plainMail"><br>> >>> I have set up a pair of ha LAMP servers using heartbeat,<br>> pacemaker and<br>> >>> drbd on Ubuntu 10.04 LTS. Everything works fine until I upgraded<br>> >>> mysql-server from 5.1.41-3ubuntu12.6 to 5.1.41-3ubuntu12.9. Now<br>> node 1<br>> >>> (arsvr1) works still fine, but mysql on node 2 (arsvr2) won't start<br>> >>> when I switch arsvr1 standby. The error message shown from "crm<br>> >>> status" is<br>> >>><br>> >>> Failed actions:<br>> >>> mysql_start_0 (node=arsvr2, call=32, rc=4, status=complete):<br>> >>>
insufficient privileges<br>> >>><br>> >>> No errors logged in /var/log/mysql/error.log at all.<br>> >><br>> >> I think that you should check directory permissions. The log<br>> >> file should give you a hint.<br>> >><br>> >> Thanks,<br>> >><br>> >> Dejan<br>> >><br>> >><br>> >>> drbd mysql partition mounted properly. If I go to<br>> >>> /usr/lib/ocf/resource.d/heartbeat and set the OCF_RESKEY<br>> parameters, I<br>> >>> have no problem to start mysql server
by "./mysql start". But the<br>> >>> resource mysql won't show up in crm status.<br>> >>><br>> >>> So looks somehow pacemaker fail to start resource mysql even before<br>> >>> running the resource script.<br>> >>><br>> >>> Here is the configuration<br>> >>><br>> >>> node $id="bc6bf61d-6b5f-4307-85f3-bf7bb11531bb" arsvr2 \<br>> >>> attributes standby="off"<br>> >>> node $id="bf0e7394-9684-42b9-893b-5a9a6ecddd7e" arsvr1 \<br>> >>> attributes standby="off"<br>> >>> primitive apache2
lsb:apache2 \<br>> >>> op start interval="0" timeout="60" \<br>> >>> op stop interval="0" timeout="120" start-delay="15" \<br>> >>> meta target-role="Started"<br>> >>> primitive drbd_mysql ocf:linbit:drbd \<br>> >>> params drbd_resource="r0" \<br>> >>> op monitor interval="15s"<br>> >>> primitive drbd_webfs ocf:linbit:drbd \<br>> >>> params drbd_resource="r1" \<br>> >>> op monitor interval="15s" \<br>> >>> op
start interval="0" timeout="240" \<br>> >>> op stop interval="0" timeout="100"<br>> >>> primitive fs_mysql ocf:heartbeat:Filesystem \<br>> >>> params device="/dev/drbd/by-res/r0"<br>> directory="/var/lib/mysql" fstype="ext4" \<br>> >>> op start interval="0" timeout="60" \<br>> >>> op stop interval="0" timeout="120" \<br>> >>> meta target-role="Started"<br>> >>> primitive fs_webfs ocf:heartbeat:Filesystem \<br>> >>> params device="/dev/drbd/by-res/r1" directory="/srv"<br>>
fstype="ext4" \<br>> >>> op start interval="0" timeout="60" \<br>> >>> op stop interval="0" timeout="120" \<br>> >>> meta target-role="Started"<br>> >>> primitive ip1 ocf:heartbeat:IPaddr2 \<br>> >>> params ip="10.10.10.193" nic="eth0" \<br>> >>> op monitor interval="5s"<br>> >>> primitive ip1arp ocf:heartbeat:SendArp \<br>> >>> params ip="10.10.10.193" nic="eth0"<br>> >>> primitive mysql ocf:heartbeat:mysql \<br>> >>>
params binary="/usr/bin/mysqld_safe" config="/etc/mysql/my.cnf"<br>> >>> user="mysql" group="mysql" log="/var/log/mysql.log"<br>> >>> pid="/var/run/mysqld/mysqld.pid" datadir="/var/lib/mysql"<br>> >>> socket="/var/run/mysqld/mysqld.sock" \<br>> >>> op monitor interval="30s" timeout="30s" \<br>> >>> op start interval="0" timeout="120" \<br>> >>> op stop interval="0" timeout="120" \<br>> >>> meta target-role="Started"<br>> >>> group MySQLDB fs_mysql mysql \<br>> >>> meta
target-role="Started"<br>> >>> group WebServices ip1 ip1arp fs_webfs apache2 \<br>> >>> meta target-role="Started"<br>> >>> ms ms_drbd_mysql drbd_mysql \<br>> >>> meta master-max="1" master-node-max="1" clone-max="2"<br>> >>> clone-node-max="1" notify="true"<br>> >>> ms ms_drbd_webfs drbd_webfs \<br>> >>> meta master-max="1" master-node-max="1" clone-max="2"<br>> >>> clone-node-max="1" notify="true" target-role="Started"<br>> >>> colocation apache2_with_ip inf: apache2 ip1<br>> >>> colocation apache2_with_mysql inf: apache2
ms_drbd_mysql:Master<br>> >>> colocation apache2_with_webfs inf: apache2 ms_drbd_webfs:Master<br>> >>> colocation fs_on_drbd inf: fs_mysql ms_drbd_mysql:Master<br>> >>> colocation ip_with_ip_arp inf: ip1 ip1arp<br>> >>> colocation mysql_on_drbd inf: MySQLDB ms_drbd_mysql:Master<br>> >>> colocation web_with_mysql inf: MySQLDB WebServices<br>> >>> colocation webfs_on_drbd inf: fs_webfs ms_drbd_webfs:Master<br>> >>> colocation webfs_with_fs inf: fs_webfs fs_mysql<br>> >>> order apache2-after-arp inf: ip1arp:start apache2:start<br>> >>> order arp-after-ip inf: ip1:start ip1arp:start<br>> >>> order
fs-mysql-after-drbd inf: ms_drbd_mysql:promote fs_mysql:start<br><br></div></blockquote></td></tr></table><br>