bind9 dns troubles

Scott Schulz swschulz at astrum.com
Fri Jul 15 17:15:36 UTC 2016


On 15 Jul 2016, at 12:43, Bob wrote:

> Thanks Peter, the zone files check out 'ok' now when I check them. I 
> have another issue though that is not resolved. I cannot access my 
> domain from outside my network. I did nslookup and it returned a 
> 'cannot find' message

That’s because you haven’t defined an IP for the bare domain 
(faithwalk.ca), and that also causes the lookup of an address for 
www.faithwalk.ca to eventually fail, although you have it CNAME’d to 
faithwalk.ca.

Remember anything in the bind file which does not have a final period 
will have the domain appended to it, so this was either a typo (see 
below [1]) in which you forgot the final period, or an oversight.  What 
this means, is that you’ve actually defined faithwalk.ca.faithwalk.ca 
(which does resolve [2]).

So you have two choices: 1) Simply append the period to the 
faithwalk.ca. name where mentioned, or (my preference), simply give it 
an address earlier in the config (as part of @ [3]) and remove the 
now-redundant later definition.

At the bottom of this email, you’ll find a complete zone file.

S


>> $TTL 3600
>> @       IN     SOA    server.faithwalk.ca. bob.faithwalk.ca. (
… snipped …
>>         ; Name Server
>>         IN      NS      server.faithwalk.ca.   ; Primary server
>>         IN      NS      ns0.xname.org.  ; non-local server xname 1
… snipped …
>>
>>         ; Mail Exchanger
>>         IN      MX      10 mail.faithwalk.ca. ; faithwalk mail

[3] here, e.g.
			IN	A 		24.72.66.135

>>
>> ;dns
>> server                          IN A            24.72.66.135
>> ns0                             IN A            195.234.42.1
>> ns1                             IN A            178.22.255.252
>> ns2                             IN A            88.191.64.64
>>
>> ;Machine names
>> faithwalk.ca                    IN A            24.72.66.135

[1] Missing period ^, i.e. should be:
faithwalk.ca. 		IN A		24.72.66.135

[2]  dig @24.72.66.135 faithwalk.ca.faithwalk.ca

; <<>> DiG 9.8.3-P1 <<>> @24.72.66.135 faithwalk.ca.faithwalk.ca
; (1 server found)
;; global options: +cmd
;; Got answer:

;; QUESTION SECTION:
;faithwalk.ca.faithwalk.ca.	IN	A

;; ANSWER SECTION:
faithwalk.ca.faithwalk.ca. 3600	IN	A	24.72.66.135


[4]  === Complete Zone ===

$TTL 3600
@       IN     SOA    server.faithwalk.ca. bob.faithwalk.ca. (
                                 2016071502  ; Serial
                                 3H          ; refresh after 3 hours
                                 1H          ; retry after 1 hour
                                 1W          ; expire after 1 week
                                 1D)         ; minimum TTL of 1 day

         ; Name Server
         IN      NS      server.faithwalk.ca.   ; Primary server
         IN      NS      ns0.xname.org.  ; non-local server xname 1
         IN      NS      ns1.xname.org.  ; non-local server xname 2
         IN      NS      ns2.xname.org.  ; non-local server xname 3

         ; Mail Exchanger
         IN      MX      10 mail.faithwalk.ca. ; faithwalk mail

         IN      A       24.72.66.135		; this provides an address for
                                           ; @ e.g. faithwalk.ca

;dns
server                          IN A            24.72.66.135
ns0                             IN A            195.234.42.1
ns1                             IN A            178.22.255.252
ns2                             IN A            88.191.64.64

;Machine names
server                          IN A            24.72.66.135
mail                            IN A            24.72.66.135

;aliases
www                      IN CNAME                faithwalk.ca.
;mail                    IN CNAME                faithwalk.ca.



More information about the ubuntu-users mailing list