Univention Bugzilla – Bug 43229
confusing warning message in connector.log
Last modified: 2017-02-01 12:07:21 CET
Our customer got strange warning messages in his connector.log which are confusing and questions the function. ------------------------------------------------------------------------------------------------------------------ connector.log: [...] 19.12.2016 09:52:24,19 MAIN (------ ): DEBUG_INIT 19.12.2016 09:52:24,60 LDAP (ERROR ): Failed to lookup AD LDAP base, using UCR value. 19.12.2016 09:52:25,424 LDAP (PROCESS): Using UNIV as AD Netbios domain name 19.12.2016 09:53:01,622 LDAP (PROCESS): sync to ucs: [windowscomputer] [ modify] cn=fnb68112,ou=notebooks,ou=mein,o=sunshinead,c=ad 19.12.2016 09:53:01,647 LDAP (WARNING): __set_values: no ucs_attribute found in <univention.connector.attribute instance at 0x2d66a28> 19.12.2016 09:53:43,969 MAIN (------ ): DEBUG_INIT 19.12.2016 09:53:44,15 LDAP (ERROR ): Failed to lookup AD LDAP base, using UCR value. 19.12.2016 09:53:45,336 LDAP (PROCESS): Using UNIV as AD Netbios domain name 19.12.2016 09:54:27,941 LDAP (PROCESS): sync to ucs: [windowscomputer] [ modify] cn=fpc60023,ou=computers,ou=dein,o=sunshinead,c=ad 19.12.2016 09:54:27,964 LDAP (WARNING): __set_values: no ucs_attribute found in <univention.connector.attribute instance at 0x2d66a28> 19.12.2016 09:54:33,975 MAIN (------ ): DEBUG_INIT 19.12.2016 09:54:34,5 LDAP (ERROR ): Failed to lookup AD LDAP base, using UCR value. 19.12.2016 09:54:35,91 LDAP (PROCESS): Using UNIV as AD Netbios domain name 19.12.2016 09:54:52,196 MAIN (------ ): DEBUG_INIT 19.12.2016 09:54:52,220 LDAP (ERROR ): Failed to lookup AD LDAP base, using UCR value. 19.12.2016 09:54:53,33 LDAP (PROCESS): Using UNIV as AD Netbios domain name 19.12.2016 09:55:26,673 MAIN (------ ): DEBUG_INIT 19.12.2016 09:55:26,711 LDAP (ERROR ): Failed to lookup AD LDAP base, using UCR value. 19.12.2016 09:55:27,691 LDAP (PROCESS): Using UNIV as AD Netbios domain name 19.12.2016 09:56:31,791 MAIN (------ ): DEBUG_INIT 19.12.2016 09:56:31,812 LDAP (ERROR ): Failed to lookup AD LDAP base, using UCR value. 19.12.2016 09:56:32,840 LDAP (PROCESS): Using UNIV as AD Netbios domain name 19.12.2016 09:56:49,395 LDAP (PROCESS): sync to ucs: [windowscomputer] [ modify] cn=num090,ou=notebooks,ou=mein,o=sunshinead,c=ad 19.12.2016 09:56:49,418 LDAP (WARNING): __set_values: no ucs_attribute found in <univention.connector.attribute instance at 0x2d66a28> 19.12.2016 09:59:49,859 MAIN (------ ): DEBUG_INIT 19.12.2016 09:59:49,888 LDAP (ERROR ): Failed to lookup AD LDAP base, using UCR value. 19.12.2016 09:59:51,33 LDAP (PROCESS): Using UNIV as AD Netbios domain name 19.12.2016 10:00:32,121 LDAP (PROCESS): sync to ucs: [windowscomputer] [ modify] cn=ucsmis1,cn=memberserver,cn=computers,o=sunshinead,c=ad 19.12.2016 10:00:32,153 LDAP (WARNING): __set_values: no ucs_attribute found in <univention.connector.attribute instance at 0x2d66a28> ------------------------------------------------------------------------------------------------------ For this message i already found this Bug 40816 with a workaround (ERROR ): Failed to lookup AD LDAP base, using UCR value. But the message (WARNING): __set_values: no ucs_attribute found in <univention.connector.attribute instance at 0x2d66a28> is not reported by now I found in /etc/univention/connector/ad/mapping in line 393 a function, which afaik controls the windowscomputer mapping and in line 422 where the attributes are defined I found 'samAccountName' without ucs_attribute defined. ------------------------------------------------------------------------------------------------------- [...] 'samAccountName': univention.connector.attribute ( ldap_attribute='uid', con_attribute='sAMAccountName', compare_function=univention.connector.compare_lowercase, ), [...] ------------------------------------------------------------------------------------------------------- IMHO the missing definition of ucs_attribute causes the warning message. We should at least define the attribute to get rid of the warning message?
ucs_attribute in samAccountName mapping does not work as we don't have a UDM attribute for the uid (this is handled in the cn mapping). Actually, the samAccountName mapping is only needed for the "ad to ucs" sync (write mode), because Computer name change in AD modifies the cn, cn is mapped to udm:name and udm:name modifies cn and uid. Computer name change in UCS modifies cn and uid, cn is mapped to cn, and uid to samAccountName (now in write mode) Added sync_mode='write' to windowscomputer.samAccountName mapping attribute. YAML: univention-ad-connector.yaml merged to 4.2
Jenkins tests: OK Changelog: OK (r76241) UCS 4.2 merge: OK Code review: OK Tests: OK, it works now.
<http://errata.software-univention.de/ucs/4.1/386.html>