LinuxSir.cn,穿越时空的Linuxsir!

 找回密码
 注册
搜索
热搜: shell linux mysql
查看: 725|回复: 1

求助:FC3下配置DNS

[复制链接]
发表于 2006-8-14 19:49:59 | 显示全部楼层 |阅读模式
非常感谢各位花点时间看,谢谢!

主机IP:192.168.0.1
主机名:saturn.tanglab.net
我想配置一个DNS,对我内网的ip进行解析,我的配置文件如下:
*********/etc/hosts***********************
# Do not remove the following line, or various programs
# that require network functionality will fail
192.168.0.1     saturn.tanglab.net      saturn
127.0.0.1       localhost       localhost

*********/etc/host.conf********************
order hosts,bind
multi on

*********/etc/resolv.conf*******************  
nameserver 192.168.0.1
search tanglab.net
domain tanglab.net

*********/etc/named.conf*******************

// named.conf for Red Hat caching-nameserver
// generated by named-bootconf.pl

options {
        directory "/var/named";
//      forward  first;
        forwarders {
        202.38.193.33;
        };
        /*
         * 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
zone "." IN {
        type hint;
        file "named.ca";
};

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

zone "tanglab.net" IN {
        type master;
        file "named.tanglab";
};

zone "0.168.192.in-addr.arpa" IN {
        type master;
        file "named.192";
};
include "/etc/rndc.key";

*********/etc/named/named.192******************
$TTL  86400
@ IN SOA saturn.tanglab.net. root.saturn.tanglab.net.  (
                                    1997022708  ; Serial
                                    28800       ; Refresh
                                    14400       ; Retry
                                    3600000     ; Expire
                                    86400 )     ; Minimum
IN NS saturn.tanglab.net.
1 IN PTR saturn.tanglab.net.

*********/etc/named/named.tanglab***************
@ IN SOA saturn.tanglab.net. root.saturn.tanglab.net. (
                                    1997022702 ; Serial
                                    28800      ; Refresh
                                    14400      ; Retry
                                    3600000    ; Expire
                                    86400 )    ; Minimum
IN NS saturn.tanglab.net.
IN MX 10 saturn.tanglab.net.
saturn    IN  A  192.168.0.1
localhost IN  A  127.0.0.1
cjc       IN  A  192.168.0.53
www       IN  CNAME  saturn.tanglab.net.

在配置完后,运行nslookup saturn.tanglab.net出现如下错误:
Server:         192.168.0.1
Address:        192.168.0.1#53

** server can't find saturn.tanglab.net: SERVFAIL

我不知道哪里出错了,恳请各位高手解答,十分感谢!
发表于 2006-8-15 17:33:10 | 显示全部楼层
1 IN PTR saturn.tanglab.net.
www IN CNAME saturn.tanglab.net.
后面不需要家点。
cjc IN A 192.168.0.53
www IN CNAME saturn.tanglab.net.
根据这个你解析的时候应该是:nslookup cjc/www.tanglab.net才对啊!!!
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

快速回复 返回顶部 返回列表