LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian
User Name
Password
Debian This forum is for the discussion of Debian Linux.

Notices


Reply
  Search this Thread
Old 03-31-2009, 03:21 AM   #1
linx win
Member
 
Registered: Jan 2004
Posts: 390

Rep: Reputation: 31
DNS server (bind9) working but not pinging


I have installed a DNS server using bind9. I created an internal zone linux.bogus per insrtuctions shown in:
http://www.tldp.org/HOWTO/DNS-HOWTO-5.html
My linux.bogus zone file is as follows:
Code:
;
; Zone file for linux.bogus
;
; The full zone file
;
$TTL 3D
@       IN      SOA     ns.linux.bogus. hostmaster.linux.bogus. (
                        199802151       ; serial, todays date + todays serial #
                        8H              ; refresh, seconds
                        2H              ; retry, seconds
                        4W              ; expire, seconds
                        1D )            ; minimum, seconds
;
                TXT     "Linux.Bogus, your DNS consultants"
                NS      ns              ; Inet Address of name server
                NS      ns.friend.bogus.
                MX      10 mail         ; Primary Mail Exchanger
                MX      20 mail.friend.bogus. ; Secondary Mail Exchanger

localhost       A       127.0.0.1

gw              A       192.168.196.1
                TXT     "The router"

ns              A       192.168.196.2
                MX      10 mail
                MX      20 mail.friend.bogus.
www             CNAME   ns

donald          A       192.168.196.3
                MX      10 mail
                MX      20 mail.friend.bogus.
                TXT     "DEK"

mail            A       192.168.196.4
                MX      10 mail
                MX      20 mail.friend.bogus.

ftp             A       192.168.196.5
                MX      10 mail
                MX      20 mail.friend.bogus.
The 127.0.0 zone is as follows:

Code:
$TTL 3D
@               IN      SOA     ns.linux.bogus. hostmaster.linux.bogus. (
                                1       ; Serial
                                8H      ; Refresh
                                2H      ; Retry
                                4W      ; Expire
                                1D)     ; Minimum TTL
                        NS      ns.linux.bogus.
1                       PTR     localhost.
DNS server started successfully, but when I do dig any linux.bogus, I get the following:
Code:
root@ns:/etc# dig any linux.bogus

; <<>> DiG 9.5.1-P2 <<>> any linux.bogus
;; global options:  printcmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NXDOMAIN, id: 18622
;; flags: qr rd ra; QUERY: 1, ANSWER: 0, AUTHORITY: 1, ADDITIONAL: 0

;; QUESTION SECTION:
;linux.bogus.			IN	ANY

;; AUTHORITY SECTION:
.			9613	IN	SOA	A.ROOT-SERVERS.NET. NSTLD.VERISIGN-GRS.COM. 2009033101 1800 900 604800 86400

;; Query time: 1 msec
;; SERVER: 127.0.0.1#53(127.0.0.1)
;; WHEN: Tue Mar 31 22:20:56 2009
;; MSG SIZE  rcvd: 104
As you can see, I get ANSWER: 0. Also when I do dig linux.bogus axfr, I get the following:

Code:
root@ns:/etc# dig linux.bogus axfr
; <<>> DiG 9.5.1-P2 <<>> linux.bogus axfr
;; global options:  printcmd
; Transfer failed.
Does any body know how to correct these issues?

My named.conf is as follows:
Code:
// Config file for caching only name server
//
// The version of the HOWTO you read may contain leading spaces
// (spaces in front of the characters on these lines ) in this and
// other files.  You must remove them for things to work.
//
// Note that the filenames and directory names may differ, the
// ultimate contents of should be quite similar though.

options {
	directory "/etc/bind";
	pid-file "/var/run/bind/run/named.pid";
	};

zone "." {
	type hint;
	file "/etc/bind/db.cache";
	};

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

key rndc-key {
	algorithm hmac-md5;
	secret "XXXXXXXXX";
	};
controls {
	inet 127.0.0.1 port 953 allow { 127.0.0.1; } keys { rndc-key; };
	};

           forward first;
           forwarders {
                10.0.0.1;
                10.0.0.2;
            };

zone "linux.bogus" {
        type master;
        notify no;
        file "pz/linux.bogus";
};
My PC hostname is:
Code:
root@ns:/etc# hostname
ns.linux.bogus

Last edited by linx win; 03-31-2009 at 05:00 PM.
 
Old 03-31-2009, 05:01 PM   #2
linx win
Member
 
Registered: Jan 2004
Posts: 390

Original Poster
Rep: Reputation: 31
Update:

I deleted the following from named.conf:

forward first;
forwarders {
10.0.0.1;
10.0.0.2;

It is working fine now.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
DNS Server (bind9) works on the private network but not in the public one! wjleon Linux - Networking 26 01-24-2009 09:14 PM
DNS Server (BIND9) mpgram Linux - Server 1 02-22-2008 11:36 AM
DNS (bind9) on Ubuntu not working right Avatar Linux - Networking 9 01-07-2008 05:01 PM
DNS Server for 2 domains - Bind9 bence8810 Linux - Server 17 12-19-2006 02:58 AM
Suse Linux 9.1 Pro BIND9/DNS server vbat Linux - Newbie 0 10-01-2004 08:20 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian

All times are GMT -5. The time now is 02:24 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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration