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)
committerAmitay Isaacs <amitay@gmail.com>
Thu, 14 Aug 2014 01:03:02 +0000 (11:03 +1000)
commit8067abcf3e1f2585cbfc63d3af978f6abdfe4ba0
treef4feee052e06a8e1990848390908d56e2aabb455
parent5a265c87ecf89ffaa5a73409abd70024b97f04b5
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

(Imported from commit c6d0e8dadcff55ea21973f4f7a89f241180d17e8)
server/ctdb_call.c