Linode Forum
Linode Community Forums
 FAQFAQ    SearchSearch    MembersMembers      Register Register 
 LoginLogin [ Anonymous ] 
Post new topic  Reply to topic
Author Message
 Post subject: correct master file?
PostPosted: Tue Jun 01, 2004 10:12 pm 
Offline
Senior Newbie

Joined: Mon May 31, 2004 7:44 pm
Posts: 15
I'm hoping to use bind9 to run DNS myself. It looks like I get the right IP address back from dig @65.19.178.131 brlewis.com, but never having done this before I want to be sure I'm not doing some kind of subtle screwup. Anyone see a mistake in this master file for brlewis.com?

@ IN SOA ns1.brlewis.com. (
2004060101 ; Serial (yyyymmddxx)
86400 ; Refresh (1 day)
7200 ; Retry (2 hours)
604800 ; Expire (7 days)
86400 ) ; Minimum (1 day)

IN NS ns1.brlewis.com.

brlewis.com. IN A 65.19.178.131
www IN CNAME brlewis.com.

ns1 IN A 65.19.178.131


Top
   
 Post subject: Re: correct master file?
PostPosted: Wed Jun 02, 2004 11:19 am 
Offline
Senior Member
User avatar

Joined: Tue Apr 13, 2004 6:54 pm
Posts: 833
brlewis wrote:
@ IN SOA ns1.brlewis.com. (
2004060101 ; Serial (yyyymmddxx)
86400 ; Refresh (1 day)
7200 ; Retry (2 hours)
604800 ; Expire (7 days)
86400 ) ; Minimum (1 day)


Aren't you missing an entry in this SOA record? After "ns1.brlewis.com." you need your contact address (with @ converted to .)

The format is
Code:
@ IN SOA origin mail.addr (
     serial refresh retry expire ttl)


The line beginning "brlewis.com." may be better of using @ as the name, so it references implicitly the zone you are defining (same as with the SOA record) for consistency. But that's just a matter of taste :-)

_________________
Rgds
Stephen
(Linux user since kernel version 0.11)


Top
   
 Post subject:
PostPosted: Thu Jun 03, 2004 9:26 pm 
Offline
Senior Newbie

Joined: Mon May 31, 2004 7:44 pm
Posts: 15
I'll defer to someone else's taste. My DNS needs are so normal that I don't think I need to agonize over anything, or even get a deep understanding of all the RFCs.

@ IN SOA ns1.brlewis.com. brlewis.alum.mit.edu (
2004060101 ; Serial (yyyymmddxx)
86400 ; Refresh (1 day)
7200 ; Retry (2 hours)
604800 ; Expire (7 days)
86400 ) ; Minimum (1 day)

IN NS ns1.brlewis.com.

@ IN A 65.19.178.131
www IN CNAME brlewis.com.
ns1 IN A 65.19.178.131


Top
   
 Post subject:
PostPosted: Tue Jun 15, 2004 10:38 pm 
Offline
Senior Newbie

Joined: Mon May 31, 2004 7:44 pm
Posts: 15
I suppose though I should at least have an MX record. I also added a $TTL line because bind was noting its absence in syslog (falling back on min ttl).

Code:
$TTL 1d
@ IN  SOA  ns1.brlewis.com. brlewis.alum.mit.edu (
                2004061501 ; Serial (yyyymmddxx)
                86400      ; Refresh (1 day)
                7200       ; Retry (2 hours)
                604800     ; Expire (7 days)
                86400 )    ; Minimum (1 day)

                IN      NS      ns1.brlewis.com.

@                       IN      A       65.19.178.131
@                       IN      MX 50   65.19.178.131
www                     IN      CNAME   brlewis.com.
ns1                     IN      A       65.19.178.131
ns2                     IN      A       65.19.178.131


Top
   
 Post subject:
PostPosted: Wed Jun 16, 2004 7:03 am 
Offline
Senior Member
User avatar

Joined: Tue Apr 13, 2004 6:54 pm
Posts: 833
A quick glance and there's a few things. FIrstly, MX records should point to A records, not to IP addresses...

Code:
% nslookup -silent -type=mx brlewis.com 65.19.178.131
Server:         65.19.178.131
Address:        65.19.178.131#53

brlewis.com     mail exchanger = 50 65.19.178.131.brlewis.com.


There are a couple of minor points you may not be aware of. The first is that since you have multiple entries for "@" they can all be collapsed into one.

The second is the CNAME for www. Because it's a CNAME you now also have MX records, NS records and SOA records for the "www" name etc etc

Code:
% nslookup -silent -type=mx www.brlewis.com 65.19.178.131
Server:         65.19.178.131
Address:        65.19.178.131#53

www.brlewis.com canonical name = brlewis.com.
brlewis.com     mail exchanger = 50 65.19.178.131.brlewis.com.


It's just a minor point :-)

What I would do is:
Code:
$TTL 1d
@ IN  SOA  ns1.brlewis.com. brlewis.alum.mit.edu (
                2004061601 ; Serial (yyyymmddxx)
                86400      ; Refresh (1 day)
                7200       ; Retry (2 hours)
                604800     ; Expire (7 days)
                86400 )    ; Minimum (1 day)

                IN      NS      ns1.brlewis.com.
                IN      A       65.19.178.131
                IN      MX 50   mail.brlewis.com.

; We use the same IP address a lot, because we use different
; names for the same service.  We could just have
; "linode.brlewis.com" as the one name, but...
www                     IN      A       65.19.178.131
ns1                     IN      A       65.19.178.131
ns2                     IN      A       65.19.178.131
mail                    IN      A       65.19.178.131

Note that the same IP address is used in lots of places now. As the comment says, we _could_ reduce it and just have it twice (an A record for the @ line, and an A record for a general line (eg "linode") and have everything (NS, MX,WWW) all point to that. That's just a matter of taste :-)

_________________
Rgds

Stephen

(Linux user since kernel version 0.11)


Top
   
 Post subject:
PostPosted: Wed Jun 16, 2004 11:51 am 
Offline
Junior Member

Joined: Thu Jun 03, 2004 2:57 pm
Posts: 23
And don't forget to do everybody a favor and create an SPF record. ;)


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic


Who is online

Users browsing this forum: No registered users and 0 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
RSS

Powered by phpBB® Forum Software © phpBB Group