From: Björn Baumbach Date: Tue, 28 May 2019 12:52:36 +0000 (+0200) Subject: samba-tool: add 'import samba.drs_utils' to fsmo.py X-Git-Tag: ldb-2.0.5~559 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=320a5c5425e6ced18b1a9bf19b4f361ee16821ed;p=thirdparty%2Fsamba.git samba-tool: add 'import samba.drs_utils' to fsmo.py On some systems we're seeing this: ERROR(): uncaught exception - 'module' object has no attribute 'drs_utils' File "/usr/lib/python2.7/dist-packages/samba/netcmd/__init__.py", line 185, in _run return self.run(*args, **kwargs) File "/usr/lib/python2.7/dist-packages/samba/netcmd/fsmo.py", line 533, in run transfer_dns_role(self.outf, sambaopts, credopts, role, samdb) File "/usr/lib/python2.7/dist-packages/samba/netcmd/fsmo.py", line 136, in transfer_dns_role except samba.drs_utils.drsException as e: E.g. it happens on debian stretch (9.9) with python 2.7.13 (on 4.10.4) While it doesn't happen on ubuntu 18.04 with python 2.7.15rc1 or with python 3.6.7. There were also some reports on the mailing lists, see: https://lists.samba.org/archive/samba-technical/2019-May/133624.html BUG: https://bugzilla.samba.org/show_bug.cgi?id=13973 Pair-Programmed-With: Stefan Metzmacher Signed-off-by: Björn Baumbach Signed-off-by: Stefan Metzmacher Reviewed-by: Andrew Bartlett Autobuild-User(master): Andrew Bartlett Autobuild-Date(master): Thu May 30 08:27:24 UTC 2019 on sn-devel-184 --- diff --git a/python/samba/netcmd/fsmo.py b/python/samba/netcmd/fsmo.py index 4061bad4322..643d0aec1b6 100644 --- a/python/samba/netcmd/fsmo.py +++ b/python/samba/netcmd/fsmo.py @@ -23,6 +23,7 @@ import ldb from ldb import LdbError from samba.dcerpc import drsuapi, misc from samba.auth import system_session +import samba.drs_utils from samba.netcmd import ( Command, CommandError,