Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[SOLVED] Bind 9.7.0_p1 and DLZ?
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
gixer
n00b
n00b


Joined: 22 Nov 2003
Posts: 28
Location: Cypress, CA, USA

PostPosted: Wed May 26, 2010 12:59 pm    Post subject: [SOLVED] Bind 9.7.0_p1 and DLZ? Reply with quote

I just updated to Bind 9.7.0_p1 and suddenly my DLZ is no longer working! It segfaults with the following error:

26-May-2010 05:48:02.611 Loading 'Mysql zone' using driver mysql
26-May-2010 05:48:02.611 Loading SDLZ driver.
26-May-2010 05:48:02.611 Required token $zone$ not found.
26-May-2010 05:48:02.611 Could not build all nodes query list
26-May-2010 05:48:02.611 mysql driver could not create database instance object.
Segmentation fault (core dumped)

I have not changed the named.conf file, and it's been working for years! I'm wondering if anyone else has run into this, or if there's been some kind of change to 9.7.0?

Downgrading to 9.4.3-P5, the problem goes away, and everything is good again.

Below is my 'working' dlz config in 9.4.3-P5:

dlz "Mysql zone" {
database "mysql
{host=localhost dbname=xxxxx ssl=false port=3306 user=xxxxx pass=xxxxxx}
{select zone from dns_records where zone = '%zone%' limit 1}
{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%'}";
};

Appreciate any help/comments....

-Allan
_________________
If you had to rebuild your car's engine on the freeway, every week, would that be ok? Then why would you use windowz? :)


Last edited by gixer on Wed Mar 23, 2011 12:42 am; edited 1 time in total
Back to top
View user's profile Send private message
erik258
Advocate
Advocate


Joined: 12 Apr 2005
Posts: 2650
Location: Twin Cities, Minnesota, USA

PostPosted: Fri May 28, 2010 4:20 am    Post subject: Reply with quote

Not many use DLZ, from what I know, and your chances of getting relevant help from the gentooers at this point seem pretty slim. I personally forsook DLZ long ago rather than patch it to better handle losing its mysql connection. But the error seems to suggest that maybe you need to update your configuration to work with the new versions, since the error seems to say that something's wrong with your config.

Anyhow, if you want a real answer I recommend the dlz mailing list.

http://bind-dlz.sourceforge.net/mailing_list.html
_________________
Configuring a Firewall? Try my iptables configuration
LinuxCommando.com is my blog for linux-related scraps and tidbits. Stop by for a visit!
Back to top
View user's profile Send private message
gixer
n00b
n00b


Joined: 22 Nov 2003
Posts: 28
Location: Cypress, CA, USA

PostPosted: Wed Mar 23, 2011 12:42 am    Post subject: [SOLVED] Bind 9.7.0_p1 and DLZ? Reply with quote

Ok, so MONTHS later, I found the answer to this! Thought I would share. Those using DLZ with Bind, like myself, WILL run into this problem! If you look at the docs on the homepage for DLZ, the examples it gives are WRONG!! Only slightly, but enough to crash bind when attempting to use DLZ. Here's what's wrong:

In the examples, it uses '%zone%' and '%record%' ... really they MUST be '$zone$' and '$record$' ... any 'token' is with a $ NOT a %. I don't know at what version this changed, but no one bothered to update the docs!! Anyways I finally found it and hope it saves someone else time and effort.
_________________
If you had to rebuild your car's engine on the freeway, every week, would that be ok? Then why would you use windowz? :)
Back to top
View user's profile Send private message
jelf
n00b
n00b


Joined: 01 Jul 2014
Posts: 8

PostPosted: Fri Sep 18, 2015 10:13 pm    Post subject: Re: [SOLVED] Bind 9.7.0_p1 and DLZ? Reply with quote

gixer wrote:
Ok, so MONTHS later, I found the answer to this! Thought I would share. Those using DLZ with Bind, like myself, WILL run into this problem! If you look at the docs on the homepage for DLZ, the examples it gives are WRONG!! Only slightly, but enough to crash bind when attempting to use DLZ. Here's what's wrong:

In the examples, it uses '%zone%' and '%record%' ... really they MUST be '$zone$' and '$record$' ... any 'token' is with a $ NOT a %. I don't know at what version this changed, but no one bothered to update the docs!! Anyways I finally found it and hope it saves someone else time and effort.


God bless you
_________________
Sorry for my english, i'm trying
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum