LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 08-09-2006, 04:04 AM   #1
BlackRabbit
Member
 
Registered: Oct 2003
Distribution: Debian
Posts: 83

Rep: Reputation: 15
[Slack] Problems with named


Hi,
yesterday I installed Slackware 10.1 on my homeserver. Before that, it was running Slack 9.0. I made a backup of all my config files (apache, samba, php, named, proftpd, ...) and copied them onto the new install. Everything works fine (after some minor adjustments in de config files), except for named.
It's weird actually: named does start without errors (and keeps running), but any local zone I cannot find.
Here are my config files:


/etc/named.conf:
Code:
options {
        directory "/var/named";
        pid-file "/var/run/named/named.pid";
        // Uncommenting this might help if you have to go through a
        // firewall and things are not working out.  But you probably
        // need to talk to your firewall admin.

        // query-source port 53;
};

controls {
        inet 127.0.0.1 allow { localhost; } keys { rndc_key; };
};

key "rndc_key" {
        algorithm hmac-md5;
        secret "KJLZX+44uYN7dTz5QuyKQw==";
};

zone "." IN {
        type hint;
        file "root.hints";
};

zone "0.0.127.in-addr.arpa" IN {
        type master;
        file "pz/127.0.0";
};

zone "maes.local" IN {
        type master;
        notify no;
        file "pz/maes.local";
};
/var/named/pz/maes.local:
Code:
;
; Zone file formaes.local
;
; The full zone file
;
$TTL 3D
@       IN      SOA     sun.maes.local. BlackRabbit.actua-forums.be. (
                        199802151       ; serial, todays date + todays serial #
                        8H              ; refresh, seconds
                        2H              ; retry, seconds
                        4W              ; expire, seconds
                        1D )            ; minimum, seconds
;
                NS      ns              ; Inet Address of name server
maes.local.            IN    MX      10 mail.scarlet.be     ; Primary Mail Exchanger
//                MX      20 mail.friend.bogus.   ; Secondary Mail Exchanger
;
localhost       A       127.0.0.1
www             A       192.168.0.2
photos          A       192.168.0.2
cbase           A       192.168.0.2
dvd             A       192.168.0.2
camera1         A       192.168.0.100
/var/named/root.hints:
Code:
; <<>> DiG 9.3.0 <<>> @e.root-servers.net . ns
;; global options:  printcmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 37134
;; flags: qr aa rd; QUERY: 1, ANSWER: 13, AUTHORITY: 0, ADDITIONAL: 13

;; QUESTION SECTION:
;.                              IN      NS

;; ANSWER SECTION:
.                       518400  IN      NS      J.ROOT-SERVERS.NET.
.                       518400  IN      NS      K.ROOT-SERVERS.NET.
.                       518400  IN      NS      L.ROOT-SERVERS.NET.
.                       518400  IN      NS      M.ROOT-SERVERS.NET.
.                       518400  IN      NS      A.ROOT-SERVERS.NET.
.                       518400  IN      NS      B.ROOT-SERVERS.NET.
.                       518400  IN      NS      C.ROOT-SERVERS.NET.
.                       518400  IN      NS      D.ROOT-SERVERS.NET.
.                       518400  IN      NS      E.ROOT-SERVERS.NET.
.                       518400  IN      NS      F.ROOT-SERVERS.NET.
.                       518400  IN      NS      G.ROOT-SERVERS.NET.
.                       518400  IN      NS      H.ROOT-SERVERS.NET.
.                       518400  IN      NS      I.ROOT-SERVERS.NET.

;; ADDITIONAL SECTION:
A.ROOT-SERVERS.NET.     3600000 IN      A       198.41.0.4
B.ROOT-SERVERS.NET.     3600000 IN      A       192.228.79.201
C.ROOT-SERVERS.NET.     3600000 IN      A       192.33.4.12
D.ROOT-SERVERS.NET.     3600000 IN      A       128.8.10.90
E.ROOT-SERVERS.NET.     3600000 IN      A       192.203.230.10
F.ROOT-SERVERS.NET.     3600000 IN      A       192.5.5.241
G.ROOT-SERVERS.NET.     3600000 IN      A       192.112.36.4
H.ROOT-SERVERS.NET.     3600000 IN      A       128.63.2.53
I.ROOT-SERVERS.NET.     3600000 IN      A       192.36.148.17
J.ROOT-SERVERS.NET.     3600000 IN      A       192.58.128.30
K.ROOT-SERVERS.NET.     3600000 IN      A       193.0.14.129
L.ROOT-SERVERS.NET.     3600000 IN      A       198.32.64.12
M.ROOT-SERVERS.NET.     3600000 IN      A       202.12.27.33

;; Query time: 161 msec
;; SERVER: 192.203.230.10#53(e.root-servers.net)
;; WHEN: Tue Aug  8 11:59:32 2006
;; MSG SIZE  rcvd: 436

I also ran "named-checkconf /etc/named.conf", which doesn't return any errors or notices.
Pinging to "www.maes.local" from any machine (client or the server itself) does not work. Pinging to "www.google.com" works from all machines.

More:
named-checkzone -t /var/named/pz/ maes.local maes.local:
Code:
zone maes.local/IN: loaded serial 199802151
OK

dig @localhost www.maes.local:
Code:
; <<>> DiG 9.3.0 <<>> @localhost www.maes.local
;; global options:  printcmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: SERVFAIL, id: 53728
;; flags: qr rd ra; QUERY: 1, ANSWER: 0, AUTHORITY: 0, ADDITIONAL: 0

;; QUESTION SECTION:
;www.maes.local.                        IN      A

;; Query time: 1 msec
;; SERVER: 127.0.0.1#53(localhost)
;; WHEN: Wed Aug  9 11:18:12 2006
;; MSG SIZE  rcvd: 32
Anybody with an idea?

Last edited by BlackRabbit; 08-09-2006 at 04:59 AM.
 
Old 08-09-2006, 04:40 AM   #2
prozac
Member
 
Registered: Oct 2005
Location: Australia
Distribution: slackware 12.1
Posts: 753

Rep: Reputation: 32
i would check /var/log/messages for any errors just after starting named.
 
Old 08-09-2006, 04:45 AM   #3
BlackRabbit
Member
 
Registered: Oct 2003
Distribution: Debian
Posts: 83

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by prozac
i would check /var/log/messages for any errors just after starting named.
Did that as well, but can't see anything wrong:
Code:
Aug  9 11:43:21 SUN named[1209]: starting BIND 9.3.0
Aug  9 11:43:21 SUN named[1209]: loading configuration from '/etc/named.conf'
Aug  9 11:43:21 SUN named[1209]: no IPv6 interfaces found
Aug  9 11:43:21 SUN named[1209]: listening on IPv4 interface lo, 127.0.0.1#53
Aug  9 11:43:21 SUN named[1209]: listening on IPv4 interface eth0, 192.168.0.2#53
Aug  9 11:43:21 SUN named[1209]: command channel listening on 127.0.0.1#953
Aug  9 11:43:21 SUN named[1209]: zone 0.0.127.in-addr.arpa/IN: loaded serial 1
Aug  9 11:43:21 SUN named[1209]: running
Aug  9 11:43:21 SUN named[1209]: zone 0.0.127.in-addr.arpa/IN: sending notifies (serial 1)

Last edited by BlackRabbit; 08-09-2006 at 04:47 AM.
 
Old 08-09-2006, 04:50 AM   #4
prozac
Member
 
Registered: Oct 2005
Location: Australia
Distribution: slackware 12.1
Posts: 753

Rep: Reputation: 32
where did it load 'maes.local'?
 
Old 08-09-2006, 04:52 AM   #5
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:
zone 0.0.127.in-addr.arpa/IN: loaded serial 1
Are you sure you're using the correct named.conf? Cause from the logs zone 0.0.127.in-addr.arpa is loaded (which does not exist in the named.conf you posted) and the zone maes.local is not loaded.
 
