Not able to get anything through autobuild at the moment - visualize_drs.python3 error.
Alexander Bokovoy
ab at samba.org
Fri Sep 7 13:16:26 UTC 2018
On to, 06 syys 2018, Jeremy Allison via samba-technical wrote:
> I'm trying to push the (unrelated) printing
> fixes and continually get:
>
> ----------------------------------------------------------------
> [36(315)/36 at 9m1s] samba.tests.samba_tool.visualize_drs.python3(promoted_dc)
> Attempting to contact ldap://localdc.samba.example.com (CN=LOCALDC,CN=Servers,CN=Default-First-Site-Name,CN=Sites,CN=Configuration,DC=samba,DC=example,DC=com)
> found extra DSAs:
> CN=RODC,CN=Servers,CN=Default-First-Site-Name,CN=Sites,CN=Configuration,DC=samba,DC=example,DC=com
> missing DSAs (known locally, not by CN=LOCALDC,CN=Servers,CN=Default-First-Site-Name,CN=Sites,CN=Configuration,DC=samba,DC=example,DC=com):
> Attempting to contact ldap://localvampiredc.samba.example.com (CN=LOCALVAMPIREDC,CN=Servers,CN=Default-First-Site-Name,CN=Sites,CN=Configuration,DC=samba,DC=example,DC=com)
> found extra DSAs:
> CN=RODC,CN=Servers,CN=Default-First-Site-Name,CN=Sites,CN=Configuration,DC=samba,DC=example,DC=com
> missing DSAs (known locally, not by CN=LOCALVAMPIREDC,CN=Servers,CN=Default-First-Site-Name,CN=Sites,CN=Configuration,DC=samba,DC=example,DC=com):
> Attempting to contact ldap://promotedvdc.samba.example.com (CN=PROMOTEDVDC,CN=Servers,CN=Default-First-Site-Name,CN=Sites,CN=Configuration,DC=samba,DC=example,DC=com)
> UNEXPECTED(failure): samba.tests.samba_tool.visualize_drs.python3.samba.tests.samba_tool.visualize_drs.SambaToolVisualizeDrsTest.test_reps_remote(promoted_dc)
> REASON: Exception: Exception: Traceback (most recent call last):
> File "/memdisk/jra/a/b43732/samba-py3/bin/python/samba/tests/samba_tool/visualize_drs.py", line 466, in test_reps_remote
> self.assertCmdSuccess(result, out, err)
> File "/memdisk/jra/a/b43732/samba-py3/bin/python/samba/tests/samba_tool/base.py", line 109, in assertCmdSuccess
> exit, out, err, msg))
> AssertionError: -1 is not None : exit[-1] stdout[] stderr[ERROR(<class 'KeyError'>): uncaught exception - '6eec1bda-5ce1-4c06-b747-fab80d6377ab'
> File "/memdisk/jra/a/b43732/samba-py3/bin/python/samba/netcmd/__init__.py", line 183, in _run
> return self.run(*args, **kwargs)
> File "/memdisk/jra/a/b43732/samba-py3/bin/python/samba/netcmd/visualize.py", line 339, in run
> (guid_to_dnstr[str(r.source_dsa_obj_guid)],
> ]:
>
> FAILED (1 failures, 0 errors and 0 unexpected successes in 0 testsuites)
> ----------------------------------------------------------------
>
> Which certainly seems unrelated to any change I'm making.
>
The actual issue is within the exception printout here:
AssertionError: -1 is not None : exit[-1] stdout[] stderr[ERROR(<class 'KeyError'>): uncaught exception - '6eec1bda-5ce1-4c06-b747-fab80d6377ab'
File "/memdisk/jra/a/b43732/samba-py3/bin/python/samba/netcmd/__init__.py", line 183, in _run
return self.run(*args, **kwargs)
File "/memdisk/jra/a/b43732/samba-py3/bin/python/samba/netcmd/visualize.py", line 339, in run
(guid_to_dnstr[str(r.source_dsa_obj_guid)],
]:
this is a part within cmd_reps.run():
guid_to_dnstr = {}
.......
# the remote, because after kcc.run (or kcc.list_dsas) the kcc
# ends up in a messy state.
for dsa_dn in dsas:
......
for remote_dn in dsas_from_here:
if mode == 'others' and remote_dn == dsa_dn:
continue
elif mode == 'self' and remote_dn != dsa_dn:
continue
remote_dsa = kcc.get_dsa('CN=NTDS Settings,' + remote_dn)
kcc.translate_ntdsconn(remote_dsa)
guid_to_dnstr[str(remote_dsa.dsa_guid)] = remote_dn
.......
for partname, part in nc_reps.items():
for state, edgelists in all_edges.items():
for dsa_dn, rep in part[state]:
short_name = long_partitions.get(partname, partname)
for r in rep.rep_repsFrom:
edgelists['from'].append(
(dsa_dn,
guid_to_dnstr[str(r.source_dsa_obj_guid)],
short_name))
for r in rep.rep_repsTo:
edgelists['to'].append(
(guid_to_dnstr[str(r.source_dsa_obj_guid)],
dsa_dn,
short_name))
so r.source_dsa_obj_guid ('6eec1bda-5ce1-4c06-b747-fab80d6377ab') does
not exist in guid_to_dnstr[] dictionary. A missing rep_repsTo edge means
we have broken topology but I have no idea what we should do here --
skip an edge or report an error.
Douglas, do you have any suggestion?
--
/ Alexander Bokovoy
More information about the samba-technical
mailing list