Sorry for taking so long to get back to you.
I've been busy with the holidays / vacation, and then getting back to work
things are always busy.
You have two problems.
Problem #1 you probably aren't even experiencing
yet. Your allow zone transfer query won't work right. It should be
something along the lines of
select id from zone_transfer_table where
zone = '%zone%' and client = '%client%'
You need to search for a match to both %zone% and
%client% so that the zone transfer will only be allowed if the zone and client
are listed together in a single row.
Problem #2 - the more important
"dns_rdata_fromtext: buffer-0x4076452c:1: near eol: unexpected end of input"
& crash error has me stumped for the moment. Try doing a make clean,
then re-doing your ./configure and then do a make, followed by make
install. See if that clears things up because it looks like your data is
ok - or at least the segment you sent is. Generally I can spot the data /
configuration issue right off and once fixed DLZ works fine. This has
almost always been the case - there have been relatively few bugs and those do
get squashed quickly. A few more bugs will be squashed in the next release
but the release that is out now is fairly stable.
If you can try DLZ on another machine..
Perhaps there is something odd on that particular machine causing a
problem. Let me know what you find and if I can be any more help in
getting things to work for you.
----- Original Message -----
Sent: Sunday, January 04, 2004 1:04
AM
Subject: Re: [Bind-dlz-testers] no
solutions ....
Hi
Ok thanks.
i run on Bind 9.2.2-P3 on a Mandrake Linux 9.2
(Kernel 2.4.22 SMP Bi Xeon 2,67 Ghz) and
MySQL 4.0.17 (ns1.phibee.net).
My named.conf (DLZ Section):
==================================================================
//#######################################################################
//##
Configuration de la base de données
DLZ
##
//#######################################################################
dlz
"Mysql zone" {
database "mysql
{host=localhost user=bind
pass=XXXXXXX dbname=Phibee ssl=false}
{select id from zone 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
zone,dns_records where id=zone_id and zone = '%zone%' and host
=
'%record%'}
{}
{select ttl, type, host,
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
zone,dns_records where id=zone_id and zone =
'%zone%'}
{select '%client%' from zone where zone =
'%zone%'}
{}";
};
==================================================================
My syslog when i start named:
Jan 4 07:50:33 ns1 named[17045]: starting
BIND 9.2.2-P3 -u named
Jan 4 07:50:33 ns1 named[17045]: using 2
CPUs
Jan 4 07:50:33 ns1 named[17047]: loading configuration from
'/etc/named.conf'
jan 4 07:50:33 ns1 named: Démarrage de named
succeeded
Jan 4 07:50:33 ns1 named[17047]: no IPv6 interfaces
found
Jan 4 07:50:33 ns1 named[17047]: listening on IPv4 interface
lo, 127.0.0.1#53
Jan 4 07:50:33 ns1 named[17047]: listening on IPv4
interface eth0, 213.41.42.129#53
Jan 4 07:50:33 ns1 named[17047]:
Loading 'Mysql zone' using driver mysql
Jan 4 07:50:33 ns1
named[17047]: command channel listening on 127.0.0.1#953
Jan 4
07:50:33 ns1 named[17047]: zone 0.0.127.in-addr.arpa/IN: loaded serial
2003122001
Jan 4 07:50:33 ns1 named[17047]: zone
26/128.42.41.213.in-addr.arpa/IN: loaded serial 2003122002
Jan 4
07:50:33 ns1 named[17047]: running
Jan 4 07:50:33 ns1 named[17047]:
zone 26/128.42.41.213.in-addr.arpa/IN: sending notifies (serial
2003122002)
==================================================================
I use a example of data structure of DLZ Mailing
List, two table into my database "Phibee".
The user are bind and the access are
Ok.
Table zone:
CREATE TABLE `zone` (
`id` int(11) unsigned NOT NULL
auto_increment,
`ttl` int(11) unsigned NOT NULL default
'86400',
`zone` varchar(50) NOT NULL default '',
`resp_person` varchar(255) default 'hostmaster',
`serial` int(11)
unsigned NOT NULL default '0',
`refresh` int(11) unsigned NOT NULL
default '86400',
`retry` int(11) unsigned NOT NULL default
'7200',
`expire` int(11) unsigned NOT NULL default
'604800',
`minimum` int(11) unsigned NOT NULL default
'86400',
PRIMARY KEY (`id`),
KEY `zona`
(`zone`)
) TYPE=MyISAM AUTO_INCREMENT=4 ;
INSERT INTO `zone` VALUES
(1, 86400, 'phibee.info', 'hostmaster', 2004010301, 86400, 7200, 604800,
86400);
and the table dns_records with data for the zone
"phibee.info":
CREATE TABLE `dns_records` (
`zone_id` int(11) unsigned NOT
NULL default '0',
`type`
enum('SOA','NS','MX','A','CNAME','TXT','HINFO','PTR') NOT NULL default
'SOA',
`host` varchar(255) default NULL,
`mx_priority`
int(3) unsigned default NULL,
`data` varchar(255) default
NULL,
KEY `zh` (`zone_id`,`host`)
) TYPE=MyISAM;
INSERT
INTO `dns_records` VALUES (1, 'SOA', ' <at> ', NULL, 'ns1.phibee.net.');
INSERT
INTO `dns_records` VALUES (1, 'NS', ' <at> ', NULL, 'ns1.phibee.net.');
INSERT
INTO `dns_records` VALUES (1, 'NS', ' <at> ', NULL, 'ns2.phibee.net.');
INSERT
INTO `dns_records` VALUES (1, 'MX', ' <at> ', 10, 'mx1.phibee.net.');
INSERT
INTO `dns_records` VALUES (1, 'MX', ' <at> ', 20, 'mx2.phibee.net.');
INSERT
INTO `dns_records` VALUES (1, 'A', ' <at> ', NULL, '213.41.42.160');
INSERT INTO
`dns_records` VALUES (1, 'A', 'www', NULL, '213.41.42.160');
INSERT INTO
`dns_records` VALUES (1, 'CNAME', 'test', NULL, 'www.phibee.info.');
==================================================================
and when i test with nslookup my server, we have
:
[root <at> ns1 etc]# !nslo
nslookup -
localhost
>
www.phibee.infoServer:
localhost
Address:
127.0.0.1#53
immediatly i have this in
/var/log/syslog
Jan 4 07:45:49 ns1 named[32320]:
dns_rdata_fromtext: buffer-0x4056430c:1: near eol: unexpected end of
input
Jan 4 07:45:49 ns1 named[32320]: dns_sdlz_putrr returned error.
Error code was: unexpected end of input
and when i want SOA information:
>set query=soa
>
phibee.info
Jan 4 07:49:39 ns1 named[17010]: dns_rdata_fromtext:
buffer-0x4076452c:1: near eol: unexpected end of input
Jan 4 07:49:39
ns1 named[17010]: dns_sdlz_putrr returned error. Error code was: unexpected
end of input
Jan 4 07:49:39 ns1 named[17010]: dns_rdata_fromtext:
buffer-0x4076426c:1: near eol: unexpected end of input
Jan 4 07:49:39
ns1 named[17010]: dns_sdlz_putrr returned error. Error code was: unexpected
end of input
Jan 4 07:49:39 ns1 named[17010]: query.c:1746: fatal
error:
Jan 4 07:49:39 ns1 named[17010]: RUNTIME_CHECK(result == 0)
failed
Jan 4 07:49:39 ns1 named[17010]: exiting (due to fatal error
in library)
and named crash .......
==================================================================
in named debug mode, this is information
:
jan 4 07:56:11 ns1 named: Query String:
select id from zone where zone = 'phibee.info'
jan 4 07:56:11 ns1
named:
jan 4 07:56:11 ns1 named: Jan 04 07:56:11.581
jan 4
07:56:11 ns1 named:
jan 4 07:56:11 ns1 named: Jan 04 07:56:11.581
dns_rdata_fromtext: buffer-0x4056452c:1: near eol: unexpected end of
input
jan 4 07:56:11 ns1 named: Jan 04 07:56:11.581 dns_sdlz_putrr
returned error. Error code was: unexpected end of input
jan 4
07:56:11 ns1 named: Jan 04 07:56:11.581
jan 4 07:56:11 ns1 named:
Query String: select ttl, type, mx_priority, case when lower(type)='txt'
then
jan 4 07:56:11 ns1 named: concat('"', data, '"')
when lower(type)='soa' then CONCAT_WS('
jan 4 07:56:11 ns1
named: ',data,resp_person,serial,refresh,retry,expire,minimum)
else data end from
jan 4 07:56:11 ns1 named:
zone,dns_records where id=zone_id and zone = 'phibee.info' and host
=
jan 4 07:56:11 ns1 named: '*'
jan 4 07:56:11 ns1
named:
jan 4 07:56:11 ns1 named: Jan 04 07:56:11.582
jan 4
07:56:11 ns1 named: Query String: select ttl, type, mx_priority, case when
lower(type)='txt' then
jan 4 07:56:11 ns1 named:
concat('"', data, '"') when lower(type)='soa' then CONCAT_WS('
jan 4
07:56:11 ns1 named:
',data,resp_person,serial,refresh,retry,expire,minimum) else data end
from
jan 4 07:56:11 ns1 named: zone,dns_records where
id=zone_id and zone = 'phibee.info' and host =
jan 4 07:56:11 ns1
named:
' <at> 'jan 4 07:56:11 ns1
named:
jan 4 07:56:11 ns1 named: Jan 04 07:56:11.582
dns_rdata_fromtext: buffer-0x4056426c:1: near eol: unexpected end of
input
jan 4 07:56:11 ns1 named: Jan 04 07:56:11.582 dns_sdlz_putrr
returned error. Error code was: unexpected end of input
jan 4
07:56:11 ns1 named: Jan 04 07:56:11.582
jan 4 07:56:11 ns1 named:
Query String: select ttl, type, mx_priority, case when lower(type)='txt'
then
jan 4 07:56:11 ns1 named: concat('"', data, '"')
when lower(type)='soa' then CONCAT_WS('
jan 4 07:56:11 ns1
named: ',data,resp_person,serial,refresh,retry,expire,minimum)
else data end from
jan 4 07:56:11 ns1 named:
zone,dns_records where id=zone_id and zone = 'phibee.info' and host
=
jan 4 07:56:11 ns1 named: '*'
jan 4 07:56:11 ns1
named:
jan 4 07:56:11 ns1 named: Jan 04 07:56:11.582 query.c:1746:
fatal error:
jan 4 07:56:11 ns1 named: Jan 04 07:56:11.582
RUNTIME_CHECK(result == 0) failed
jan 4 07:56:11 ns1 named: Jan 04
07:56:11.582 exiting (due to fatal error in library)
jan 4 07:56:11
ns1 named: Démarrage de named failedjan 4 07:56:11 ns1 named: Query
String: select ttl, type, mx_priority, case when lower(type)='txt'
then
jan 4 07:56:11 ns1 named: concat('"', data, '"')
when lower(type)='soa' then CONCAT_WS('
jan 4 07:56:11 ns1
named: ',data,resp_person,serial,refresh,retry,expire,minimum)
else data end from
jan 4 07:56:11 ns1 named:
zone,dns_records where id=zone_id and zone = 'phibee.info' and host
=
jan 4 07:56:11 ns1 named:
' <at> '
when i put into mysql client the request
:
mysql> select id from zone where zone =
'phibee.info';
+----+
| id |
+----+
| 1 |
+----+
1 row
in set (0.00 sec)
mysql>
mysql> 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
-> zone,dns_records where id=zone_id and zone =
'phibee.info' and host =
->
' <at> ' ->
;
+-------+------+-------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
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
|
+-------+------+-------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
86400 | SOA | NULL |
ns1.phibee.net.
hostmaster
2004010301
86400
7200
604800
86400
|
| 86400 | NS | NULL
|
ns1.phibee.net.
|
| 86400 | NS | NULL
|
ns2.phibee.net.
|
| 86400 | MX
| 10 |
mx1.phibee.net.
|
| 86400 | MX
| 20 |
mx2.phibee.net.
|
| 86400 | A |
NULL |
213.41.42.160
|
+-------+------+-------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------+
6
rows in set (0.00 sec)
mysql>
if you want more information, don't hesitate
;=)
thanks for your help
----- Original Message -----
Sent: Sunday, January 04, 2004 12:06
AM
Subject: Re: [Bind-dlz-testers] no
solutions ....
Jerome,
Send the DLZ section of your named.conf, a
SMALL sample of the data in your database (it should include SOA, NS, and A
records within the sample at least), and a BRIEF description of the DLZ
related tables in your database. I will take a look at them and try to
find out what's wrong with your setup. Without the above information I
can't do anything to help you.
Later
Rob
----- Original Message -----
Sent: Thursday, January 01, 2004 2:02
AM
Subject: [Bind-dlz-testers] no
solutions ....
Hi
Please help me ;=) i don't see the solution.
DLZ on my server don't works ...
The error :
Jan 1 08:48:17 ns1 named[31893]:
dns_rdata_fromtext: buffer-0x4076452c:1: near eol: unexpected end of
input
Jan 1 08:48:17 ns1 named[31893]: dns_sdlz_putrr returned
error. Error code was: unexpected end of input
Jan 1 08:48:17 ns1
named[31893]: dns_rdata_fromtext: buffer-0x4076430c:1: near eol:
unexpected end of input
Jan 1 08:48:17 ns1 named[31893]:
dns_sdlz_putrr returned error. Error code was: unexpected end of
input
Jan 1 08:57:50 ns1 named[31893]:
dns_rdata_fromtext: buffer-0x4076452c:1: near eol: unexpected end of
input
Jan 1 08:57:50 ns1 named[31893]: dns_sdlz_putrr returned
error. Error code was: unexpected end of input
Jan 1 08:57:50 ns1
named[31893]: dns_rdata_fromtext: buffer-0x4076426c:1: near eol:
unexpected end of input
Jan 1 08:57:50 ns1 named[31893]:
dns_sdlz_putrr returned error. Error code was: unexpected end of
input
Jan 1 08:57:50 ns1 named[31893]: query.c:1746: fatal
error:
Jan 1 08:57:50 ns1 named[31893]: RUNTIME_CHECK(result ==
0) failed
Jan 1 08:57:50 ns1 named[31893]: exiting (due to fatal
error in library)
I have deleted all of my database
and my conf ... i use the configuration
posted by teszter
2003-11-23 without success !
A error
in compilation ?
bye