From bad98e37e7e4077a74c7b32d74499c78810192c5 Mon Sep 17 00:00:00 2001 From: Volker Lendecke Date: Wed, 29 Sep 2010 12:17:05 +0200 Subject: s3: Add "smbcontrol winbindd ip-dropped " This is supposed to improve the winbind reconnect time after an ip address has been moved away from a box. Any kind of HA scenario will benefit from this, because winbindd does not have to wait for the TCP timeout to kick in when a local IP address has been dropped and DC replies are not received anymore. --- source3/winbindd/winbindd_dual.c | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) (limited to 'source3/winbindd/winbindd_dual.c') diff --git a/source3/winbindd/winbindd_dual.c b/source3/winbindd/winbindd_dual.c index 931ec6787a..a6cc64a7b5 100644 --- a/source3/winbindd/winbindd_dual.c +++ b/source3/winbindd/winbindd_dual.c @@ -1295,6 +1295,10 @@ static bool fork_domain_child(struct winbindd_child *child) MSG_DUMP_EVENT_LIST, child_msg_dump_event_list); messaging_register(winbind_messaging_context(), NULL, MSG_DEBUG, debug_message); + messaging_register(winbind_messaging_context(), NULL, + MSG_WINBIND_IP_DROPPED, + winbind_msg_ip_dropped); + primary_domain = find_our_domain(); @@ -1486,3 +1490,21 @@ static bool fork_domain_child(struct winbindd_child *child) TALLOC_FREE(frame); } } + +void winbind_msg_ip_dropped_parent(struct messaging_context *msg_ctx, + void *private_data, + uint32_t msg_type, + struct server_id server_id, + DATA_BLOB *data) +{ + struct winbindd_child *child; + + winbind_msg_ip_dropped(msg_ctx, private_data, msg_type, + server_id, data); + + + for (child = winbindd_children; child != NULL; child = child->next) { + messaging_send_buf(msg_ctx, pid_to_procid(child->pid), + msg_type, data->data, data->length); + } +} -- cgit