← Back to team overview

maria-discuss team mailing list archive

Re: Mariadb 10.1.6, total cluster recovery - gvwstate.dat


Hi Max,

On Wed, Aug 19, 2015 at 9:40 AM, Max Zulio <zulioexpress@xxxxxxxxx> wrote:
> If I kill -9 mysqld on all three of my nodes in the cluster, then start the
> services simultaneously,the cluster comes back online successfully using the
> gvwstate.dat file.
> If I gracefully shutdown mysql on all three nodes as you mentioned the
> gvwstate.dat file is deleted. This means when the cluster needs to be
> restarted I am forced to edit my.cnf and replace
> wsrep_cluster_address=gcomm://x.x.x.x,y.y.y.y,z.z.z.z with
> wsrep_cluster_address=gcomm:// on one of the nodes before I can bring up the
> cluster.
> Is there anyway to have the last node that is shutdown gracefully keep it's
> gvwstate.dat file so that the next time the cluster is started it can come
> online without editing the config file?

It might not help a whole lot to only have a gvwstate.dat file on the
last node that shuts down, since that would only allow for recovering
a cluster with that single node. In that case, it would kind of be
like a shortcut to bootstrapping.

There is a feature request on Codership's Github that requests a new
wsrep_provider_option: pc.recover_minimum_weight. If that ever gets
added to Galera, that would allow you to automatically recover a
cluster after a graceful shutdown: