[SCM] Samba Shared Repository - branch master updated
Martin Schwenke
martins at samba.org
Fri Mar 17 13:06:02 UTC 2017
The branch, master has been updated
via ad758cb ctdb-readonly: Avoid a tight loop waiting for revoke to complete
from da5e256 winbindd: remove trailing spaces in get_cache()
https://git.samba.org/?p=samba.git;a=shortlog;h=master
- Log -----------------------------------------------------------------
commit ad758cb869ac83534993caa212abc9fe9905ec68
Author: Amitay Isaacs <amitay at gmail.com>
Date: Tue Mar 14 16:12:55 2017 +1100
ctdb-readonly: Avoid a tight loop waiting for revoke to complete
BUG: https://bugzilla.samba.org/show_bug.cgi?id=12697
During revoking readonly delegations, if one of the nodes disappears, then
there is no point re-trying revoking readonly delegation. The database
needs to be recovered before the revoke operation can succeed. So retry
only after a grace period.
Signed-off-by: Amitay Isaacs <amitay at gmail.com>
Reviewed-by: Martin Schwenke <martin at meltin.net>
Autobuild-User(master): Martin Schwenke <martins at samba.org>
Autobuild-Date(master): Fri Mar 17 14:05:57 CET 2017 on sn-devel-144
-----------------------------------------------------------------------
Summary of changes:
ctdb/server/ctdb_call.c | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)
Changeset truncated at 500 lines:
diff --git a/ctdb/server/ctdb_call.c b/ctdb/server/ctdb_call.c
index a05ec1a..8ce3928 100644
--- a/ctdb/server/ctdb_call.c
+++ b/ctdb/server/ctdb_call.c
@@ -1600,7 +1600,6 @@ static int deferred_call_destructor(struct revokechild_deferred_call *deferred_c
{
struct ctdb_context *ctdb = deferred_call->ctdb;
struct revokechild_requeue_handle *requeue_handle = talloc(ctdb, struct revokechild_requeue_handle);
- struct ctdb_req_call_old *c = (struct ctdb_req_call_old *)deferred_call->hdr;
requeue_handle->ctdb = ctdb;
requeue_handle->hdr = deferred_call->hdr;
@@ -1608,9 +1607,12 @@ static int deferred_call_destructor(struct revokechild_deferred_call *deferred_c
requeue_handle->ctx = deferred_call->ctx;
talloc_steal(requeue_handle, requeue_handle->hdr);
- /* when revoking, any READONLY requests have 1 second grace to let read/write finish first */
+ /* Always delay revoke requests. Either wait for the read/write
+ * operation to complete, or if revoking failed wait for recovery to
+ * complete
+ */
tevent_add_timer(ctdb->ev, requeue_handle,
- timeval_current_ofs(c->flags & CTDB_WANT_READONLY ? 1 : 0, 0),
+ timeval_current_ofs(1, 0),
deferred_call_requeue, requeue_handle);
return 0;
--
Samba Shared Repository
More information about the samba-cvs
mailing list