[Pacemaker] Monitor and standby

Lars Ellenberg lars.ellenberg at linbit.com
Wed Jul 3 10:35:34 UTC 2013


On Wed, Jul 03, 2013 at 12:21:37PM +0200, Denis Witt wrote:
> Hi List,
> 
> we have a two node cluster (test1-node1, test1-node2) with an additional
> quorum node (test1). On all nodes MySQL is running. test1-node1 and
> test1-node2 sharing the MySQL-Database via DRBD, so only one Node
> should run MySQL. On test1 there is a MySQL-Slave connected to
> test1-node1/test1-node2. test1 is always in Standby-Mode.
> 
> The problem is now that the MySQL-Slave on test1 is shut down by crmd:
> 
> Jul  3 12:05:12 test2 crmd: [5945]: info: te_rsc_command: Initiating action 22: monitor p_mysql_monitor_0 on test2 (local)
> Jul  3 12:05:14 test2 pengine: [5944]: ERROR: native_create_actions: Resource p_mysql (lsb::mysql) is active on 2 nodes attempting recovery


There.
init script status action told pacemaker that mysql was running on both
nodes, pacemaker was told it should run only once.
pacemaker "recovers" by stopping both and starting one.

> Jul  3 12:05:14 test2 pengine: [5944]: notice: LogActions: Restart p_mysql#011(Started test2-node1)
> Jul  3 12:05:15 test2 crmd: [5945]: info: te_rsc_command: Initiating action 54: stop p_mysql_stop_0 on test2 (local)
> 
> From my understanding this shouldn't happen as test1 was set to standby
> before:
> 
> Jul  3 12:04:48 test2 cib: [5940]: info: cib:diff: +           <nvpair id="nodes-test2-standby" name="standby" value="on" />
> 
> How could we solve this?

use the mysql RA with proper parameters, so it won't get confused by a
different instance of mysql.

Or fix the init script status action to be able to distinguish between
the "cluster" mysql instance, and your "other" mysql instance.

Note that a pacemaker node in "standby" is supposed to not run any
resources, so if it notices that DRBD is "running" there (in Secondary),
it will stop it, too.

Maybe you and pacemaker disagree about the meaning of "standby"?


-- 
: Lars Ellenberg
: LINBIT | Your Way to High Availability
: DRBD/HA support and consulting http://www.linbit.com

DRBD® and LINBIT® are registered trademarks of LINBIT, Austria.




More information about the Pacemaker mailing list