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/utils/smbcontrol.c | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) (limited to 'source3/utils') diff --git a/source3/utils/smbcontrol.c b/source3/utils/smbcontrol.c index e24add0050..998971dfa2 100644 --- a/source3/utils/smbcontrol.c +++ b/source3/utils/smbcontrol.c @@ -726,6 +726,22 @@ static bool do_closeshare(struct messaging_context *msg_ctx, strlen(argv[1]) + 1); } +/* Tell winbindd an IP got dropped */ + +static bool do_ip_dropped(struct messaging_context *msg_ctx, + const struct server_id pid, + const int argc, const char **argv) +{ + if (argc != 2) { + fprintf(stderr, "Usage: smbcontrol ip-dropped " + "\n"); + return False; + } + + return send_message(msg_ctx, pid, MSG_WINBIND_IP_DROPPED, argv[1], + strlen(argv[1]) + 1); +} + /* force a blocking lock retry */ static bool do_lockretry(struct messaging_context *msg_ctx, @@ -1196,6 +1212,7 @@ static const struct { { "debuglevel", do_debuglevel, "Display current debuglevels" }, { "printnotify", do_printnotify, "Send a print notify message" }, { "close-share", do_closeshare, "Forcibly disconnect a share" }, + { "ip-dropped", do_ip_dropped, "Tell winbind that an IP got dropped" }, { "lockretry", do_lockretry, "Force a blocking lock retry" }, { "brl-revalidate", do_brl_revalidate, "Revalidate all brl entries" }, { "samsync", do_samsync, "Initiate SAM synchronisation" }, -- cgit