Univention Bugzilla – Bug 36794
Can't contact LDAP server (appcenter ldap.SERVER_DOWN)
Last modified: 2015-05-28 16:49:46 CEST
Instead of a traceback a user friendly message could be shown. Die Ausführung des Kommandos appcenter/query ist fehlgeschlagen: Traceback (most recent call last): File "/usr/lib/pymodules/python2.7/univention/management/console/modules/__init__.py", line 176, in _decorated return function(self, request, *args, **kwargs) File "/usr/lib/pymodules/python2.7/univention/management/console/modules/decorators.py", line 316, in _response result = _multi_response(self, request) File "/usr/lib/pymodules/python2.7/univention/management/console/modules/decorators.py", line 460, in _response return list(function(self, iterator, *nones)) File "/usr/lib/pymodules/python2.7/univention/management/console/modules/decorators.py", line 282, in _fake_func yield function(self, *args) File "/usr/lib/pymodules/python2.7/univention/management/console/modules/appcenter/__init__.py", line 111, in query props = application.to_dict(self.package_manager, domainwide_managed, hosts) File "/usr/lib/pymodules/python2.7/univention/management/console/modules/appcenter/app_center.py", line 918, in to_dict ldap_object = self.get_ldap_object() File "/usr/lib/pymodules/python2.7/univention/management/console/modules/appcenter/app_center.py", line 1260, in get_ldap_object lo, pos = admin_uldap.getMachineConnection() File "/usr/lib/pymodules/python2.7/univention/admin/uldap.py", line 75, in getMachineConnection lo=univention.uldap.getMachineConnection(start_tls, decode_ignorelist=decode_ignorelist, ldap_master=ldap_master) File "/usr/lib/pymodules/python2.7/univention/uldap.py", line 101, in getMachineConnection lo=access(host=ucr['ldap/master'], port=port, base=ucr['ldap/base'], binddn=ucr['ldap/hostdn'], bindpw=bindpw, start_tls=start_tls, decode_ignorelist=decode_ignorelist) File "/usr/lib/pymodules/python2.7/univention/uldap.py", line 177, in __init__ self.__open(ca_certfile) File "/usr/lib/pymodules/python2.7/univention/uldap.py", line 215, in __open self.lo.start_tls_s() File "/usr/lib/python2.7/dist-packages/ldap/ldapobject.py", line 884, in start_tls_s res = self._apply_method_s(SimpleLDAPObject.start_tls_s,*args,**kwargs) File "/usr/lib/python2.7/dist-packages/ldap/ldapobject.py", line 865, in _apply_method_s self.reconnect(self._uri,retry_max=self._retry_max,retry_delay=self._retry_delay) File "/usr/lib/python2.7/dist-packages/ldap/ldapobject.py", line 839, in reconnect raise e SERVER_DOWN: {'desc': "Can't contact LDAP server"}
We could move error handling of ldap exceptions into the UMC module error handling so that the SERVER_DOWN message from UDM is shown for every module (UVMM, AppCenter, UDM, ...).
Another one reported by 4.0-0 errata10 (Walle): Die Ausführung des Kommandos apps/get ist fehlgeschlagen: Traceback (most recent call last): File "/usr/lib/pymodules/python2.7/univention/management/console/modules/__init__.py", line 176, in _decorated return function(self, request, *args, **kwargs) File "/usr/lib/pymodules/python2.7/univention/management/console/modules/decorators.py", line 316, in _response result = _multi_response(self, request) File "/usr/lib/pymodules/python2.7/univention/management/console/modules/decorators.py", line 460, in _response return list(function(self, iterator, *nones)) File "/usr/lib/pymodules/python2.7/univention/management/console/modules/decorators.py", line 282, in _fake_func yield function(self, *args) File "/usr/lib/pymodules/python2.7/univention/management/console/modules/apps/__init__.py", line 76, in get return application.to_dict(self.package_manager) File "/usr/lib/pymodules/python2.7/univention/management/console/modules/appcenter/app_center.py", line 917, in to_dict ldap_object = self.get_ldap_object() File "/usr/lib/pymodules/python2.7/univention/management/console/modules/appcenter/app_center.py", line 1259, in get_ldap_object lo, pos = admin_uldap.getMachineConnection() File "/usr/lib/pymodules/python2.7/univention/admin/uldap.py", line 75, in getMachineConnection lo=univention.uldap.getMachineConnection(start_tls, decode_ignorelist=decode_ignorelist, ldap_master=ldap_master) File "/usr/lib/pymodules/python2.7/univention/uldap.py", line 101, in getMachineConnection lo=access(host=ucr['ldap/master'], port=port, base=ucr['ldap/base'], binddn=ucr['ldap/hostdn'], bindpw=bindpw, start_tls=start_tls, decode_ignorelist=decode_ignorelist) File "/usr/lib/pymodules/python2.7/univention/uldap.py", line 177, in __init__ self.__open(ca_certfile) File "/usr/lib/pymodules/python2.7/univention/uldap.py", line 215, in __open self.lo.start_tls_s() File "/usr/lib/python2.7/dist-packages/ldap/ldapobject.py", line 884, in start_tls_s res = self._apply_method_s(SimpleLDAPObject.start_tls_s,*args,**kwargs) File "/usr/lib/python2.7/dist-packages/ldap/ldapobject.py", line 865, in _apply_method_s self.reconnect(self._uri,retry_max=self._retry_max,retry_delay=self._retry_delay) File "/usr/lib/python2.7/dist-packages/ldap/ldapobject.py", line 839, in reconnect raise e SERVER_DOWN: {'desc': "Can't contact LDAP server"}
Reported again, 4.0-0 errata17 (Walle)
Reported again, 4.0-1 errata84 (Walle)
Reported again, 4.0-1 errata152 (Walle)
Die Ausführung des Kommandos appcenter/query ist fehlgeschlagen: Traceback (most recent call last): File "%PY2.7%/univention/management/console/modules/__init__.py", line 176, in _decorated return function(self, request, *args, **kwargs) File "%PY2.7%/univention/management/console/modules/decorators.py", line 316, in _response result = _multi_response(self, request) File "%PY2.7%/univention/management/console/modules/decorators.py", line 460, in _response return list(function(self, iterator, *nones)) File "%PY2.7%/univention/management/console/modules/decorators.py", line 282, in _fake_func yield function(self, *args) File "%PY2.7%/univention/management/console/modules/appcenter/__init__.py", line 107, in query hosts = util.get_all_hosts() File "%PY2.7%/univention/management/console/modules/appcenter/util.py", line 108, in get_all_hosts lo = uldap.getMachineConnection(ldap_master=False) File "%PY2.7%/univention/uldap.py", line 110, in getMachineConnection raise ldap.SERVER_DOWN, e SERVER_DOWN: {'desc': "Can't contact LDAP server"}
ldap.SERVER_DOWN is implemented in the error_handling function of the UMC server core. It shows the message which is used in UDM, too. YAML: 2015-05-12-univention-management-console.yaml Package: univention-management-console Version: 7.1.63-17.859.201505131137 YAML: 2015-05-12-univention-management-console-module-udm.yaml Package: univention-management-console-module-udm Version: 5.1.25-66.574.201505131143 (just import the function in udm from UMC-server if possible). We can drop that block in the future completely.
Reported again, 4.0-2 errata193 (Walle)
Reported again, 4.0-2 errata194 (Walle)
(In reply to Florian Best from comment #9) > Reported again, 4.0-2 errata194 (Walle) again
Not translated. Additionally, a generic error message like should not make promises about information in log files as they may not exist. Apart from that, works fine.
(In reply to Dirk Wiesenthal from comment #11) > Not translated. yes, missed to copy the translation. Fixed now. > Additionally, a generic error message like should not make > promises about information in log files as they may not exist. Apart from > that, works fine. Yes, this was intended for other error messages. It is commented out now and will be reused in the near future. Package currently builds.
OK, works fine
<http://errata.univention.de/ucs/4.0/198.html>
<http://errata.univention.de/ucs/4.0/199.html>
<http://errata.univention.de/ucs/4.0/203.html>