systemd-resolve에서 DNS 옵션을 제거하는 방법

systemd-resolve에서 DNS 옵션을 제거하는 방법

연결할 때 resolvconf가 찾는 DNS 옵션 목록을 변경하는 방법을 잘 모르겠습니다. systemd-resolve --status산출

Global
         Protocols: -LLMNR -mDNS +DNSOverTLS DNSSEC=no/unsupported
  resolv.conf mode: foreign
Current DNS Server: serverine
       DNS Servers: serverone
                    serveronev6
                    servertwo
                    servertwov6

Link 2 (wlp0s20f3)
    Current Scopes: DNS
         Protocols: +DefaultRoute +LLMNR -mDNS +DNSOverTLS DNSSEC=no/unsupported
Current DNS Server: 8.8.4.4
       DNS Servers: 8.8.8.8 8.8.4.4

그리고 cat /run/systemd/resolve/resolv.conf출력:

# This is /run/systemd/resolve/resolv.conf managed by man:systemd-resolved(8).
# Do not edit.
#
# This file might be symlinked as /etc/resolv.conf. If you're looking at
# /etc/resolv.conf and seeing this text, you have followed the symlink.
#
# This is a dynamic resolv.conf file for connecting local clients directly to
# all known uplink DNS servers. This file lists all configured search domains.
#
# Third party programs should typically not access this file directly, but only
# through the symlink at /etc/resolv.conf. To manage man:resolv.conf(5) in a
# different way, replace this symlink by a static file or a different symlink.
#
# See man:systemd-resolved.service(8) for details about the supported modes of
# operation for /etc/resolv.conf.

nameserver serverone
nameserver serveronev6
nameserver servertwo
# Too many DNS servers configured, the following entries may be ignored.
nameserver servertwov6
nameserver 8.8.8.8
nameserver 8.8.4.4
search .

서버 1과 서버 2는 제가 사용하려는 두 개의 DNS 서버이고, v6은 ipv6 주소입니다. link2에서 google dns 옵션을 제거하고 전역적으로 사용하고 싶습니다. 이를 달성하려면 systemd-resolve를 어떻게 사용합니까?

답변1

/etc/systemd/resolved.conf의 DNS= 설정을 사용하여 적절한 네임서버를 설정해야 합니다.

resolv.conf는solved에 의해 전적으로 관리되므로 편집하면 안 됩니다.

관련 정보