[Samba] remove dead server (samba 4.4.4)

Andrew Bartlett abartlet at samba.org
Mon Dec 19 18:40:47 UTC 2016


On Fri, 2016-12-16 at 15:50 -0200, Vinicius Bones Silva via samba
wrote:
> Hi,
> 
>      I'm trying to remove a DC from a site we have shutdown. The
> demote command is 
> throwing up this message:

...

> keeping 0 values, removing 1 values
> ERROR(<type 'exceptions.TypeError'>): uncaught exception -
> __ndr_unpack__() argument 1 
> must be string or read-only buffer, not dnsp.DnssrvRpcRecord
>    File "/usr/lib64/python2.7/site-
> packages/samba/netcmd/__init__.py", line 175, in _run
>      return self.run(*args, **kwargs)
>    File "/usr/lib64/python2.7/site-packages/samba/netcmd/domain.py",
> line 720, in run
>      remove_dc.remove_dc(samdb, logger, remove_other_dead_server)
>    File "/usr/lib64/python2.7/site-packages/samba/remove_dc.py", line
> 423, in remove_dc
>      remove_dns_account=True)
>    File "/usr/lib64/python2.7/site-packages/samba/remove_dc.py", line
> 351, in 
> offline_remove_ntds_dc
>      remove_dns_account=remove_dns_account)
>    File "/usr/lib64/python2.7/site-packages/samba/remove_dc.py", line
> 266, in 
> offline_remove_server
>      remove_dns_references(samdb, logger, dnsHostName)
>    File "/usr/lib64/python2.7/site-packages/samba/remove_dc.py", line
> 186, in 
> remove_dns_references
>      for v in values if not to_remove(v) ]
>    File "/usr/lib64/python2.7/site-packages/samba/remove_dc.py", line
> 160, in to_remove
>      dnsRecord = ndr_unpack(dnsp.DnssrvRpcRecord, value)
>    File "/usr/lib64/python2.7/site-packages/samba/ndr.py", line 45,
> in ndr_unpack
>      object.__ndr_unpack__(data, allow_remaining=allow_remaining)
> A transaction is still active in ldb context [0x1953490] on 
> tdb:///var/lib/samba/private/sam.ldb
> 
> The pippin server still shows up in the Domain controllers list and
> site list. Is there 
> anything I can do to complete the removal?
> 
> The samba version is 4.4.4:

This is fixed in all Samba 4.5 releases and Samba 4.4.6.

Thanks!

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