01 October 2010

Using ODBC with bind

I ran into this last week, and the Google was failing me, so here's the reason why you sometimes get "Required token $zone$ not found." when debugging why bind won't start with ODBC. The answer is: because the DLZ documentation is slightly wrong. It delimits "zone" and "record" with % instead of $. That is, the directions show:

{select zone from dns_records where zone = '%zone%'}

But really, it should be:

{select zone from dns_records where zone = '$zone$'}

There you go. That's where that error comes from. Now hopefully the next person who hits this will be able to find an actual useful answer when they search for the error.


purplelight said...

This helped so much, all the tutorials have it wrong!

Azabecki said...

To say 'thank you' would be an understatement. For MONTHS I have been looking around for a reason as to why DLZ stopped working whenever I updated to a newer version of bind. This is EXACTLY why! I can now run bind 9.8! Thank you, thank you, thank you.