Ldapsync python error (server pro 8.0.11)

Hi,

we have a seafile server pro 8.0.11 on centos 8 running with LDAP Sync with the python LDAP package. I have only just noticed that the synchonization has been failing for some time.

./pro/pro.py ldapsync
Exception in thread Thread-1:
Traceback (most recent call last):
  File "/usr/lib64/python3.6/threading.py", line 919, in _bootstrap_inner
    self.run()
  File "/opt/seafile/seafile-pro-server-8.0.11/pro/python/seafevents/ldap_syncer/ldap_sync.py", line 56, in run
    migrate_dn_pairs(settings=self.settings)
  File "/opt/seafile/seafile-pro-server-8.0.11/pro/python/seafevents/ldap_syncer/ldap_sync.py", line 45, in migrate_dn_pairs
    uuid = results[0][1][config.group_uuid_attr][0]
KeyError: 'objectGUID'

Exception in thread Thread-2:
Traceback (most recent call last):
  File "/usr/lib64/python3.6/threading.py", line 919, in _bootstrap_inner
    self.run()
  File "/opt/seafile/seafile-pro-server-8.0.11/pro/python/seafevents/ldap_syncer/ldap_sync.py", line 56, in run
    migrate_dn_pairs(settings=self.settings)
  File "/opt/seafile/seafile-pro-server-8.0.11/pro/python/seafevents/ldap_syncer/ldap_sync.py", line 45, in migrate_dn_pairs
    uuid = results[0][1][config.group_uuid_attr][0]
KeyError: 'objectGUID'

ldapsearch is OK
Anyone an idea how to solve this?

Please check this manual (GROUP_UUID_ATTR part): Importing Groups from LDAP - Seafile Admin Manual

  • GROUP_UUID_ATTR: Since Seafile pro 8.0, UUID is used to identify groups in LDAP/AD servers. Before that, group DN is used. So when a group changes name, the old group will be deleted and a new group will be created. This is not a desirable behavior. With the new mechanism, the rename can be detected and the groups in Seafile remains intact. The default attribute is “ObjectGUID”, which is available in AD. For other LDAP servers, please refer to https://ldapwiki.com/wiki/Universally%20Unique%20Identifier .

Oups … Thx, now it’s ok … sorry :disappointed_relieved: