[PATCH] Fix ctdb tool command restoredb

Amitay Isaacs amitay at gmail.com
Thu Jul 3 20:30:22 MDT 2014


Correct way to trigger recovery is to set recovery mode to active.  This
decouples the logic of detecting database recoveries from the freeze state
of databases.  CTDB tool commands such as wipedb/restoredb freeze databases
to ensure that no client can get inconsistent view of database while these
operations are in progress.

However, due to inconsistency in the way recovery state was detected,
whenever databases were frozen for restoredb, database recovery was
triggered overriding restoredb operation and sometimes thawing database
prematurely while recovery is in progress.

This patch series makes the logic for active recovery detection consistent
and adds extra check before thawing databases.  Also, a test is added to
ensure restoredb command works correctly.

The patches are attached and are available in my ctdb-recover branch.


Please review and push if ok.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: ctdb.patches
Type: application/octet-stream
Size: 14497 bytes
Desc: not available
URL: <http://lists.samba.org/pipermail/samba-technical/attachments/20140704/66a6ecfc/attachment.obj>

More information about the samba-technical mailing list