ctdb-readonly: Do not abort if revoke of readonly record fails on a node
authorAmitay Isaacs <amitay@gmail.com>
Tue, 12 Aug 2014 13:58:00 +0000 (23:58 +1000)
committerMartin Schwenke <martins@samba.org>
Wed, 13 Aug 2014 09:24:09 +0000 (11:24 +0200)
commitc6d0e8dadcff55ea21973f4f7a89f241180d17e8
treeab04adbd67b6e0cccdcff98d623d6a4ef3306dde
parentf96f395d853e0181d9ee031c3e3f1d31f5cff35c
ctdb-readonly: Do not abort if revoke of readonly record fails on a node

Revoking readonly record involves first marking the record on dmaster as
RO_REVOKING_READONLY.  Then all the other nodes are sent update_record
control to get rid of RO_DELEGATION.  Once that succeeds, the record
is marked RO_REVOKING_COMPLETE.

Currently, revoking of readonly delegations on the nodes is tried only
once.  If a node goes in recovery, it can fail update_record control and
revoke code will abort ctdb.  Since database recovery would revoke all
readonly delegations anyway, there is no reason to abort.  Simply undo
the start of revoke process by resetting RO_REVOKING_READONLY flag.

Signed-off-by: Amitay Isaacs <amitay@gmail.com>
Reviewed-by: Martin Schwenke <martin@meltin.net>
Autobuild-User(master): Martin Schwenke <martins@samba.org>
Autobuild-Date(master): Wed Aug 13 11:24:09 CEST 2014 on sn-devel-104
ctdb/server/ctdb_call.c