Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 328697

Summary: net-dns/bind-9.7.0_p2: not start with zone in mysql database via dlz
Product: Gentoo Linux Reporter: Fabian Fingerle <fabian>
Component: [OLD] ServerAssignee: Gentoo Linux bug wranglers <bug-wranglers>
Status: RESOLVED INVALID    
Severity: critical    
Priority: High    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---

Description Fabian Fingerle 2010-07-17 08:33:22 UTC
bind-9.7.0 with dlz and mysql support does not start with following config and debug message:


dlz "Mysql zone" {
   database "mysql
   {host=localhost dbname=test user=test pass=test}
   {SELECT zone FROM records WHERE zone = '%zone%'}
   {SELECT ttl, type, mx_priority, IF(type = 'TXT', CONCAT('\"',data,'\"'), data) AS data
    FROM records
    WHERE zone = '%zone%' AND host = '%record%' AND type <> 'SOA' AND type <> 'NS'}
   {SELECT ttl, type, data, primary_ns, resp_contact, serial, refresh, retry, expire, minimum
    FROM records
    WHERE zone = '%zone%' AND (type = 'SOA' OR type='NS')}
   {SELECT ttl, type, host, mx_priority, IF(type = 'TXT', CONCAT('\"',data,'\"'), data) AS data, resp_contact, serial, refresh, retry, expire, minimum
    FROM records
    WHERE zone = '%zone%' AND type <> 'SOA' AND type <> 'NS'}
   {SELECT zone FROM xfr where zone='%zone%' AND client = '%client%'}";
};



17-Jul-2010 10:09:23.032 generating session key for dynamic DNS
17-Jul-2010 10:09:23.032 Loading 'Mysql zone' using driver mysql
17-Jul-2010 10:09:23.032 Loading SDLZ driver.
17-Jul-2010 10:09:23.032 Required token $zone$ not found.
17-Jul-2010 10:09:23.032 Could not build all nodes query list
17-Jul-2010 10:09:23.033 mysql driver could not create database instance object.

Reproducible: Always
Comment 1 Christian Ruppert (idl0r) gentoo-dev 2010-07-17 09:40:27 UTC
The tokens has been changed to "$foo$", take a look at bug 238681.
Those patches has been applied by upstream as well and will be available in newer (official) bind versions like 9.7.1.