wir haben den opsidirectoryconnector erworben und versuchen uns an der Inbetriebnahme. Lt. Beschreibung des Connectors kann das nicht so schwierig sein, aber es funktioniert natürlich nicht.... Wir haben die version 31.1 aus dem Stable verwendet - der Server hat 4.1.1.8 - und ein Windows AD. Die --checks sind fehlerfrei, nur ein Warning zum opsi-Zertifikat.
Die Config sieht so aus:
Code: Alles auswählen
{
"directory": {
"address": "ldap://x.x.x.x",
"user": "XXX\\Benutzer",
"password": "***********",
"passwordFile": "",
"search_base": "DC=xxx,DC=xxxxxxx,DC=xx",
"search_query_computers": "(objectClass=computer)",
"identifying_attribute": "distinguishedName",
"connection_options": {
"start_tls": false,
"paged_search_limit": 768
}
},
"behaviour": {
"group_handling": "distinguishedName",
"write_changes_to_opsi": true,
"root_dir_in_opsi": "clientdirectory",
"update_existing_clients": false,
"prefer_location_from_directory": true
},
"mapping": {
"client": {
"id": "name",
"description": "description",
"notes": "",
"hardwareAddress": "",
"ipAddress": "",
"inventoryNumber": "",
"oneTimePassword": ""
}
},
"opsi": {
"address": "https://x.x.x.x:4447",
"username": "user",
"password": "********",
"passwordFile": "",
"exit_on_error": false,
"connection_options": {
"verify_certificate": false
}
}
Code: Alles auswählen
[DEBUG] [2021-02-10 08:30:16,014] LDAP search query: '(objectClass=computer)'
[WARNING] [2021-02-10 08:30:16,015] No value given for opsi client attribute 'oneTimePassword'
[WARNING] [2021-02-10 08:30:16,016] No value given for opsi client attribute 'hardwareAddress'
[WARNING] [2021-02-10 08:30:16,016] No value given for opsi client attribute 'notes'
[WARNING] [2021-02-10 08:30:16,017] No value given for opsi client attribute 'ipAddress'
[WARNING] [2021-02-10 08:30:16,018] No value given for opsi client attribute 'inventoryNumber'
[DEBUG] [2021-02-10 08:30:16,018] Adding 'distinguishedName' as identifying attribute
[DEBUG] [2021-02-10 08:30:16,018] Querying for the following attributes: cn, objectClass, objectCategory, distinguishedName, description, name
[DEBUG] [2021-02-10 08:30:16,019] Searching for elements in directory with paged search...
[INFO] [2021-02-10 08:30:16,019] Connected to directory
[DEBUG] [2021-02-10 08:30:16,701] Found element: {'uri': ["b'ldap://DomainDnsZones.xxx.xxxxx.xx/DC=DomainDnsZones,DC=xxx,DC=xxxxx,DC=xx'"], 'type': 'searchResRef'}
[DEBUG] [2021-02-10 08:30:16,701] yielding element: {'uri': ["b'ldap://DomainDnsZones.xxx.xxxxx.xx/DC=DomainDnsZones,DC=xxx,DC=xxxxx,DC=xx'"], 'type': 'searchResRef'}
[DEBUG] [2021-02-10 08:30:16,701] Next element: {'uri': ["b'ldap://DomainDnsZones.xxx.xxxxx.xx/DC=DomainDnsZones,DC=xxx,DC=xxxxx,DC=xx'"], 'type': 'searchResRef'}
[DEBUG] [2021-02-10 08:30:16,701] Failed to get identifying name from {'uri': ["b'ldap://DomainDnsZones.xxx.xxxxx.xx/DC=DomainDnsZones,DC=xxx,DC=xxxxx,DC=xx'"], 'type': 'searchResRef'} (via attribute 'dn'): KeyError('dn',)
[CRITICAL] [2021-02-10 08:30:16,701] Unable to get the identifying name for the current element!
Traceback (most recent call last):
File "/usr/bin/opsidirectoryconnector", line 6, in <module>
runConnector()
File "/usr/lib/python3/dist-packages/opsidirectoryconnector/cli.py", line 103, in runConnector
updateOpsi(opsiSession, actions, writeChanges=writeChanges, exitOnError=exitOnError)
File "/usr/lib/python3/dist-packages/opsidirectoryconnector/opsi.py", line 114, in updateOpsi
for actionCounter, action in enumerate(processableActions, start=1):
File "/usr/lib/python3/dist-packages/opsidirectoryconnector/opsi.py", line 111, in <genexpr>
processableActions = (action for action in actions if action is not None)
File "/usr/lib/python3/dist-packages/opsidirectoryconnector/connector.py", line 43, in convertComputers
dn = getDNFromElement(element, identifyingAttribute)
File "/usr/lib/python3/dist-packages/opsidirectoryconnector/connector.py", line 80, in getDNFromElement
raise kerr
File "/usr/lib/python3/dist-packages/opsidirectoryconnector/connector.py", line 76, in getDNFromElement
return element[identifyingAttribute]
KeyError: 'dn'
vielen Dank im Voraus
vG RG