** Description changed:
Due to ubuntu putting /var/run on a tempory fs the /var/run/mysqld directory
is removed upon a reboot. Mysql will fail to start via the crm after next boot
as it cannot access or find the the needed /var/run/mysqld directory.
This directory is created in the OCF script in the mysql_start() function ,
but for some reason not until after the script checks for the directory and
write permissions, logs an error, and exits. (Line 345)
I have fixed it by merely moving the if statement which test -w the
pid_dir to after the if statements which create the pid_dir (line 350)
+
+
+
+ SRU Justification:
+ [Impact]
+ /var/run/mysqld directory is typically created by pre-start in the mysql
upstart job prior to starting the service every boot, as /var/run is tempfs and
its contents ephemeral. Users of the Linux HA stack typically hand over
control of specific services to the cluster managed by OCF scripts. The OCF
script to manage mysql should take the same steps the required directories are
present. A bug exists in the version of the mysql OCF script shipped in
1:1.0.3-2ubuntu1 which prevents the required directories from being created if
they do not exist. If the clustered service is configured to use
/var/run/mysqld (the ubuntu default for certain files), the cluster will fail
to start mysql after a reboot. As most users of the cluster agent anticipate a
*highly* available service, graceful system reboots should not result in an
unavailable service.
+
+ [Development Fix]
+ As Florian Hass pointed out, this has been fixed upstream over a year ago and
is not present in the current development release (precise, package renamed
resource agents 1:3.9.2-5ubuntu1)
+
+
+ [Stable Fix]
+ A trivial fix at
https://github.com/ClusterLabs/resource-agents/commit/a1801207e0602d9b975f336569b562c195a6eb8a
solves the issue and is easily backported.
+
+ [Test Case]
+ See http://paste.ubuntu.com/746339/ for a minimal test case which involves
configuration of a 1-node heartbeat/pacemaker cluster.
+
+ [Regression Potential]
+ Minimal chance of regression. Change simply ensures mysql directories exist
before they are checked for write permissions. The change only affects the
mysql OCF agent, all others are untouched.
** Changed in: cluster-agents (Ubuntu Lucid)
Assignee: Adam Gandelman (gandelman-a) => (unassigned)
--
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/893352
Title:
mysql ocf script broken in 1:1.0.3-2ubuntu1 (lucid)
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/cluster-agents/+bug/893352/+subscriptions
--
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs