Operating System - Linux
1825764 Members
2141 Online
109687 Solutions
New Discussion

Re: Configuring DNS SERver on RH A.S

 
SOLVED
Go to solution
Edwin Ruiz_2
Super Advisor

Configuring DNS SERver on RH A.S

Hi!

Somebody knows how can i configure a DNS Server using Red Hat ?

Thnx for ur help!
9 REPLIES 9
Ivan Ferreira
Honored Contributor

Re: Configuring DNS SERver on RH A.S

Is no different from any other distribution. Anyway is not a simple task (the first time), follow the instructions located here:

http://www.brennan.id.au/08-Domain_Name_System_BIND.html
http://www.linuxhomenetworking.com/linux-hn/dns-static.htm

You must:

Install the package.
Configure your named.conf file
Configure and populate the zone files.
Por que hacerlo dificil si es posible hacerlo facil? - Why do it the hard way, when you can do it the easy way?
Vitaly Karasik_1
Honored Contributor

Re: Configuring DNS SERver on RH A.S

Edwin,

You can use RH doc http://www.redhat.com/docs/manuals/enterprise/RHEL-4-Manual/ref-guide/ (Chapter 12.1) as well.

If you can tell us more about your environment, we'll be able to suggest the optimal DNS design.
Vipulinux
Respected Contributor

Re: Configuring DNS SERver on RH A.S

Hi

Once you configure it using the above mentioned url's. also have a look at this:
http://www.redhat.com/docs/manuals/linux/RHL-9-Manual/ref-guide/s1-bind-mistakes.html

Cheers

Edwin Ruiz_2
Super Advisor

Re: Configuring DNS SERver on RH A.S

Hi!
thax for ur answers. I have installed Redhat AS Update5. This server is on a DMZ.
These are my configurations files:

/etc/named.conf


[root@salcto-apl09 etc]# more named.conf
//
// named.conf for Red Hat caching-nameserver
//

options {
directory "/var/named";
dump-file "/var/named/data/cache_dump.db";
statistics-file "/var/named/data/named_stats.txt";
/*
* If there is a firewall between you and nameservers you want
* to talk to, you might need to uncomment the query-source
* directive below. Previous versions of BIND always asked
* questions using port 53, but BIND 8.1 uses an unprivileged
* port by default.
*/
// query-source address * port 53;
};

//
// a caching only nameserver config
//
controls {
inet 127.0.0.1 allow { localhost; } keys { rndckey; };
};

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

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

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; };
};

zone "0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.ip6.arpa" IN
{
type master;
file "named.ip6.local";
allow-update { none; };
};

zone "255.in-addr.arpa" IN {
type master;
file "named.broadcast";
allow-update { none; };
};

zone "0.in-addr.arpa" IN {
type master;
file "named.zero";
allow-update { none; };
};

zone "taca.com" IN {
type master;
file "taca.com";
allow-update {
127.0.0.1;
172.17.10.5;
};
};
include "/etc/rndc.key";

+===========================================
/var/named/taca.com

$TTL 604800
(EN) IN SOA salcto-apl09.taca.com. root.salcto.taca.com. (
2002111502 ; serial
86400 ; refresh
7200 ; retry
2592000 ; expire
172800 ; default_ttl
)
(EN) IN NS salcto-apl09.taca.com.
salcto-apl09 IN A 172.17.10.5

========================================

/etc/resolv.conf


search taca.com
nameserver 127.0.0.1
nameserver 172.17.10.5


=========================================

/etc/hosts

# Do not remove the following line, or various programs
# that require network functionality will fail.
127.0.0.1 localhost.localdomain localhost
172.17.10.5 salcto-apl09 salcto-apl09.taca.com


I start the named service but in /var/log/messages i get this messages:

May 10 08:05:52 salcto-apl09 named[2225]: dns_master_load: taca.com:9: EN.taca.com: not at top of zone
May 10 08:05:52 salcto-apl09 named[2225]: zone taca.com/IN: loading master file taca.com: not at top of zone

========================================

Because this server is in DMZ, do i need to use the IP intenal or NAT IP?

Thx for ur help
Vitaly Karasik_1
Honored Contributor
Solution

Re: Configuring DNS SERver on RH A.S

I suggest you to change your zone file as following:

$ORIGIN taca.com.

$TTL 604800
@ IN SOA salcto-apl09.taca.com. root.salcto.taca.com. (
2002111502 ; serial
86400 ; refresh
7200 ; retry
2592000 ; expire
172800 ; default_ttl
)
@ IN NS salcto-apl09.taca.com.
salcto-apl09 IN A 172.17.10.5


And you should use external (legal) IP address.
Edwin Ruiz_2
Super Advisor

Re: Configuring DNS SERver on RH A.S

I change /var/named/taca.com adding

$ORIGIN taca.com

but ...

[root@salcto-apl09 ftp]# named-checkzone example.com /var/named/taca.com
dns_master_load: /var/named/taca.com:3: SOA record not at top of zone (EN.taca.com.example.com)
zone example.com/IN: loading master file /var/named/taca.com: not at top of zone

i get same errors
Vitaly Karasik_1
Honored Contributor

Re: Configuring DNS SERver on RH A.S

please note "@" in my previous post.
Asif Sharif
Honored Contributor

Re: Configuring DNS SERver on RH A.S

Hi Ruiz,

Step by step configuration of DNS server for Redhat 9 is available on the following link.

http://www.xenocafe.com/tutorials/dns_linux/redhat/dns_linux_redhat-part1.php

Regards,
Asif Sharif
Regards,
Asif Sharif
Edwin Ruiz_2
Super Advisor

Re: Configuring DNS SERver on RH A.S

Thx! i dont have errors now... i will try the configuration... thx for ur help