• 追加された行はこの色です。
  • 削除された行はこの色です。
* BIND9インストール(FreeBSD) [#i849de05]

** 概要 [#d350bcd5]
FreeBSD6.2にBIND9をインストールする。なお、chrootはしない。

** インストール [#l89f01f8]
portsで。
 cd /usr/ports/dns/bind9
 make install

** rndcの設定 [#t50d45c2]
BIND9の起動などはrndcコマンドを用いる。
*** 鍵の作成 [#z6769224]
 rndc-confgen -a
 chown bind /etc/namedb/rndc.key
rndc.keyが出来たが、DNSサーバはユーザbindで実行する予定なので、オーナーを変更しておく。


*** rndc.confの編集 [#xb3d7402]
/etc/namedb/rndc.conf:

 options {        
        default-server  localhost;
        default-key     "key";
 };
 
 server localhost {
        key     "key";
 };
 
 key "key" {
        algorithm       hmac-md5;
        secret          "ABCDEFG12345;
 };

↑「key "key" {}」の部分はrndc.keyのそれをそのままコピーする。

** namedの設定 [#j5d10a03]
 options {
        directory       "/etc/namedb";
        pid-file        "/var/run/named/pid";
        dump-file       "/var/dump/named_dump.db";
        statistics-file "/var/stats/named.stats";
 
        //listen-on     { 127.0.0.1; };
 
     //forward only;
 
 /*
        forwarders {
                127.0.0.1;
        };
 */
 };
 
 include "rndc.key";
 
 zone "." {
        type hint;
        file "named.root";
 };
 
 zone "0.0.127.IN-ADDR.ARPA" {
        type master;
        file "master/localhost.rev";
 };
 
 zone "example.net" {
        type master;
        file "master/example.net";
 };
 
** 起動 [#yae31f51]
 named -u bind -c /etc/namedb/named.conf


トップ   新規 一覧 検索 最終更新   ヘルプ   最終更新のRSS