From: Ronan Pigott Date: Wed, 21 Aug 2024 13:59:22 +0000 (-0700) Subject: Revert "resolved: demote the global unicast scope" X-Git-Tag: v257-rc1~651^2~4 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=bebec8865375011cf74d3c23363d37c9ebec5c4d;p=thirdparty%2Fsystemd.git Revert "resolved: demote the global unicast scope" This commit may have been a breaking change for sd-resolved foreign resolv.conf mode, where a legacy network management daemon directly modifies resolv.conf and sd-resolved consumes that. This reverts commit eded61e410dfa6c16ae68cb624c58122fb18fd0e. --- diff --git a/man/systemd-resolved.service.xml b/man/systemd-resolved.service.xml index 34f05bd8b0a..13c0da987fe 100644 --- a/man/systemd-resolved.service.xml +++ b/man/systemd-resolved.service.xml @@ -217,10 +217,7 @@ If a query does not match any configured routing domain (either per-link or global), it is sent to all DNS servers that are configured on links with the DefaultRoute= - option set. - - If no links are configured with DefaultRoute=, it is sent to the - globally configured DNS server. + option set, as well as the globally configured DNS server. If there is no link configured as DefaultRoute= and no global DNS server configured, one of the compiled-in fallback DNS servers is used. diff --git a/src/resolve/resolved-dns-scope.c b/src/resolve/resolved-dns-scope.c index 3bb7c0aa219..21b9844e047 100644 --- a/src/resolve/resolved-dns-scope.c +++ b/src/resolve/resolved-dns-scope.c @@ -778,8 +778,7 @@ DnsScopeMatch dns_scope_good_domain( if (!dns_scope_is_default_route(s)) return DNS_SCOPE_NO; - /* Prefer suitable per-link scopes where possible */ - return s->link ? DNS_SCOPE_MAYBE : DNS_SCOPE_LAST_RESORT; + return DNS_SCOPE_MAYBE; } case DNS_PROTOCOL_MDNS: {