peerdns in Linux is a network interface configuration option: 1. When set to yes, the system will use the DNS server obtained through DHCP to resolve domain names; 2. When set to no, the system will use other configuration methods DNS server or manually configured DNS server to resolve domain names.
The operating system of this tutorial: Linux5.18.14 system, Dell G3 computer.
In Linux, peersdns is a network interface configuration option that specifies whether to obtain the DNS server address through DHCP (Dynamic Host Configuration Protocol).
When peersdns is set to yes, the network interface automatically adds the DNS server address obtained from the DHCP server to the system's DNS resolver list. This means that the system will use DNS servers obtained via DHCP to resolve domain names.
When peersdns is set to no, the network interface will not add DNS server addresses obtained via DHCP to the system's DNS resolver list. This means that the system will use an otherwise configured DNS server or a manually configured DNS server to resolve domain names.
In most cases, setting peersdns to yes can conveniently use the DNS server provided by the DHCP server to ensure that the network connection is normal and the domain name can be resolved correctly. But in some cases, it may be necessary to manually configure the DNS server, or use other methods to obtain the DNS server address without relying on the settings provided by the DHCP server.
The above is the detailed content of what is peerdns in linux. For more information, please follow other related articles on the PHP Chinese website!