User Tools

Site Tools


ubuntu:bind:test_bind9

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
ubuntu:bind:test_bind9 [2020/12/09 16:18] peterubuntu:bind:test_bind9 [2020/12/09 16:23] (current) peter
Line 62: Line 62:
 ;; Query time: 1 msec ;; Query time: 1 msec
 </code> </code>
 +
 +----
 +
 +===== ping =====
 +
 +To demonstrate how applications make use of DNS to resolve a host name use the ping utility to send an ICMP echo request:
 +
 +<code bash>
 +ping example.com
 +</code>
 +
 +This tests if the nameserver can resolve the name ns.example.com to an IP Address. The command output should resemble:
 +
 +<code bash>
 +PING ns.example.com (192.168.1.10) 56(84) bytes of data.
 +64 bytes from 192.168.1.10: icmp_seq=1 ttl=64 time=0.800 ms
 +64 bytes from 192.168.1.10: icmp_seq=2 ttl=64 time=0.813 ms
 +</code>
 +
 +----
 +
 +===== named-checkzone =====
 +
 +A great way to test your zone files is by using the **named-checkzone** utility installed with the bind9 package.
 +
 +This utility allows you to make sure the configuration is correct before restarting BIND9 and making the changes live.
 +
 +To test our example Forward zone file enter the following from a command prompt:
 +
 +<code bash>
 +named-checkzone example.com /etc/bind/db.example.com
 +</code>
 +
 +If everything is configured correctly you should see output similar to:
 +
 +<code bash>
 +zone example.com/IN: loaded serial 6
 +OK
 +</code>
 +
 +Similarly, to test the Reverse zone file enter the following:
 +
 +<code bash>
 +named-checkzone 1.168.192.in-addr.arpa /etc/bind/db.192
 +</code>
 +
 +The output should be similar to:
 +
 +<code bash>
 +zone 1.168.192.in-addr.arpa/IN: loaded serial 3
 +OK
 +</code>
 +
 +<WRAP info>
 +**NOTE:**  The Serial Number of your zone file will probably be different.
 +</WRAP>
 +
  
ubuntu/bind/test_bind9.1607530737.txt.gz · Last modified: 2020/12/09 16:18 by peter

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki