LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 10-10-2005, 09:18 AM   #1
DanielTan
Member
 
Registered: Sep 2004
Location: Malaysia
Distribution: FC6, Solaris
Posts: 340

Rep: Reputation: 30
Configure named server


I am configuring caching named server and file "db.127.0.0" . I follow advise from a website that i need to create this db.127.0.0 and add below lines to it
but i get error message "Zone file initialization error. ....zone 0.0.127.in-addr-arpa/IN: has no NS records". Pls advise. Thanks

$TTL 345600
@ IN SOA localhost. root.localhost. (
00 ; Serial
86400 ; Refresh
7200 ; Retry
2592000 ; Expire
345600 ) ; Minimum
IN NS localhost.
1 IN PTR localhost.

Rgds
Daniel
 
Old 10-10-2005, 11:08 AM   #2
sshoemaker
LQ Newbie
 
Registered: Aug 2005
Location: Pennsylvania
Distribution: FC4
Posts: 14

Rep: Reputation: 0
named server configuration

something like this for named.conf file

options {
directory "/var/named";
pid-file "/var/named/named.pid";
allow-query { 127.0.0.1; };
allow-transfer { none; };
listen-on { 127.0.0.1; };
};

zone "localhost" IN {
type master;
file "localhost.zone";
};

zone "." in {
type hint;
file "named.ca";
};

zone "0.0.127.in-addr.arpa" in {
type master;
file "named.local";
};

something like this for the localhost.zone file
$TTL 86400
$ORIGIN localhost.
@ 1D IN SOA @ root (
2005101000; serial YYYYMMDDnn
3H ; refresh
15M ; retry
1W ; expiry
1D ) ; minimum

1D IN NS @
1D IN A 127.0.0.1

something like this for the named.local file
$TTL 86400
@ IN SOA localhost. root.localhost. (
2005101000 ; Serial
28800 ; Refresh
14400 ; Retry
3600000 ; Expire
86400 ) ; Minimum
IN NS localhost.
1 IN PTR localhost.


This should work for you....
 
Old 10-10-2005, 11:09 AM   #3
sshoemaker
LQ Newbie
 
Registered: Aug 2005
Location: Pennsylvania
Distribution: FC4
Posts: 14

Rep: Reputation: 0
named server configuration

One more thing... make sure if you change anything in the zone files that you increment the serial #.. otherwise changes will not show up.
 
Old 10-10-2005, 07:25 PM   #4
DanielTan
Member
 
Registered: Sep 2004
Location: Malaysia
Distribution: FC6, Solaris
Posts: 340

Original Poster
Rep: Reputation: 30
Re: named server configuration

Hi, does localhost.zone same as db.127.0.0 ? db.cache same as named.local ?

Rgds
Daniel


Quote:
Originally posted by sshoemaker
something like this for named.conf file

options {
directory "/var/named";
pid-file "/var/named/named.pid";
allow-query { 127.0.0.1; };
allow-transfer { none; };
listen-on { 127.0.0.1; };
};

zone "localhost" IN {
type master;
file "localhost.zone";
};

zone "." in {
type hint;
file "named.ca";
};

zone "0.0.127.in-addr.arpa" in {
type master;
file "named.local";
};

something like this for the localhost.zone file
$TTL 86400
$ORIGIN localhost.
@ 1D IN SOA @ root (
2005101000; serial YYYYMMDDnn
3H ; refresh
15M ; retry
1W ; expiry
1D ) ; minimum

1D IN NS @
1D IN A 127.0.0.1

something like this for the named.local file
$TTL 86400
@ IN SOA localhost. root.localhost. (
2005101000 ; Serial
28800 ; Refresh
14400 ; Retry
3600000 ; Expire
86400 ) ; Minimum
IN NS localhost.
1 IN PTR localhost.


This should work for you....
 
Old 10-11-2005, 08:15 AM   #5
sshoemaker
LQ Newbie
 
Registered: Aug 2005
Location: Pennsylvania
Distribution: FC4
Posts: 14

Rep: Reputation: 0
named sdrver...

I think the db.cache is the same as "named.ca" -- it's the cache of the root servers.

the localhost.zone is the forward of the localhost zone and the named.local is the reverse of the localhost zone.
 
Old 10-11-2005, 11:08 AM   #6
DanielTan
Member
 
Registered: Sep 2004
Location: Malaysia
Distribution: FC6, Solaris
Posts: 340

Original Poster
Rep: Reputation: 30
Re: named sdrver...

Hi, what abt db.127.0.0 ? similar as db.cache ?

Rgds
Daniel


Quote:
Originally posted by sshoemaker
I think the db.cache is the same as "named.ca" -- it's the cache of the root servers.

