Shutdown mysql when replication failed.