Old 08-09-2006, 05:00 AM   #6
BlackRabbit
Member
 
Registered: Oct 2003
Distribution: Debian
Posts: 83

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by bathory
Are you sure you're using the correct named.conf? Cause from the logs zone 0.0.127.in-addr.arpa is loaded (which does not exist in the named.conf you posted) and the zone maes.local is not loaded.
My bad: didn't copy-paste the whole file.
It does load the correct named.conf (did a search, is the only file on the whole system)
Edited first post.

Quote:
Originally Posted by prozac
where did it load 'maes.local'?
Good question

But euhm.. What's wrong then?
 
Old 08-09-2006, 05:03 AM   #7
prozac
Member
 
Registered: Oct 2005
Location: Australia
Distribution: slackware 12.1
Posts: 753

Rep: Reputation: 32
your local zone file, maes.local, well i don't see it loading in /var/log/messages. why is it not loading? it you don't load it how would your query fetch data based on the records of that zone.
 
Old 08-09-2006, 05:10 AM   #8
BlackRabbit
Member
 
Registered: Oct 2003
Distribution: Debian
Posts: 83

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by prozac
your local zone file, maes.local, well i don't see it loading in /var/log/messages. why is it not loading? it you don't load it how would your query fetch data based on the records of that zone.
Yes ofcourse, I understand that.
What I meant was: what is wrong with my config that it doesn't load the zonefile?
 
Old 08-09-2006, 05:12 AM   #9
prozac
Member
 
Registered: Oct 2005
Location: Australia
Distribution: slackware 12.1
Posts: 753

Rep: Reputation: 32
Code:
zone "maes.local" IN {
        type master;
        notify no;
        file "pz/maes.local";
};
well i am not that expert. what does the line in bold does?
 
Old 08-09-2006, 05:14 AM   #10
prozac
Member
 
Registered: Oct 2005
Location: Australia
Distribution: slackware 12.1
Posts: 753

Rep: Reputation: 32
also;
Code:
localhost       A       127.0.0.1
www             A       192.168.0.2
photos          A       192.168.0.2
cbase           A       192.168.0.2
dvd             A       192.168.0.2
camera1         A       192.168.0.100
like already said, i am not an expert. shouldn't there be a IN between those www|photos and 192.168.0.2? i don't know actually, maybe someone else knows.
 
Old 08-09-2006, 05:15 AM   #11
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
You should add:
Code:
ns             A       192.168.0.2
in your zone file (/var/named/pz/maes.local) cause there is no entry for the host ns, so you cannot find your own dns.
 
Old 08-09-2006, 05:18 AM   #12
BlackRabbit
Member
 
Registered: Oct 2003
Distribution: Debian
Posts: 83

Original Poster
Rep: Reputation: 15
It notifies other DNS servers of changes (I believe).

Anyway, just to be sure I removed the line and restarted named:
Code:
Aug  9 12:11:01 SUN named[1272]: starting BIND 9.3.0
Aug  9 12:11:01 SUN named[1272]: loading configuration from '/etc/named.conf'
Aug  9 12:11:01 SUN named[1272]: no IPv6 interfaces found
Aug  9 12:11:01 SUN named[1272]: listening on IPv4 interface lo, 127.0.0.1#53
Aug  9 12:11:01 SUN named[1272]: listening on IPv4 interface eth0, 192.168.0.2#53
Aug  9 12:11:01 SUN named[1272]: command channel listening on 127.0.0.1#953
Aug  9 12:11:01 SUN named[1272]: zone 0.0.127.in-addr.arpa/IN: loaded serial 1
Aug  9 12:11:01 SUN named[1272]: running
Aug  9 12:11:01 SUN named[1272]: zone 0.0.127.in-addr.arpa/IN: sending notifies (serial 1)
It doesn't load nor notify maes.local



Quote:
Originally Posted by bathory
You should add:
Code:
ns             A       192.168.0.2
in your zone file (/var/named/pz/maes.local) cause there is no entry for the host ns, so you cannot find your own dns.
You mean like this:
Code:
;
; Zone file formaes.local
;
; The full zone file
;
$TTL 3D
@       IN      SOA     sun.maes.local. BlackRabbit.actua-forums.be. (
                        199802151       ; serial, todays date + todays serial #
                        8H              ; refresh, seconds
                        2H              ; retry, seconds
                        4W              ; expire, seconds
                        1D )            ; minimum, seconds
;
        IN        NS    ns              ; Inet Address of name server
maes.local.            IN    MX      10 mail.scarlet.be     ; Primary Mail Exchanger
//                MX      20 mail.friend.bogus.   ; Secondary Mail Exchanger
;
ns             A       192.168.0.2
localhost       A       127.0.0.1
www             A       192.168.0.2
photos          A       192.168.0.2
cbase           A       192.168.0.2
dvd             A       192.168.0.2
camera1         A       192.168.0.100
Doesn't work either

Last edited by BlackRabbit; 08-09-2006 at 05:25 AM.
 
Old 08-09-2006, 05:29 AM   #13
BlackRabbit
Member
 
Registered: Oct 2003
Distribution: Debian
Posts: 83

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by prozac
also;
Code:
localhost       A       127.0.0.1
www             A       192.168.0.2
photos          A       192.168.0.2
cbase           A       192.168.0.2
dvd             A       192.168.0.2
camera1         A       192.168.0.100
like already said, i am not an expert. shouldn't there be a IN between those www|photos and 192.168.0.2? i don't know actually, maybe someone else knows.
Wasn't on previous install (as that worked).
Anyway, checked google, seems others add "IN" as well, so did it as well now.
Unfortunately it didn't make a difference
 
Old 08-09-2006, 05:36 AM   #14
BlackRabbit
Member
 
Registered: Oct 2003
Distribution: Debian
Posts: 83

Original Poster
Rep: Reputation: 15
More information:
maes.local isn't the only domain I'm running on this server. Another domain on it is datanuke.be:
/var/named/datanuke.be
Code:
;
; Zone file for datanuke.be
;
; The full zone file
;
$TTL 3D
@       IN      SOA     sun.datanuke.be. BlackRabbit.actua-forums.be. (
                        199802151       ; serial, todays date + todays serial #
                        8H              ; refresh, seconds
                        2H              ; retry, seconds
                        4W              ; expire, seconds
                        1D )            ; minimum, seconds
;
                NS      ns              ; Inet Address of name server
//                MX      10 mail.linux.bogus     ; Primary Mail Exchanger
//                MX      20 mail.friend.bogus.   ; Secondary Mail Exchanger
;
localhost       A       127.0.0.1
www             A      213.193.229.20
2x              A       192.168.0.2
ftp             A       192.168.0.3
www.datanuke.be is a public website. All the others are sites on my local servers (for developement etc).

Although I can ping www.google.com on the servermachine (public IP), I fail to reach www.datanuke.be. This is interesting, because it means that named does "pick up" the request, but is unable to handle it.

My guess is the problem lies in the zone-files..
 
Old 08-09-2006, 05:36 AM   #15
prozac
Member
 
Registered: Oct 2005
Location: Australia
Distribution: slackware 12.1
Posts: 753

Rep: Reputation: 32
Quote:
zone "maes.local" IN {
type master;
notify no;
file "pz/maes.local";
};
in my understanding, bind should look for maes.local and try to load it (even if it has errors), but since it isn't even trying, i feel it is not using the named.conf you have configured.
 
  


Reply

Tags
named, slackware



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
'named' problems on boot and shutdown ayn Linux - Networking 1 06-20-2004 09:12 AM
Named on Fedora problems johnrat Linux - Networking 3 05-14-2004 08:09 AM
Virtual Host type, named or IP via SSL? Named VH is not possible? piratebiter Linux - Security 3 08-20-2003 05:27 PM
named - dns - problems blaci Linux - General 2 07-22-2003 01:32 AM
named problems 9nine9 Linux - Networking 4 01-25-2003 10:38 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 02:22 PM.

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