From 711dd5db9e1935a20158727f4a27d12a64ba48e7 Mon Sep 17 00:00:00 2001 From: Yu Watanabe Date: Sun, 19 Jul 2020 13:57:51 +0900 Subject: [PATCH] man: update explanation about the format to specify DNS servers --- man/resolvectl.xml | 23 ++++++++++++++--------- man/resolved.conf.xml | 13 +++++++++---- man/systemd.network.xml | 10 +++++++++- 3 files changed, 32 insertions(+), 14 deletions(-) diff --git a/man/resolvectl.xml b/man/resolvectl.xml index 0ae70dc34bd..a4bd8f52d77 100644 --- a/man/resolvectl.xml +++ b/man/resolvectl.xml @@ -145,15 +145,20 @@ settings for network interfaces. These commands may be used to inform systemd-resolved or systemd-networkd about per-interface DNS configuration determined through external means. The dns command expects IPv4 or - IPv6 address specifications of DNS servers to use. The domain command expects - valid DNS domains, possibly prefixed with ~, and configures a per-interface - search or route-only domain. The default-route command expects a boolean - parameter, and configures whether the link may be used as default route for DNS lookups, i.e. if it - is suitable for lookups on domains no other link explicitly is configured for. The - llmnr, mdns, dnssec and - dnsovertls commands may be used to configure the per-interface LLMNR, - MulticastDNS, DNSSEC and DNSOverTLS settings. Finally, nta command may be used - to configure additional per-interface DNSSEC NTA domains. + IPv6 address specifications of DNS servers to use. Each address can optionally take a port number + separated with :, a network interface name or index separated with + %, and a Server Name Indication (SNI) separated with #. When + IPv6 address is specified with a port number, then the address must be in the square brackets. That + is, the acceptable full formats are 111.222.333.444:9953%ifname#example.com for + IPv4 and [1111:2222::3333]:9953%ifname#example.com for IPv6. The + domain command expects valid DNS domains, possibly prefixed with + ~, and configures a per-interface search or route-only domain. The + default-route command expects a boolean parameter, and configures whether the + link may be used as default route for DNS lookups, i.e. if it is suitable for lookups on domains no + other link explicitly is configured for. The llmnr, mdns, + dnssec and dnsovertls commands may be used to configure the + per-interface LLMNR, MulticastDNS, DNSSEC and DNSOverTLS settings. Finally, nta + command may be used to configure additional per-interface DNSSEC NTA domains. Commands dns, domain and nta can take a single empty string argument to clear their respective value lists. diff --git a/man/resolved.conf.xml b/man/resolved.conf.xml index 0e7a9f4bc66..535a23f500a 100644 --- a/man/resolved.conf.xml +++ b/man/resolved.conf.xml @@ -47,8 +47,13 @@ DNS= - A space-separated list of IPv4 and IPv6 addresses to use as system DNS servers. DNS requests - are sent to one of the listed DNS servers in parallel to suitable per-link DNS servers acquired from + A space-separated list of IPv4 and IPv6 addresses to use as system DNS servers. Each address can + optionally take a port number separated with :, a network interface name or index separated with + %, and a Server Name Indication (SNI) separated with #. When IPv6 address is + specified with a port number, then the address must be in the square brackets. That is, the acceptable full formats + are 111.222.333.444:9953%ifname#example.com for IPv4 and + [1111:2222::3333]:9953%ifname#example.com for IPv6. DNS requests are sent to one of the listed + DNS servers in parallel to suitable per-link DNS servers acquired from systemd-networkd.service8 or set at runtime by external applications. For compatibility reasons, if this setting is not specified, the DNS servers listed in /etc/resolv.conf are used instead, if that file exists and any servers @@ -57,8 +62,8 @@ FallbackDNS= - A space-separated list of IPv4 and IPv6 addresses to use as the fallback DNS servers. Any - per-link DNS servers obtained from + A space-separated list of IPv4 and IPv6 addresses to use as the fallback DNS servers. Please see + DNS= for acceptable format of adddresses. Any per-link DNS servers obtained from systemd-networkd.service8 take precedence over this setting, as do any servers set via DNS= above or /etc/resolv.conf. This setting is hence only used if no other DNS server information is diff --git a/man/systemd.network.xml b/man/systemd.network.xml index 58d1f2c717f..0b0c751e913 100644 --- a/man/systemd.network.xml +++ b/man/systemd.network.xml @@ -606,7 +606,15 @@ A DNS server address, which must be in the format described in inet_pton3. - This option may be specified more than once. This setting is read by + This option may be specified more than once. Each address can optionally take a port number + separated with :, a network interface name or index separated with + %, and a Server Name Indication (SNI) separated with #. + When IPv6 address is specified with a port number, then the address must be in the square + brackets. That is, the acceptable full formats are + 111.222.333.444:9953%ifname#example.com for IPv4 and + [1111:2222::3333]:9953%ifname#example.com for IPv6. This setting can be + specified multiple times. If an empty string is assigned, then the all previous assignments + are cleared. This setting is read by systemd-resolved.service8. -- 2.47.3