activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Torsten Mielke <>
Subject Re: MySQL active/passive cluster not recovering from master power failure
Date Fri, 30 Sep 2011 11:45:29 GMT
How did you simulate such error? 
I have tested JDBC master/slave in the past and killed -9 the master. The lock on the database
was released immediately and so the slave was able to take over.

Have never simulated a kernel panic though.
Do you use a default MySQL configuration?

Torsten Mielke


On Sep 30, 2011, at 12:54 PM, R.I.Pienaar wrote:

> hello,
> I have a active/passive setup using a mysql datastore:
>    <bean id="mysql-ds" class="org.apache.commons.dbcp.BasicDataSource" destroy-method="close">
>       <property name="driverClassName" value="com.mysql.jdbc.Driver"/>
>       <property name="url" value="jdbc:mysql://jmsdb1/activemq?relaxAutoCommit=true"/>
>       <property name="username" value="activemq"/>
>       <property name="password" value="xx"/>
>       <property name="poolPreparedStatements" value="true"/>
>     </bean>
> this works fine, one of the pair is master and one is slave based on the 
> lock contention on the table.
> When the master fails - like with a power failure or a kernel panic - the lock
> does not get released though.  Even through a restart of the server the lock
> do not get released.  If we just cleanly shut down the master like for maintenance
> then it is all good.
> After restart when the server eventually came back up it re-acquired the lock and
> was again the master.
> Failover never happened.  Is there some tunable setting or advice you can give on 
> improving this setup to be better resilient to failure of this nature?
> -- 
> R.I.Pienaar

View raw message