cache_bdg
02-11-2002, 12:06
Chào bác, Tôi là thành viên mới của diễn đàn. Tôi vừa học về HĐH linux ( tôi tham khảo sách thôi) nhưng tôi không hiểu nhiều lắm. Tôi đang cài DNS cho nó và dung công cụ Bind 9. Nhưng mà DNS của tôi vẫn không chạy.
Tôi làm theo sách thì tôi có các file nhu sau :
//etc/named.conf
## named.conf - configuration for bind
#
# Generated automatically by bindconf, alchemist et al.
options {
directory "/var/named/";
};
zone "." {
type hint;
file "named.ca";
};
zone "0.0.127.in-addr.arpa" {
type master;
file "0.0.127.in-addr.arpa.zone";
};
zone "mydomain.test" {
type master;
file "mydomain.test.zone";
};
};
zone "0.168.192.in-addr.arpa" {
type master;
file "0.168.192.in-addr.arpa.zone";
/* This file is the reverse file for your
* local network, it is essential that this
* is in place or dns may be flakey.
*/
};
/var/named/0.0.127.in-addr.arpa.zone
$TTL 86400
@ IN SOA dns1.mydomain.test administrator.mydomain.test (
1 ; ******
28800 ; refresh
7200 ; retry
604800 ; expire
86400 ; ttk
)
@ IN NS dns1.mydomain.test
192.168.0.235 IN PTR localhost
//0.168.192.in-addr.arpa.zone
$TTL 86400
@ IN SOA @ administrator.mydomain.test (
3 ; ******
28800 ; refresh
7200 ; retry
604800 ; expire
86400 ; ttk
)
@ IN NS dns1.mydomain.test.
235 IN PTR dns1.mydomain.test.
3 IN PTR pop.mydomain.test.
4 IN PTR dns2.mydomain.test.
5 IN PTR smtp.mydomain.test.
6 IN PTR www.mydomain.test.
7 IN PTR ftp.mydomain.test.
8 IN PTR webhosting.mydomain.test.
//localhost.zone
$TTL 86400
$ORIGIN localhost.
@ 1D IN SOA @ root (
42 ; ****** (d. adams)
3H ; refresh
15M ; retry
1W ; expiry
1D ) ; minimum
1D IN NS @
1D IN A 127.0.0.1
//named.ca
; This file holds the information on root name servers needed to
; initialize cache of Internet domain name servers
; (e.g. reference this file in the "cache . <file>"
; configuration file of BIND domain name servers).
;
; This file is made available by InterNIC registration services
; under anonymous FTP as
; file /domain/named.root
; on server FTP.RS.INTERNIC.NET
; -OR- under Gopher at RS.INTERNIC.NET
; under menu InterNIC Registration Services (NSI)
; submenu InterNIC Registration Archives
; file named.root
;
; last update: Aug 22, 1997
; related version of root zone: 1997082200
;
;
; formerly NS.INTERNIC.NET
;
. 3600000 IN NS A.ROOT-SERVERS.NET.
A.ROOT-SERVERS.NET. 3600000 A 198.41.0.4
;
; formerly NS1.ISI.EDU
;
. 3600000 NS B.ROOT-SERVERS.NET.
B.ROOT-SERVERS.NET. 3600000 A 128.9.0.107
;
; formerly C.PSI.NET
;
. 3600000 NS C.ROOT-SERVERS.NET.
C.ROOT-SERVERS.NET. 3600000 A 192.33.4.12
;
; formerly TERP.UMD.EDU
;
. 3600000 NS D.ROOT-SERVERS.NET.
D.ROOT-SERVERS.NET. 3600000 A 128.8.10.90
;
; formerly NS.NASA.GOV
//named.local
$TTL 86400
@ IN SOA localhost. root.localhost. (
1997022700 ; ******
28800 ; Refresh
14400 ; Retry
3600000 ; Expire
86400 ) ; Minimum
IN NS localhost.
1 IN PTR localhost.
//mydomain.test.zone
$TTL 86400
@ IN SOA @ administrator.mydomain.test (
2 ; ******
28800 ; refresh
7200 ; retry
604800 ; expire
86400 ; ttl
)
@ IN NS dns1.mydomain.test.
@ IN MX 10 smtp.mydomain.test.
@ IN MX 100 pop.mydomain.test.
@ IN A 127.0.0.1
dns1 IN A 192.168.0.235
dns2 IN A 192.168.0.4
smtp IN A 192.168.0.5
pop IN A 192.168.0.3
pop3 IN CNAME pop.mydomain.test.
www IN A 192.168.0.6
mail IN A 192.168.0.5
webhosting IN A 192.168.0.8
////////////////////////////////
Không biết la có sai hay thiếu gì nữa không, nhờ các bác chỉ giúp cho
Tôi làm theo sách thì tôi có các file nhu sau :
//etc/named.conf
## named.conf - configuration for bind
#
# Generated automatically by bindconf, alchemist et al.
options {
directory "/var/named/";
};
zone "." {
type hint;
file "named.ca";
};
zone "0.0.127.in-addr.arpa" {
type master;
file "0.0.127.in-addr.arpa.zone";
};
zone "mydomain.test" {
type master;
file "mydomain.test.zone";
};
};
zone "0.168.192.in-addr.arpa" {
type master;
file "0.168.192.in-addr.arpa.zone";
/* This file is the reverse file for your
* local network, it is essential that this
* is in place or dns may be flakey.
*/
};
/var/named/0.0.127.in-addr.arpa.zone
$TTL 86400
@ IN SOA dns1.mydomain.test administrator.mydomain.test (
1 ; ******
28800 ; refresh
7200 ; retry
604800 ; expire
86400 ; ttk
)
@ IN NS dns1.mydomain.test
192.168.0.235 IN PTR localhost
//0.168.192.in-addr.arpa.zone
$TTL 86400
@ IN SOA @ administrator.mydomain.test (
3 ; ******
28800 ; refresh
7200 ; retry
604800 ; expire
86400 ; ttk
)
@ IN NS dns1.mydomain.test.
235 IN PTR dns1.mydomain.test.
3 IN PTR pop.mydomain.test.
4 IN PTR dns2.mydomain.test.
5 IN PTR smtp.mydomain.test.
6 IN PTR www.mydomain.test.
7 IN PTR ftp.mydomain.test.
8 IN PTR webhosting.mydomain.test.
//localhost.zone
$TTL 86400
$ORIGIN localhost.
@ 1D IN SOA @ root (
42 ; ****** (d. adams)
3H ; refresh
15M ; retry
1W ; expiry
1D ) ; minimum
1D IN NS @
1D IN A 127.0.0.1
//named.ca
; This file holds the information on root name servers needed to
; initialize cache of Internet domain name servers
; (e.g. reference this file in the "cache . <file>"
; configuration file of BIND domain name servers).
;
; This file is made available by InterNIC registration services
; under anonymous FTP as
; file /domain/named.root
; on server FTP.RS.INTERNIC.NET
; -OR- under Gopher at RS.INTERNIC.NET
; under menu InterNIC Registration Services (NSI)
; submenu InterNIC Registration Archives
; file named.root
;
; last update: Aug 22, 1997
; related version of root zone: 1997082200
;
;
; formerly NS.INTERNIC.NET
;
. 3600000 IN NS A.ROOT-SERVERS.NET.
A.ROOT-SERVERS.NET. 3600000 A 198.41.0.4
;
; formerly NS1.ISI.EDU
;
. 3600000 NS B.ROOT-SERVERS.NET.
B.ROOT-SERVERS.NET. 3600000 A 128.9.0.107
;
; formerly C.PSI.NET
;
. 3600000 NS C.ROOT-SERVERS.NET.
C.ROOT-SERVERS.NET. 3600000 A 192.33.4.12
;
; formerly TERP.UMD.EDU
;
. 3600000 NS D.ROOT-SERVERS.NET.
D.ROOT-SERVERS.NET. 3600000 A 128.8.10.90
;
; formerly NS.NASA.GOV
//named.local
$TTL 86400
@ IN SOA localhost. root.localhost. (
1997022700 ; ******
28800 ; Refresh
14400 ; Retry
3600000 ; Expire
86400 ) ; Minimum
IN NS localhost.
1 IN PTR localhost.
//mydomain.test.zone
$TTL 86400
@ IN SOA @ administrator.mydomain.test (
2 ; ******
28800 ; refresh
7200 ; retry
604800 ; expire
86400 ; ttl
)
@ IN NS dns1.mydomain.test.
@ IN MX 10 smtp.mydomain.test.
@ IN MX 100 pop.mydomain.test.
@ IN A 127.0.0.1
dns1 IN A 192.168.0.235
dns2 IN A 192.168.0.4
smtp IN A 192.168.0.5
pop IN A 192.168.0.3
pop3 IN CNAME pop.mydomain.test.
www IN A 192.168.0.6
mail IN A 192.168.0.5
webhosting IN A 192.168.0.8
////////////////////////////////
Không biết la có sai hay thiếu gì nữa không, nhờ các bác chỉ giúp cho