[Samba] DomainDnsZones bad magic

Andrew Bartlett abartlet at samba.org
Fri Mar 3 19:45:10 UTC 2023


On Fri, 2023-03-03 at 11:36 -0800, Peter Pollock via samba wrote:
> I've been called back to an old workplace to try to help with some issues
> that they have and have found that the DomainDnsZones database is not
> replicating. Everything else in the replication seems to be fine.
> 
> I ran a samba-tool dbcheck on the affected server and it returns:
> 
> ltdb:
> tdb(/var/lib/samba/private/sam.ldb.d/DC=DOMAINDNSZONES,DC=MYDOMAIN,DC=MYCOMPANY.ldb):
> tdb_rec_read bad magic 0xd9fee666 at offset=4135368
> 
> ERROR(ldb): uncaught exception - Indexed and full searches both failed!
> 
> I've tried to force sync that file from our other DC but it errors out.
> 
> Can I delete the file and manually copy it over from the good file on the
> other server?

No.  These files have per-server metadata in them, and can't be copied
around.

> This is a live environment and I don't want to try it and bork things up
> even more if it can't be done that way.

You have filesystem corruption on this server, so destroy it and
rebuild by joining a replacement from another working server.

Andrew Bartlett

-- 
Andrew Bartlett (he/him) https://samba.org/~abartlet/
Samba Team Member (since 2001) https://samba.org
Samba Developer, Catalyst IT https://catalyst.net.nz/services/samba



More information about the samba mailing list