免费注册 查看新帖 |

Chinaunix

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

[OpenBSD] OpenBSD5.4 bind范例 [复制链接]

论坛徽章:
2
双子座
日期:2014-05-18 22:44:102015年迎新春徽章
日期:2015-03-04 09:58:11
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2014-04-17 21:12 |只看该作者 |倒序浏览
大概是这三个文件吧,需要的可以参考下
# uname -a                                                            
OpenBSD openbsd.my.domain 5.4 GENERIC#37 amd64
# cat /var/named/etc/named.conf                                               
// $OpenBSD: named-simple.conf,v 1.10 2009/11/02 21:12:56 jakob Exp $
//
// Example file for a simple named configuration, processing both
// recursive and authoritative queries using one cache.


// Update this list to include only the networks for which you want
// to execute recursive queries. The default setting allows all hosts
// on any IPv4 networks for which the system has an interface, and
// the IPv6 localhost address.
//
acl clients {
        localnets;
        ::1;
};

options {
        version "";     // remove this to allow version queries

        listen-on    { any; };
        listen-on-v6 { any; };

        empty-zones-enable yes;

        allow-recursion { clients; };
};

logging {
        category lame-servers { null; };
};

// Standard zones
//
zone "." {
        type hint;
        file "etc/root.hint";
};

zone "localhost" {
        type master;
        file "standard/localhost";
        allow-transfer { localhost; };
};

zone "127.in-addr.arpa" {
        type master;
        file "standard/loopback";
        allow-transfer { localhost; };
};


zone "leeqiand.cn" {
        type master;
        file "standard/leeqiand";
        allow-transfer { localhost; };
};

zone "24.168.192.in-addr.arpa" {
        type master;
        file "standard/24.168.192";
        allow-transfer { localhost; };
};
zone "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" {
        type master;
        file "standard/loopback6.arpa";
        allow-transfer { localhost; };
};


// Master zones
//
//zone "myzone.net" {
//      type master;
//      file "master/myzone.net";
//};

// Slave zones
//
//zone "otherzone.net" {
//      type slave;
//      file "slave/otherzone.net";
//      masters { 192.0.2.1; [...;] };
//};
# cat /var/named/standard/leeqiand                                            

$TTL 6h

@       IN      SOA     dns.leeqiand.cn. root.leeqiand.cn. (
                        1       ; serial
                        1h      ; refresh
                        30m     ; retry
                        7d      ; expiration
                        1h )    ; minimum

       IN               NS      dns.leeqiand.cn.      
dns    IN               A       192.168.24.144
www    IN               A       192.168.24.100
mp3    IN               A       192.168.24.200
# cat /var/named/standard/24.168.192                                          

$TTL 6h

@       IN      SOA     dns.leeqiand.cn. root.leeqiand.cn. (
                        1       ; serial
                        1h      ; refresh
                        30m     ; retry
                        7d      ; expiration
                        1h )    ; minimum
        IN      NS dns.leeqiand.cn.
144     IN   PTR  dns.leeqiand.cn.
100     IN PTR    www.leeqiand.cn.
200     IN PTR    mp3.leeqiand.cn.
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

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

清除 Cookies - ChinaUnix - Archiver - WAP - TOP