免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
最近访问板块 发新帖
查看: 3783 | 回复: 1
打印 上一主题 下一主题

[DNS] !!求BIND 9.8.0 安装的正确步骤!感谢! [复制链接]

论坛徽章:
0
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2011-03-10 14:57 |只看该作者 |倒序浏览
本帖最后由 wanchoufei 于 2011-03-10 15:02 编辑

BIND9.8.0 安装后 日志报错:

日志报错:  managed-keys-zone     file not found    为什么会报这个错呢?

1-Jan-2011 09:14:37.774 general: error: managed-keys-zone ./IN/view_cnc: loading from master file 193f2c6c0a7025dc2fd63f6e5ed3c200b
349f90da400827d18522885d2e64f9d.mkeys failed: file not found
11-Jan-2011 09:14:37.785 general: error: managed-keys-zone ./IN/view_telecom: loading from master file 4b19585afce12358b4e1d48d66597
bf8f0909e18ecbae3e72028c955758de4b4.mkeys failed: file not found
11-Jan-2011 09:14:37.787 general: error: managed-keys-zone ./IN/view_mobile: loading from master file d9e79655283c4cfb75f4a0fe9a2db9
37f690eb59fd82bf943c52db95aec68979.mkeys failed: file not found

日志异常: automatic empty zone  是什么东西??起什么作用呢?

Mar 10 14:47:52 localhost named[23480]: automatic empty zone: view India: 0.IN-ADDR.ARPA
Mar 10 14:47:52 localhost named[23480]: automatic empty zone: view India: 127.IN-ADDR.ARPA
Mar 10 14:47:52 localhost named[23480]: automatic empty zone: view India: 254.169.IN-ADDR.ARPA
Mar 10 14:47:52 localhost named[23480]: automatic empty zone: view India: 2.0.192.IN-ADDR.ARPA
Mar 10 14:47:52 localhost named[23480]: automatic empty zone: view India: 100.51.198.IN-ADDR.ARPA
Mar 10 14:47:52 localhost named[23480]: automatic empty zone: view India: 113.0.203.IN-ADDR.ARPA
Mar 10 14:47:52 localhost named[23480]: automatic empty zone: view India: 255.255.255.255.IN-ADDR.ARPA
Mar 10 14:47:52 localhost named[23480]: automatic empty zone: view India: 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.0.IP6.ARPA
Mar 10 14:47:52 localhost named[23480]: automatic empty zone: view India: 1.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
Mar 10 14:47:52 localhost named[23480]: automatic empty zone: view India: D.F.IP6.ARPA
Mar 10 14:47:52 localhost named[23480]: automatic empty zone: view India: 8.E.F.IP6.ARPA
Mar 10 14:47:52 localhost named[23480]: automatic empty zone: view India: 9.E.F.IP6.ARPA
Mar 10 14:47:52 localhost named[23480]: automatic empty zone: view India: A.E.F.IP6.ARPA
Mar 10 14:47:52 localhost named[23480]: automatic empty zone: view India: B.E.F.IP6.ARPA
Mar 10 14:47:52 localhost named[23480]: automatic empty zone: view India: 8.B.D.0.1.0.0.2.IP6.ARPA
Mar 10 14:47:52 localhost named[23480]: set up managed keys zone for view ohter-network, file 'aafdb45275c62d96f12704c05a3326c481649a6cb608310252446b5769ab58fa.mkeys'
Mar 10 14:47:52 localhost named[23480]: automatic empty zone: view ohter-network: 0.IN-ADDR.ARPA
Mar 10 14:47:52 localhost named[23480]: automatic empty zone: view ohter-network: 127.IN-ADDR.ARPA
Mar 10 14:47:52 localhost named[23480]: automatic empty zone: view ohter-network: 254.169.IN-ADDR.ARPA
Mar 10 14:47:52 localhost named[23480]: automatic empty zone: view ohter-network: 2.0.192.IN-ADDR.ARPA
Mar 10 14:47:52 localhost named[23480]: automatic empty zone: view ohter-network: 100.51.198.IN-ADDR.ARPA
Mar 10 14:47:52 localhost named[23480]: automatic empty zone: view ohter-network: 113.0.203.IN-ADDR.ARPA
Mar 10 14:47:52 localhost named[23480]: automatic empty zone: view ohter-network: 255.255.255.255.IN-ADDR.ARPA
Mar 10 14:47:52 localhost named[23480]: automatic empty zone: view ohter-network: 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.0.IP6.ARPA
Mar 10 14:47:52 localhost named[23480]: automatic empty zone: view ohter-network: 1.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
Mar 10 14:47:52 localhost named[23480]: automatic empty zone: view ohter-network: D.F.IP6.ARPA
Mar 10 14:47:52 localhost named[23480]: automatic empty zone: view ohter-network: 8.E.F.IP6.ARPA
Mar 10 14:47:52 localhost named[23480]: automatic empty zone: view ohter-network: 9.E.F.IP6.ARPA
Mar 10 14:47:52 localhost named[23480]: automatic empty zone: view ohter-network: A.E.F.IP6.ARPA
Mar 10 14:47:52 localhost named[23480]: automatic empty zone: view ohter-network: B.E.F.IP6.ARPA
Mar 10 14:47:52 localhost named[23480]: automatic empty zone: view ohter-network: 8.B.D.0.1.0.0.2.IP6.ARPA
Mar 10 14:47:52 localhost named[23480]: command channel listening on 127.0.0.1#953


