From ab4c0508e9a298db78c72bf4b586704d6e97697d Mon Sep 17 00:00:00 2001 From: Pavel Březina Date: Jun 21 2013 12:12:55 +0000 Subject: failover: if expanded server is marked as neutral, invoke srv collapse https://fedorahosted.org/sssd/ticket/1947 Otherwise we will do the SRV expansion once again: 1. leaving the old servers in server list 2. meta server is not inserted back in the list, the newly found servers are inserted behind meta server, meta server is orphaned and the new servers are forgotten --- diff --git a/src/providers/fail_over.c b/src/providers/fail_over.c index 47bbd82..17ebbf4 100644 --- a/src/providers/fail_over.c +++ b/src/providers/fail_over.c @@ -1111,6 +1111,13 @@ resolve_srv_send(TALLOC_CTX *mem_ctx, struct tevent_context *ev, * query collapsed * */ case SRV_NEUTRAL: /* Request SRV lookup */ + if (server != NULL && server != state->meta) { + /* A server created by expansion of meta server was marked as + * neutral. We have to collapse the servers and issue new + * SRV resolution. */ + state->meta = collapse_srv_lookup(&server); + } + if (state->meta->srv_data->dns_domain == NULL) { /* we need to look up our DNS domain first */ DEBUG(SSSDBG_TRACE_FUNC,