Configuring the DNS service of the cloud server is indispensable for the cloud server to access the public domain name. DNS is the record of the domain name pointing to the IP. Only by setting up the DNS server can the public network resolution record of the domain name be obtained.
The local DNS server configuration information is stored in the file /etc/resolv.conf. Write the following DNS configuration in the configuration information
nameserver 8.8.8.8 nameserver 114.114.114.114
In this way, two default dns servers are successfully set and saved. Effective immediately.
If you need to specify the resolution record of a certain domain name, you need to use the /etc/hosts file and write
ip地址 空格 域名
in the configuration information to manually specify the resolution IP of the domain name.
Linux versions include: Deepin, UbuntuKylin, Manjaro, LinuxMint, Ubuntu and other versions. Among them, Deepin is one of the best-developed Linux distributions in China; Ubuntu Kylin is a derivative distribution based on Ubuntu; Manjaro is a Linux distribution based on Arch; LinuxMint's default Cinnamon desktop is similar to Windows XP and is simple and easy to use; Ubuntu is a desktop application Mainly Linux operating system.
The above is the detailed content of How to manually configure DNS for Linux cloud server. For more information, please follow other related articles on the PHP Chinese website!