[Samba] [samba_upgradedns] Error parsing DNS data

Andrew Bartlett abartlet at samba.org
Fri May 27 22:09:59 UTC 2016

On Sun, 2016-05-22 at 14:24 +0200, Bouke J. Henstra wrote:
> Hello,
> I am trying to change over from bind9 to internal dns.
> For some reason I keep getting the following error:
> Error parsing DNS data from '/opt/samba/private/dns/TH01.INET.zone'
> ()
> I have inspected TH01.INET.ZONE but I could not find an error.
> I do not understand this error message. I am hoping someone could
> help
> me with this issue please. Your help will be very much appreciated.
> Many thanks.
> Notes:
> I am currently running version 4.1.17 (I will upgrade to the latest
> version after resolving this issue).
> I am running the samba_upgradedns command as root after stopping
> samba
> and bind9.

I take it you are trying to move from the flatfile based bind to internal.

The samba_upgradedns script is pretty simple, and uses the dnspython
library to read zone files.  It certainly could be the case that it
just can't read the zone file after bind9 has been doing dynamic
updates on it.
Perhaps get a newer dnspython lib on your system, and see if that
In many ways you are lucky, as this script is a little too lax with the
exception handling, and any error at all means it will just re-create
the DNS data from scratch, without importing the data (please file a
The second exception (on ncName) is fixed in 4.4.

Andrew Bartlett

Andrew Bartlett                       http://samba.org/~abartlet/
Authentication Developer, Samba Team  http://samba.org
Samba Developer, Catalyst IT          http://catalyst.net.nz/services/samba

More information about the samba mailing list