我的安装过程:

tar -zxvf bind-9.8.0.tar.gz  &&  cd bind-9.8.0



./configure --prefix=/usr/local/bind-9.8.0 --with-libtool --enable-threads --disable-ipv6

--prefix=/usr/local/bind       设置bind的安装目录,默认是/usr/local。                                            
--sysconfdir=/etc/bind         设置named.conf配置文件放置的目录,默认是"$prefix/etc"
--localstatdir=/var            设置 run/named.pid 放置的目录,默认是"$prefix/var"
--with-libtool                 将BIND的库文件编译为动态共享库文件,这个选项默认是未选择的。
                               如果不选这个选项,那么编译后的named命令会比较大,lib目录中的库文件都是.a后缀的
                               如果选上这个选项,那么编译后的named命令会很小,lib目录中的库文件则是.so后缀
--enable-threads               如果你的系统有多个CPU,那么可以使用这个选项

如果 ./configure 没有报错的话,那么就可以开始编译源代码了。

make && make install

cd /usr/local/bind-9.8.0/

mkdir -p /usr/local/bind-9.8.0/var/named/log && mkdir /usr/local/bind-9.8.0/var/named/data/

/usr/local/bind-9.8.0/sbin/named -c /usr/local/bind-9.8.0/etc/named.conf &

useradd named

ps aux | grep name
root     15854  0.0  0.9  44808  9952 ?        Ssl  17:24   0:00 /usr/local/bind-9.8.0/sbin/named -c /usr/local/bind-9.8.0/etc/named.conf
root     15876  0.0  0.0   3920   656 pts/2    R+   17:28   0:00 grep name
[root@wp-linux-test1 var]#
[root@wp-linux-test1 var]# kill -9 15854
[root@wp-linux-test1 var]# chown -R named:named /usr/local/bind-9.8.0/

/usr/local/bind-9.8.0/sbin/named -u named -c /usr/local/bind-9.8.0/etc/named.conf &


我的主配置文件:

options {
        listen-on port 53 { any; };
#       listen-on-v6 port 53 { ::1; };
        directory           "/usr/local/bind-9.8.0/var/named";
        dump-file           "/usr/local/bind-9.8.0/var/named/data/cache_dump.db";
        statistics-file     "/usr/local/bind-9.8.0/var/named/data/named_stats.txt";
        memstatistics-file  "/usr/local/bind-9.8.0/var/named/data/named_mem_stats.txt";
        pid-file            "/usr/local/bind-9.8.0/var/run/named.pid";
        // Those options should be used carefully because they disable port
        // randomization
        // query-source    port 53;     
        // query-source-v6 port 53;

        allow-query     { any; };
        allow-query-cache { any; };

        forwarders     { 202.106.0.20; 8.8.8.8; };
     
};


######################################################################
# Log Definition
######################################################################

include "/usr/local/bind-9.8.0/etc/log.conf";


#################################################################################################
# Key Definition
#################################################################################################

key "rndckey" {
        algorithm hmac-md5;
        secret "**********";
};

controls {
        inet 127.0.0.1 port 953
                allow { 127.0.0.1; } keys { "rndckey"; };
};


key India-key {
    algorithm hmac-md5;
    secret "**********";
    };

key any-key {
    algorithm hmac-md5;
    secret "**********";
    };


###########################################################################################


########################################################################################

include "/usr/local/bind-9.8.0/etc/India-ip.conf";

view India  {

       match-clients { !key any-key; key India-key; India-network-ip; };
       recursion yes;
       allow-transfer {key India-key;};
       server *******{keys India-key;};  


       zone "hissage.net"  IN {
             type  master;
             file  "India/india.zone";
#            notify yes;
#            also-notify {********; };   
       };


       zone "40.92.203.in-addr.arpa" IN {
             type master;
             file "India/*******.in-addr.arpa";
       };      

       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 "." {
        type hint;
        file "named.root";
        };



};



##################################################

view ohter-network {
      
        match-clients { !key India-key; key any-key; any; };
        recursion yes;
        allow-transfer {key any-key;};
        server **.**.**.*.{keys any-key;};         


        zone "hissage.net"  IN {
             type  master;
             file  "world/world.zone";
        };

        zone "hissagetest.net"  IN {
             type  master;
             file  "world/world-2.zone";
        };


        zone "*.*.*..in-addr.arpa" IN {
             type master;
             file "world/**.**.**.in-addr.arpa";
        };      

        
               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 "." {
        type hint;
        file "named.root";
        };

};

论坛徽章:
0
2 [报告]
发表于 2011-03-10 16:46 |只看该作者
把上面的出错信息放到GOOGEL搜索栏里。
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP