Simple experience of DNS server in ubuntu

Source: Internet
Author: User
In ubuntu, you can simply build a DNS server in ubuntu to understand how DNS works. 1. install the corresponding server software. The apt-getinstallbind9 installs bind92 and sets the primary server domain and domain resolution file vim/etc/bind/na...
In ubuntu, you can simply build a DNS server in ubuntu to understand how DNS works. 1. install the corresponding server software. Apt-get install bind9 install bind9 2 and set the primary server domain and domain parsing file vim/etc/bind/named. conf. local then sets the domain zone and the domain resolution file zone "linux31.com" {type master; file "db.linux31.com" ;}; www.2cto.com 3, according to the bind9 built-in template db. local modifies the content of the domain resolution file. Generally, the default storage location of the domain resolution file is/etc/var/cache/bind. we will set/ect/bind/db. copy local data to/etc/var/cache/bind and change it to db. linux31.comcp/etc/bind/db. local/var/cache/bind/db.linux31.com and then modify the template db. local content; BIND data file for local loop Back interface; $ TTL 604800 @ in soa localhost. root. localhost. (2; Serial 604800; Refresh 86400; Retry 2419200; Expire 604800); Negative Cache TTL; @ in ns localhost. @ in a 127.0.0.1 @ in aaaa: 1 ~ ~ Www.2cto.com. Generally, you don't need to modify the above content. you just need to fill in the address of your dns server (that is, the local address) below and it will be OK; BIND data file for local loopback interface; $ TTL 604800 @ in soa localhost. root. localhost. (2; Serial 604800; Refresh 86400; Retry 2419200; Expire 604800); Negative Cache TTL; @ in ns localhost. @ in a 127.0.0.1 @ in aaaa: 1 @ in a 192.168.1.116 ~ Then, save and exit, and restart bind service/etc/init. d/bind9 restart www.2cto.com 4, and then check whether DNS works. Modify the DNS option in/etc/resolv. conf on another server and set the DNS server address to 192.168.1.106 (I configured the DNS IP address). This process is easy to forget. Then, ping linux31.com on another host to check whether the host can be pinged.
Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.