the localhost.zone is the forward of the localhost zone and the named.local is the reverse of the localhost zone.
 
Old 10-11-2005, 11:10 AM   #7
sshoemaker
LQ Newbie
 
Registered: Aug 2005
Location: Pennsylvania
Distribution: FC4
Posts: 14

Rep: Reputation: 0
named server...

your db.127.0.0 is the reverse file. so it's the samed as the named.local
 
Old 10-11-2005, 11:24 AM   #8
DanielTan
Member
 
Registered: Sep 2004
Location: Malaysia
Distribution: FC6, Solaris
Posts: 340

Original Poster
Rep: Reputation: 30
Re: named server...

So if i already have named.local then i do not have to have db.127.0.0 , right ? also where are the cached dns entries records in dns console ? i want to check all those site IP and etc i have browsed. Thanks

Rgds
Daniel



Quote:
Originally posted by sshoemaker
your db.127.0.0 is the reverse file. so it's the samed as the named.local
 
Old 10-11-2005, 11:27 AM   #9
sshoemaker
LQ Newbie
 
Registered: Aug 2005
Location: Pennsylvania
Distribution: FC4
Posts: 14

Rep: Reputation: 0
named server...

right.. if you have the named.local you don't need the db.127.0.0 file.

I'm not sure where the cache is stored... I would suppose in memory, but I wouldn't suppose it can be browsed. If it was in plain text it would take a long time to parse.
 
Old 10-11-2005, 07:14 PM   #10
DanielTan
Member
 
Registered: Sep 2004
Location: Malaysia
Distribution: FC6, Solaris
Posts: 340

Original Poster
Rep: Reputation: 30
Re: named server...

Hi, doesn't it have cached entries like in Windows cache DNS ? then how do we know it is cached ?

Rgds
Daniel


Quote:
Originally posted by sshoemaker
right.. if you have the named.local you don't need the db.127.0.0 file.

I'm not sure where the cache is stored... I would suppose in memory, but I wouldn't suppose it can be browsed. If it was in plain text it would take a long time to parse.
 
Old 10-12-2005, 09:32 AM   #11
sshoemaker
LQ Newbie
 
Registered: Aug 2005
Location: Pennsylvania
Distribution: FC4
Posts: 14

Rep: Reputation: 0
named server

add the following line to your /etc/resolv.conf file

nameserver 127.0.0.1

Also make sure that your /etc/nsswitch.conf file has the following like or something similar including dns

hosts: files dns

When you start named you should see the following (or something like it in your messages file)
Dec 23 02:21:12 lookfar named[11031]: starting BIND 9.1.3
Dec 23 02:21:12 lookfar named[11031]: using 1 CPU
Dec 23 02:21:12 lookfar named[11034]: loading configuration from \
'/etc/named.conf'
Dec 23 02:21:12 lookfar named[11034]: the default for the \
'auth-nxdomain' option is now 'no'
Dec 23 02:21:12 lookfar named[11034]: no IPv6 interfaces found
Dec 23 02:21:12 lookfar named[11034]: listening on IPv4 interface lo, \
127.0.0.1#53
Dec 23 02:21:12 lookfar named[11034]: listening on IPv4 interface eth0, \
10.0.0.129#53
Dec 23 02:21:12 lookfar named[11034]: command channel listening on \
127.0.0.1#953
Dec 23 02:21:13 lookfar named[11034]: running

Then to test it
$ dig google.com

; <<>> DiG 9.2.1 <<>> google.com
;; global options: printcmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 54001
;; flags: qr rd ra; QUERY: 1, ANSWER: 2, AUTHORITY: 0, ADDITIONAL: 0

;; QUESTION SECTION:
;google.com. IN A

;; ANSWER SECTION:
google.com. 300 IN A 216.239.37.99
google.com. 300 IN A 216.239.57.99

;; Query time: 8 msec
;; SERVER: 127.0.0.1#53(127.0.0.1)
;; WHEN: Wed Oct 12 10:29:56 2005
;; MSG SIZE rcvd: 60
 
  


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
setting my own named server slack66 *BSD 6 11-15-2004 08:52 PM
named works only on the server psc Linux - Networking 1 10-18-2004 05:41 AM
can we configure a Linux server with mail server,file server and web server kumarx Linux - Newbie 5 09-09-2004 06:21 AM
Mandrake 9.2 Computer named after Samba Server bopo119 Linux - Networking 1 04-06-2004 12:38 AM
Virtual Host type, named or IP via SSL? Named VH is not possible? piratebiter Linux - Security 3 08-20-2003 05:27 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 05:46 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