Hello everyone,
somehow I broke my DNS zone managed by samba4. Unfortunately, I'm out of
ideas and you are my last hope!
When I want to open it in Windows DNS administration MSC, I get the
following error when selecting the zone: "Zone Not Loaded by DNS
Server".
When running regular DNS queries on that zone, everything works fine.
# host -t A mydomain.local
mydomain.local has address 192.168.122.1
# host -t NS mydomain.local
mydomain.local name server sambapdc.mydomain.local.
# host -t SOA mydomain.local
mydomain.local has SOA record sambapdc.mydomain.local.
hostmaster.mydomain.local. 94 900 600 86400 0
# host -t A sambapdc.mydomain.local
sambapdc.mydomain.local has address 192.168.122.1
However, when querying it with samba-tool, the problems start:
# samba-tool dns query sambapdc.mydomain.local mydomain.local @ ALL
ERROR(runtime): uncaught exception - (1383, 'WERR_INTERNAL_DB_ERROR')
File "/usr/lib/python2.7/dist-packages/samba/netcmd/__init__.py",
line 162, in _run
return self.run(*args, **kwargs)
File "/usr/lib/python2.7/dist-packages/samba/netcmd/dns.py", line
925, in run
Note: querying the _msdcs.mydomain.local works fine using
# samba-tool dns query sambapdc.mydomain.local _msdcs.mydomain.local @ ALL
so does
# samba-tool dns query sambapdc.mydomain.local mydomain.local sambapdc ALL
ldbsearch also has no problems when accessing the @ records, at least
they show up without problems when running
# ldbsearch -H /var/lib/samba/private/dns/sam.ldb -b
"DC=DomainDnsZones,DC=mydomain,DC=local"
"(objectclass=dnsNode)"
--show-binary
Is there anything I could try to get my DNS zone back?
Is there a way to dump the sam.ldb to a text file and re-build it somehow?
Thanks for your support!
PS: Here is the output for some additional samba-tool calls, maybe this
helps...
-----
# samba-tool dns serverinfo sambapdc.mydomain.local
dwVersion : 0xece0205
fBootMethod : DNS_BOOT_METHOD_DIRECTORY
fAdminConfigured : FALSE
fAllowUpdate : TRUE
fDsAvailable : TRUE
pszServerName : sambapdc.mydomain.local
pszDsContainer :
CN=MicrosoftDNS,DC=DomainDnsZones,DC=mydomain,DC=local
aipServerAddrs : ['255.255.255.255 (53)',
'255.255.255.255 (53)', '255.255.255.255 (53)',
'255.255.255.255 (53)',
'255.255.255.255 (53)', '255.255.255.255 (53)']
aipListenAddrs : ['255.255.255.255 (53)',
'255.255.255.255 (53)', '255.255.255.255 (53)',
'255.255.255.255 (53)',
'255.255.255.255 (53)', '255.255.255.255 (53)']
aipForwarders : []
dwLogLevel : 0
dwDebugLevel : 0
dwForwardTimeout : 3
dwRpcPrototol : 0x5
dwNameCheckFlag : DNS_ALLOW_MULTIBYTE_NAMES
cAddressAnswerLimit : 0
dwRecursionRetry : 3
dwRecursionTimeout : 8
dwMaxCacheTtl : 86400
dwDsPollingInterval : 180
dwScavengingInterval : 0
dwDefaultRefreshInterval : 168
dwDefaultNoRefreshInterval : 168
fAutoReverseZones : FALSE
fAutoCacheUpdate : FALSE
fRecurseAfterForwarding : FALSE
fForwardDelegations : TRUE
fNoRecursion : FALSE
fSecureResponses : FALSE
fRoundRobin : TRUE
fLocalNetPriority : FALSE
fBindSecondaries : FALSE
fWriteAuthorityNs : FALSE
fStrictFileParsing : FALSE
fLooseWildcarding : FALSE
fDefaultAgingState : FALSE
dwRpcStructureVersion : 0x2
aipLogFilter : []
pwszLogFilePath : None
pszDomainName : mydomain.local
pszForestName : mydomain.local
pszDomainDirectoryPartition : DC=DomainDnsZones,DC=mydomain,DC=local
pszForestDirectoryPartition : DC=ForestDnsZones,DC=mydomain,DC=local
dwLocalNetPriorityNetMask : 0xff
dwLastScavengeTime : 0
dwEventLogLevel : 4
dwLogFileMaxSize : 0
dwDsForestVersion : 2
dwDsDomainVersion : 2
dwDsDsaVersion : 4
fReadOnlyDC : FALSE
# samba-tool dns zoneinfo sambapdc.mydomain.local mydomain.local
pszZoneName : mydomain.local
dwZoneType : DNS_ZONE_TYPE_PRIMARY
fReverse : FALSE
fAllowUpdate : DNS_ZONE_UPDATE_SECURE
fPaused : FALSE
fShutdown : FALSE
fAutoCreated : FALSE
fUseDatabase : TRUE
pszDataFile : None
aipMasters : []
fSecureSecondaries : DNS_ZONE_SECSECURE_NO_XFER
fNotifyLevel : DNS_ZONE_NOTIFY_LIST_ONLY
aipSecondaries : []
aipNotify : []
fUseWins : FALSE
fUseNbstat : FALSE
fAging : FALSE
dwNoRefreshInterval : 168
dwRefreshInterval : 168
dwAvailForScavengeTime : 0
aipScavengeServers : []
dwRpcStructureVersion : 0x2
dwForwarderTimeout : 0
fForwarderSlave : 0
aipLocalMasters : []
dwDpFlags : DNS_DP_AUTOCREATED
DNS_DP_DOMAIN_DEFAULT DNS_DP_ENLISTED
pszDpFqdn : DomainDnsZones.mydomain.local
pwszZoneDn :
DC=mydomain.local,CN=MicrosoftDNS,DC=DomainDnsZones,DC=mydomain,DC=local
dwLastSuccessfulSoaCheck : 0
dwLastSuccessfulXfr : 0
fQueuedForBackgroundLoad : FALSE
fBackgroundLoadInProgress : FALSE
fReadOnlyZone : FALSE
dwLastXfrAttempt : 0
dwLastXfrResult : 0
# samba-tool dns zonelist sambapdc.mydomain.local
3 zone(s) found
pszZoneName : mydomain.local
Flags : DNS_RPC_ZONE_DSINTEGRATED
DNS_RPC_ZONE_UPDATE_SECURE
ZoneType : DNS_ZONE_TYPE_PRIMARY
Version : 50
dwDpFlags : DNS_DP_AUTOCREATED
DNS_DP_DOMAIN_DEFAULT DNS_DP_ENLISTED
pszDpFqdn : DomainDnsZones.mydomain.local
pszZoneName : 122.168.192.in-addr.arpa
Flags : DNS_RPC_ZONE_DSINTEGRATED
DNS_RPC_ZONE_UPDATE_SECURE
ZoneType : DNS_ZONE_TYPE_PRIMARY
Version : 50
dwDpFlags : DNS_DP_AUTOCREATED
DNS_DP_FOREST_DEFAULT DNS_DP_ENLISTED
pszDpFqdn : ForestDnsZones.mydomain.local
pszZoneName : _msdcs.mydomain.local
Flags : DNS_RPC_ZONE_DSINTEGRATED
DNS_RPC_ZONE_UPDATE_SECURE
ZoneType : DNS_ZONE_TYPE_PRIMARY
Version : 50
dwDpFlags : DNS_DP_AUTOCREATED
DNS_DP_FOREST_DEFAULT DNS_DP_ENLISTED
pszDpFqdn : ForestDnsZones.mydomain.local
--
Best regards,
-Johannes.