YanoRyuichi.com/
Wiki
Blog
GitHub
Sandbox
開始行:
* 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の編集 (/etc/namedb/rndc.conf)[#xb3d7402]
options {
default-server localhost;
default-key "key";
};
server localhost {
key "key";
};
key "key" {
algorithm hmac-md5;
secret "ABCDEFG12345;
};
↑「key "key" {}」の部分はrndc.keyのそれをそのままコピーす...
** namedの設定 [#j5d10a03]
*** named.confの編集(/var/named/etc/namedb/named.conf) [#...
options {
directory "/etc/namedb";
pid-file "/var/run/named/pid";
dump-file "/var/dump/named_dump.db";
statistics-file "/var/stats/named.stats";
forwarders {
192.168.0.100;
};
};
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.zone";
};
*** example.netゾーン(/var/named/etc/namedb/master/exampl...
$TTL 86400
@ IN SOA ns.example.room. root.ns.example...
2007071500 ...
10800 ...
3600 ...
604800 ...
86400 ) ...
IN NS ns.example.room.
IN MX 10 mail.example.room.
ns IN A 192.168.1.10
www IN A 192.168.1.20
mail IN A 192.168.1.30
*** 127.0.0.1 ゾーン(/var/named/etc/namedb/master/localho...
$TTL 604800
@ IN SOA localhost. root.localhost. (
1 ; Serial
604800 ; Refresh
86400 ; Retry
2419200 ; Expire
604800 ) ; Negative Cache...
;
@ IN NS localhost.
1.0.0 IN PTR localhost.
** 起動 [#yae31f51]
named -u bind -c /etc/namedb/named.conf
** 自動起動 [#u71f5f59]
/etc/rc.confを以下のようにする。
named_enable="YES"
named_program="/usr/sbin/named"
named_flags="-u bind -c /etc/namedb/named.conf"
named_uid="bind"
named_chrootdir=""
named_chroot_autoupdate="NO"
named_symlink_enable="NO"
終了行:
* 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の編集 (/etc/namedb/rndc.conf)[#xb3d7402]
options {
default-server localhost;
default-key "key";
};
server localhost {
key "key";
};
key "key" {
algorithm hmac-md5;
secret "ABCDEFG12345;
};
↑「key "key" {}」の部分はrndc.keyのそれをそのままコピーす...
** namedの設定 [#j5d10a03]
*** named.confの編集(/var/named/etc/namedb/named.conf) [#...
options {
directory "/etc/namedb";
pid-file "/var/run/named/pid";
dump-file "/var/dump/named_dump.db";
statistics-file "/var/stats/named.stats";
forwarders {
192.168.0.100;
};
};
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.zone";
};
*** example.netゾーン(/var/named/etc/namedb/master/exampl...
$TTL 86400
@ IN SOA ns.example.room. root.ns.example...
2007071500 ...
10800 ...
3600 ...
604800 ...
86400 ) ...
IN NS ns.example.room.
IN MX 10 mail.example.room.
ns IN A 192.168.1.10
www IN A 192.168.1.20
mail IN A 192.168.1.30
*** 127.0.0.1 ゾーン(/var/named/etc/namedb/master/localho...
$TTL 604800
@ IN SOA localhost. root.localhost. (
1 ; Serial
604800 ; Refresh
86400 ; Retry
2419200 ; Expire
604800 ) ; Negative Cache...
;
@ IN NS localhost.
1.0.0 IN PTR localhost.
** 起動 [#yae31f51]
named -u bind -c /etc/namedb/named.conf
** 自動起動 [#u71f5f59]
/etc/rc.confを以下のようにする。
named_enable="YES"
named_program="/usr/sbin/named"
named_flags="-u bind -c /etc/namedb/named.conf"
named_uid="bind"
named_chrootdir=""
named_chroot_autoupdate="NO"
named_symlink_enable="NO"
ページ名: