RHEL5下DNS配置
2010-04-06 15:18
441 查看
[align=center]RedHat EL5 DNS 配置[/align]
[align=left]在[b]RedHat EL5下配置DNS服务:[/b][/align]
[align=left]一、安装 bind(与 [b]RedHat EL4安装方法一样)[/b][/align]
[align=left]二、配置[/align]
[align=left] 1、在/etc没有了named.conf 文件,而是多了以下两个文件:[/align]
//
// named.caching-nameserver.conf
//
// Provided by Red Hat caching-nameserver package to configure the
// ISC BIND named(8) DNS server as a caching only nameserver
// (as a localhost DNS resolver only).
//
// See /usr/share/doc/bind*/sample/ for example named configuration files.
//
// DO NOT EDIT THIS FILE - use system-config-bind or an editor
// to create named.conf - edits to this file will be lost on
// caching-nameserver package upgrade.
//
options {
listen-on port 53 { 127.0.0.1; };
listen-on-v6 port 53 { ::1; };
directory "/var/named";
dump-file "/var/named/data/cache_dump.db";
statistics-file "/var/named/data/named_stats.txt";
memstatistics-file "/var/named/data/named_mem_stats.txt";
query-source port 53;
query-source-v6 port 53;
allow-query { localhost; };
};
logging {
channel default_debug {
file "data/named.run";
severity dynamic;
};
};
view localhost_resolver {
match-clients { localhost; };
match-destinations { localhost; };
recursion yes;
include "/etc/named.rfc1912.zones"; //调用named.rfc1912.zones
};
// named.rfc1912.zones: //添加解析区域
//
// Provided by Red Hat caching-nameserver package
//
// ISC BIND named zone configuration for zones recommended by
// RFC 1912 section 4.1 : localhost TLDs and address zones
//
// See /usr/share/doc/bind*/sample/ for example named configuration files.
//
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 "benet.com" IN {
type master;
file "named.benet";
allow-update { none; };
};
zone "0.168.192.in-addr.arpa" IN {
type master;
file "named.192";
allow-update { none; };
};
2、在/var/named/chroot/var/named 下建立解析库文件
三、注意事项
在建立解析库文件时,其文件所属用户和组均为root,在启动named时,日志提示“权限不够。。。”,后将两个解析库文件组改为named ,问题解决。
[align=left]在[b]RedHat EL5下配置DNS服务:[/b][/align]
[align=left]一、安装 bind(与 [b]RedHat EL4安装方法一样)[/b][/align]
[align=left]二、配置[/align]
[align=left] 1、在/etc没有了named.conf 文件,而是多了以下两个文件:[/align]
//
// named.caching-nameserver.conf
//
// Provided by Red Hat caching-nameserver package to configure the
// ISC BIND named(8) DNS server as a caching only nameserver
// (as a localhost DNS resolver only).
//
// See /usr/share/doc/bind*/sample/ for example named configuration files.
//
// DO NOT EDIT THIS FILE - use system-config-bind or an editor
// to create named.conf - edits to this file will be lost on
// caching-nameserver package upgrade.
//
options {
listen-on port 53 { 127.0.0.1; };
listen-on-v6 port 53 { ::1; };
directory "/var/named";
dump-file "/var/named/data/cache_dump.db";
statistics-file "/var/named/data/named_stats.txt";
memstatistics-file "/var/named/data/named_mem_stats.txt";
query-source port 53;
query-source-v6 port 53;
allow-query { localhost; };
};
logging {
channel default_debug {
file "data/named.run";
severity dynamic;
};
};
view localhost_resolver {
match-clients { localhost; };
match-destinations { localhost; };
recursion yes;
include "/etc/named.rfc1912.zones"; //调用named.rfc1912.zones
};
// named.rfc1912.zones: //添加解析区域
//
// Provided by Red Hat caching-nameserver package
//
// ISC BIND named zone configuration for zones recommended by
// RFC 1912 section 4.1 : localhost TLDs and address zones
//
// See /usr/share/doc/bind*/sample/ for example named configuration files.
//
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 "benet.com" IN {
type master;
file "named.benet";
allow-update { none; };
};
zone "0.168.192.in-addr.arpa" IN {
type master;
file "named.192";
allow-update { none; };
};
2、在/var/named/chroot/var/named 下建立解析库文件
三、注意事项
在建立解析库文件时,其文件所属用户和组均为root,在启动named时,日志提示“权限不够。。。”,后将两个解析库文件组改为named ,问题解决。
相关文章推荐
- RHEL5下DNS的安装配置与调试排障
- RHEL5下安装配置DNS服务
- RHEL5下DNS配置详解2
- RHEL5下DNS配置详解3
- RHEL5下DNS服务的配置与故障处理
- RHEL5下Squid+IPtables经典案例(透明代理+防火墙配置)
- RHEL5下postfix邮件服务器的安装与详细配置(二)
- RHEL5下配置vncserver
- RHEL 5下配置DHCP Relay
- RHEL5下TFTP服务器配置步骤 - 上海嵌入式家园-开发板商城 贺工
- 在RHEL5系统中配置DNS服务
- RHEL5下Squid+IPtables经典案例(透明代理+防火墙配置)
- RHEL5中DNS服务配置
- 在RHEL5下构建LAMP网站服务平台之awstats日志分析工具的配置
- RHEL5下配置和使用SVN服务
- RHEL5下安装和配置LotusNotesClient8.5
- RHEL5下用Xmanager配置远程连接
- rhel5下配置dhcp服务器
- RHEL DNS 配置教程
- Redhat enterprise 5下 linux配置DNS 之二