[求助]CentOS5.2+Bind9.5.0P2+DLZ安裝完成後客戶端nslookup出現錯誤
當前的named.conf和view.conf的內容見5樓
安裝和配置過程都沒有問題,資料庫中的數據如下圖所示:
客戶端出錯信息如下:
C:\Documents and Settings\Administrator>nslookup www.elites.cn
*** Can't find server name for address 218.194.147.108: Query refused
Server: UnKnown
Address: 218.194.147.108
*** UnKnown can't find www.elites.cn: Server failed
伺服器出錯信息如下:
15-Aug-2008 17:53:40.059 client 202.202.144.201#1040: view CERNET: query: 108.147.194.218.in-addr.arpa IN PTR +
15-Aug-2008 17:53:40.060
Query String: select zone from dns_records where zone = '108.147.194.218.in-addr.arpa'
15-Aug-2008 17:53:40.063
Query String: select zone from dns_records where zone = '147.194.218.in-addr.arpa'
15-Aug-2008 17:53:40.067
Query String: select zone from dns_records where zone = '194.218.in-addr.arpa'
15-Aug-2008 17:53:40.071
Query String: select zone from dns_records where zone = '218.in-addr.arpa'
15-Aug-2008 17:53:40.075
Query String: select zone from dns_records where zone = 'in-addr.arpa'
15-Aug-2008 17:53:40.078
Query String: select zone from dns_records where zone = 'arpa'
15-Aug-2008 17:53:40.082 client 202.202.144.201#1040: view CERNET: query (cache) '108.147.194.218.in-addr.arpa/PTR/IN' denied
15-Aug-2008 17:53:40.130 client 202.202.144.201#1041: view CERNET: query: www.elites.cn IN A +
15-Aug-2008 17:53:40.131
Query String: select zone from dns_records where zone = 'www.elites.cn'
15-Aug-2008 17:53:40.143
Query String: select zone from dns_records where zone = 'elites.cn'
15-Aug-2008 17:53:40.155
Query String: select ttl, type, mx_priority, case when lower(type)='txt' then concat('"', data, '"')
else data end from dns_records where zone = 'elites.cn' and host = 'www'
and not (type = 'SOA' or type = 'NS')
15-Aug-2008 17:53:40.165 buffer-0xbfe13e54:1: "10" is not a decimal dotted quad
15-Aug-2008 17:53:40.166 dns_rdata_fromtext: buffer-0xbfe13e54:1: near '192.168.93.128': extra input text
15-Aug-2008 17:53:40.166 dns_sdlz_putrr returned error. Error code was: extra input text
15-Aug-2008 17:53:40.166
Query String: select ttl, type, mx_priority, case when lower(type)='txt' then concat('"', data, '"')
else data end from dns_records where zone = 'elites.cn' and host = '*'
and not (type = 'SOA' or type = 'NS')
15-Aug-2008 17:53:40.174 buffer-0xbfe13e54:1: "10" is not a decimal dotted quad
15-Aug-2008 17:53:40.175 dns_rdata_fromtext: buffer-0xbfe13e54:1: near '192.168.93.128': extra input text
15-Aug-2008 17:53:40.176 dns_sdlz_putrr returned error. Error code was: extra input text
15-Aug-2008 17:53:40.176
Query String: select ttl, type, mx_priority, case when lower(type)='txt' then concat('"', data, '"')
else data end from dns_records where zone = 'elites.cn' and host = '@'
and not (type = 'SOA' or type = 'NS')
15-Aug-2008 17:53:40.179 buffer-0xbfe13c04:1: "10" is not a decimal dotted quad
15-Aug-2008 17:53:40.181 dns_rdata_fromtext: buffer-0xbfe13c04:1: near '192.168.93.128': extra input text
15-Aug-2008 17:53:40.181 dns_sdlz_putrr returned error. Error code was: extra input text
15-Aug-2008 17:53:40.181
Query String: select ttl, type, mx_priority, case when lower(type)='txt' then concat('"', data, '"')
else data end from dns_records where zone = 'elites.cn' and host = '*'
and not (type = 'SOA' or type = 'NS')
15-Aug-2008 17:53:40.187 buffer-0xbfe13c04:1: "10" is not a decimal dotted quad
15-Aug-2008 17:53:40.188 dns_rdata_fromtext: buffer-0xbfe13c04:1: near '192.168.93.128': extra input text
15-Aug-2008 17:53:40.188 dns_sdlz_putrr returned error. Error code was: extra input text
15-Aug-2008 17:53:40.196 client 202.202.144.201#1042: view CERNET: query: www.elites.cn IN A +
15-Aug-2008 17:53:40.197
Query String: select zone from dns_records where zone = 'www.elites.cn'
15-Aug-2008 17:53:40.200
Query String: select zone from dns_records where zone = 'elites.cn'
15-Aug-2008 17:53:40.205
Query String: select ttl, type, mx_priority, case when lower(type)='txt' then concat('"', data, '"')
else data end from dns_records where zone = 'elites.cn' and host = 'www'
and not (type = 'SOA' or type = 'NS')
15-Aug-2008 17:53:40.210 buffer-0xbfe13e54:1: "10" is not a decimal dotted quad
15-Aug-2008 17:53:40.210 dns_rdata_fromtext: buffer-0xbfe13e54:1: near '192.168.93.128': extra input text
15-Aug-2008 17:53:40.210 dns_sdlz_putrr returned error. Error code was: extra input text
15-Aug-2008 17:53:40.211
Query String: select ttl, type, mx_priority, case when lower(type)='txt' then concat('"', data, '"')
else data end from dns_records where zone = 'elites.cn' and host = '*'
and not (type = 'SOA' or type = 'NS')
15-Aug-2008 17:53:40.216 buffer-0xbfe13e54:1: "10" is not a decimal dotted quad
15-Aug-2008 17:53:40.217 dns_rdata_fromtext: buffer-0xbfe13e54:1: near '192.168.93.128': extra input text
15-Aug-2008 17:53:40.217 dns_sdlz_putrr returned error. Error code was: extra input text
15-Aug-2008 17:53:40.218
Query String: select ttl, type, mx_priority, case when lower(type)='txt' then concat('"', data, '"')
else data end from dns_records where zone = 'elites.cn' and host = '@'
and not (type = 'SOA' or type = 'NS')
15-Aug-2008 17:53:40.224 buffer-0xbfe13c04:1: "10" is not a decimal dotted quad
15-Aug-2008 17:53:40.224 dns_rdata_fromtext: buffer-0xbfe13c04:1: near '192.168.93.128': extra input text
15-Aug-2008 17:53:40.224 dns_sdlz_putrr returned error. Error code was: extra input text
15-Aug-2008 17:53:40.224
Query String: select ttl, type, mx_priority, case when lower(type)='txt' then concat('"', data, '"')
else data end from dns_records where zone = 'elites.cn' and host = '*'
and not (type = 'SOA' or type = 'NS')
15-Aug-2008 17:53:40.236 buffer-0xbfe13c04:1: "10" is not a decimal dotted quad
15-Aug-2008 17:53:40.250 dns_rdata_fromtext: buffer-0xbfe13c04:1: near '192.168.93.128': extra input text
15-Aug-2008 17:53:40.250 dns_sdlz_putrr returned error. Error code was: extra input text
請有經驗的朋友、高手們幫忙看看問題出在哪裡了
[ 本帖最後由 gregry 於 2008-8-21 17:49 編輯 ]
《解決方案》
54次瀏覽都木有兄弟幫忙看看嗎,還是這個問題真的很難啊
《解決方案》
貼出named.conf文件看看,別人才好幫你..
《解決方案》
我的到是沒問題,不知道是是否做了VIEW,,我的namd.conf
《解決方案》
回復 #4 badb0y 的帖子
你沒做View吧。。。
下邊是我現在用的named.conf
key "rndc-key" {
algorithm hmac-md5;
secret "/pXpZG2+C42eySyPZ5uh6A==";
};
controls {
inet 127.0.0.1 port 953
allow { 127.0.0.1; } keys { "rndc-key"; };
};
options {
directory "/usr/local/named/etc";
pid-file "/usr/local/named/var/run/named.pid";
listen-on port 53 { 127.0.0.1;192.168.93.128; };
allow-query { any; };
recursion no;
allow-query-cache { none; };
allow-recursion { none; };
};
include "acl.conf";
include "view.conf";
acl.conf沒什麼特殊的,就是定義了一些IP地址段,下邊是我在用的view.conf
view "CERNET" {
match-clients{ CERNET; };
//recursion no;
allow-query-cache { none; };
allow-recursion { none; };
zone "." {
type hint;
file "named.root";
};
zone "localhost" {
type master;
file "localhost.zone";
allow-update { none; };
};
zone "0.0.127.IN-ADDR.ARPA" {
type master;
file "localhost.rev";
notify no;
};
dlz "CERNET_zone" {
database "mysql
{host=**** dbname=**** user=**** pass=****}
{select zone from dns_records where zone = '%zone%'}
{select ttl, type, mx_priority, case when lower(type)='txt' then concat('\"', data, '\"')
when lower(type) = 'soa' then concat_ws(' ', data, resp_person, serial, refresh, retry, expire, minimum)
else data end from dns_records where zone = '%zone%' and host = '%record%'}";
};
};
view "ANY_view" {
match-clients{ any; };
#recursion no;
allow-query-cache { none; };
allow-recursion { none; };
zone "." {
type hint;
file "named.root";
};
zone "localhost" {
type master;
file "localhost.zone";
allow-update { none; };
};
zone "0.0.127.IN-ADDR.ARPA" {
type master;
file "localhost.rev";
notify no;
};
dlz "chinanet_zone" {
database "mysql
{host=**** dbname=**** user=**** pass=****}
{select zone from dns_records where zone = '%zone%'}
{select ttl, type, mx_priority, case when lower(type)='txt' then concat('\"', data, '\"')
else data end from dns_records where zone = '%zone%' and host = '%record%'
and not (type = 'SOA' or type = 'NS')}
{select ttl, type, mx_priority, data, resp_person, serial, refresh, retry, expire, minimum
from dns_records where zone = '%zone%' and (type = 'SOA' or type='NS')}
{select ttl, type, host, mx_priority, data, resp_person, serial, refresh, retry, expire,
minimum from dns_records where zone = '%zone%' and not (type = 'SOA' or type = 'NS')}
{select zone from xfr_table where zone = '%zone%' and client = '%client%'}
{update data_count set count = count + 1 where zone ='%zone%'}";
};
};
《解決方案》
不是懸賞貼就沒人幫忙了啊?我記得CU不是這個風氣吧。。。
《解決方案》
回復 #6 gregry 的帖子
不好意思,,在搞VIEW的時候,出現很多問題,所以沒搞成,
《解決方案》
回復 2# gregry
因為你的數據有錯誤,mx_priority應該設置為 DEFAULT NULL ,而不是0