Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Problem with BIND 9 under Red Hat 7.1 !!!???

Status
Not open for further replies.

HaoDr

IS-IT--Management
Sep 26, 2001
32
VN
Hi all,

I have just installed Red Hat 7.1 in my box, and I tried to setup DNS service to make my box operate as DNS server. Previously, I have ever used BIND 8, I had no problem, but with BIND 9 going along with Red Hat 7.1, although I have tried all ways but I have always met a problem. That is every time I enter command " rndc reload " to start up named service, and get error as follow:

# rndc reload
# connect: connection refused

I have read manual guide going along with BIND9 package, and I checked configuration files related to DNS service as rndc.conf, named.conf, named.ca, localhost.zone, named.local, resolv.conf, network ...I think they aren't problem, because in fact, I don't modify them at all, I haven't added any zone yet. ( After I start up named service sucessfully, I will add my zone in file named.conf, and create this file )

Besides, TCP/IP, xinetd run well in my system, I can ping my own IP address, or I can telnet / ftp / ssh ... to my own box .

The following are my configuration files:

file rndc.conf
-------------------------------------------------------
options {
default-server localhost;
default-key "key";
};

server localhost {
key "key";
};

key "key" {
algorithm hmac-md5; secret "zgM0gsZwOXOTXqfRjWIierzEbckiUdPGPXzjAVfsEQDHToQqjFNGtxpgPMTV";
};
----------------------------------------------------

File named.conf
----------------------------------------------------
options {
directory "/var/named";
zone "." IN {
type hint;
file "named.ca";
};

zone "localhost" IN {
type master;
file "localhost.zone";
allow-update { none; };
};

zone "0.0.127.in-addr.arpa" IN {
type master;
file "named.local";
allow-update { none; };
};
key "key" {
algorithm hmac-md5;
secret "zgM0gsZwOXOTXqfRjWIierzEbckiUdPGPXzjAVfsEQDHToQqjFNGtxpgPMTV";
};
--------------------------------------------------------

and other files as named.ca, localhost.zone, named.local, resolv.conf, network I think they aren't problem.

Please tell me the reason why I cannot start up named service, and how to fix this problem.

Thanks so much for your help.

Hao Dr
 
Hi,

You seem to be missing the 'controls' statement from named.conf - e.g. :

controls {
inet 127.0.0.1 allow { localhost; } keys { "key"; };
};

This controls from where the rndc command can be executed.

Regards
 
Thanks. And can I put the control statement in anywhere in my named.conf ?
 
Hi,

I believe so.. Mine is immediately below the 'key' block.

Regards
 
Hi Ifincham,

First off all, I am very thanks for your devoted answer, I have added controls statement into named.conf file just after "Key block" like your suggest, but it still doesn't work at all ( when enter command: /usr/sbin/rndc reload -> it replies : connect: connection refused ). Or there is something else wrong, for example, version BIND 9-1.0-10 has problem with rndc utility ? This version of rndc program hasn't supported debug option yet, so it's very hard to debug its faults. Or some file in my Linux box has problem ? , do I need to reinstall Red Hat Linux again ? Please suggest me some ways to solve this problem.

Thanks in advance for your help.

Hao Dr
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top