LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 12-18-2011, 02:44 PM   #1
Earlydayrambler
Member
 
Registered: Dec 2011
Posts: 39

Rep: Reputation: Disabled
Unhappy Help with zone files.


Greetings,

I have been in need of desperate help lately, and had nobody to go to. Hopefully this is the place.

I'm trying to get a DNS server up and running using BIND9 in Debian(squeeze).

I'm at the part where I modify to files called 1.168.192.rev and another called mydomain.com.db

Here is what the mydomain.com.db file looks like..

;
; BIND data file for mydomain.com.
;
$TTL 604800 IN SOA ns1.mydomain.com. info.mydomain.com. (

@ 1 ; Serial
7200 ; Refresh
120 ; Retry
2419200 ; Expire
604800) ; Default TTL
;
@ IN A NS ns1.mydomain.com.
@ IN A NS ns2.mydomain.com.


Here is what my 192.168.1.rev file looks like.

$TTL 1d ;
$ORIGIN 1.168.192.IN-ADDR.ARPA.

@ IN SOA ns1.mydomain.com. info.mydomain.com. (
1
7200
120
2419200
604800
)
IN NS ns1.mydomain.com.
IN NS ns2.mydomain.com.
1 IN PTR ns1.mydomain.com.
2 IN PTR ns2.mydomain.com.



Now, everytime I run the command

named-checkzone 192.168.1.rev mydomain.com.db

I then get the following error

dns_master_load: mydomain.com.db:4: extra input text
dns_rdata_fromtext: mydomain.com.db:12: near 'NS': bad dotted quad
dns_rdata_fromtext: mydomain.com.db:13: near 'NS': bad
dotted quad
zone 192.168.1.rev/IN: loading from master file mydomain.com.db failed: extra input text
zone 192.168.1.rev/IN: not loaded due to errors.


I keep getting that whole error. I tried looking for solutions but none helped.

Is there something missing in the files? Or should I change something around?

Take it easy on me, I'm new to this stuff.
 
Old 12-18-2011, 03:26 PM   #2
kbp
Senior Member
 
Registered: Aug 2009
Posts: 3,790

Rep: Reputation: 653Reputation: 653Reputation: 653Reputation: 653Reputation: 653Reputation: 653
You have no address (A) records for your name servers in mydomain.com.db, this is not valid:
Quote:
@ IN A NS ns1.mydomain.com.
@ IN A NS ns2.mydomain.com.
try..
Code:
@ IN NS ns1.mydomain.com.
@ IN NS ns2.mydomain.com.

192.168.1.x IN A ns1.mydomain.com.
192.168.1.x IN A ns2.mydomain.com.

Last edited by kbp; 12-18-2011 at 03:28 PM.
 
Old 12-18-2011, 03:38 PM   #3
Earlydayrambler
Member
 
Registered: Dec 2011
Posts: 39

Original Poster
Rep: Reputation: Disabled
Thanks!

Now it gives me this error..


dns_master_load: mydomain.com.db:4: extra input text
dns_rdata_fromtext: mydomain.com.db:15: near 'ns1.mydomain.com.': bad dotted quad
dns_rdata_fromtext: mydomain.com.db:16: near 'ns2.mydomain.com.': bad dotted quad
zone 192.168.1.rev/IN: loading from master file mydomain.com.db failed: extra input text
zone 192.168.1.rev/IN: not loaded due to errors.


Anything else I could try?
 
Old 12-18-2011, 04:30 PM   #4
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 13,163
Blog Entries: 1

Rep: Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032
Quote:
Now, everytime I run the command

named-checkzone 192.168.1.rev mydomain.com.db

I then get the following error
The correct is
Code:
named-checkzone mydomain.com mydomain.com.db
named-checkzone 1.168.192.in-addr.arpa 192.168.1.rev
But you have many errors in both your zone files. Try the following:
Code:
$TTL 604800 
@ IN SOA ns1.mydomain.com. info.mydomain.com. (
2 ; Serial 
7200 ; Refresh
120 ; Retry
2419200 ; Expire
604800) ;  Minimum
;
@ IN NS ns1.mydomain.com.
@ IN NS ns2.mydomain.com.
ns1.mydomain.com. IN A x.x.x.x
ns2.mydomain.com. IN A y.y.y.y
Code:
$TTL 1d ;
$ORIGIN 1.168.192.IN-ADDR.ARPA.

@ IN SOA ns1.mydomain.com. info.mydomain.com. (
2
7200
120
2419200
604800
)
 IN NS ns1.mydomain.com.
 IN NS ns2.mydomain.com.
1 IN PTR ns1.mydomain.com.
2 IN PTR ns2.mydomain.com.
Regards
 
1 members found this post helpful.
Old 12-18-2011, 04:41 PM   #5
kbp
Senior Member
 
Registered: Aug 2009
Posts: 3,790

Rep: Reputation: 653Reputation: 653Reputation: 653Reputation: 653Reputation: 653Reputation: 653
Theres a good reference here
 
1 members found this post helpful.
Old 12-18-2011, 04:51 PM   #6
Earlydayrambler
Member
 
Registered: Dec 2011
Posts: 39

Original Poster
Rep: Reputation: Disabled
YES!!!!!!!

YOU DID IT!!!!!

THANK YOU SOO MUCH bathory!!!!!! w000t!!!!

Man..I owe you a drink!!!
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Problem creating second zone: "Copying <0> files to the zone." AlucardZero Solaris / OpenSolaris 0 07-20-2010 03:12 PM
How can I share files from a zone? AlucardZero Solaris / OpenSolaris 2 06-03-2010 10:37 AM
Bash zone files cracksternation Programming 1 08-09-2007 10:05 PM
Zone files madunix Linux - Networking 3 06-22-2006 04:31 AM
Bind and DNS information conf files and zone files aaronluke Linux - General 1 10-13-2002 09:41 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 11:47 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration