When it comes to dns, you will always think of bind. Although bind is powerful, it is too complicated and it is a headache for configuration. Killing a chicken with a knife is not a zombie, but a fear that the knife will hurt your feet. Dnsmasq is much easier to use than the dns ancestor bind. It can be used as a forward dns proxy or an internal pure dns server. Install apt-g in debianubuntu
When it comes to dns, you will always think of bind. Although bind is powerful, it is too complicated and it is a headache for configuration. Killing a chicken with a knife is not a zombie, but a fear that the knife will hurt your feet. Dnsmasq is much easier to use than the dns ancestor bind. It can be used as a forward dns proxy or an internal pure dns server.
Install In debian/ubuntu
Apt-get install dnsmasq
Configuration
Vi/etc/dnsmasq. conf
Under the default configuration, dnsmasq uses the system's/etc/resolv. conf and reads/etc/hosts. You can change or disable it in the configuration. Now you have modified the two,
Other Default values:
Resolv-File=/Etc/dnsmasq. resolv. conf
ADdN-hosts =/etc/dnsmasq. hosts
(Dnsmasq also supports dhCpService, but generally do not need to handle it)
Dnsmasq can use the hosts file to set the Domain Name:
Example: test.SuDone.com is a non-existent domain name. I point to an ip address in dnsmasq:
Echo 64.233.189.99 test.sudone.com>/etc/dnsmasq. hosts
Restart after modification
/Etc/init. d/dnsmasq restart
After that, you only need to point the local dns to the dnsmasq machine.PingTo test.sudone.com.