diff --git a/management/univention-management-console/debian/control b/management/univention-management-console/debian/control index 885255b..fe408a1 100644 --- a/management/univention-management-console/debian/control +++ b/management/univention-management-console/debian/control @@ -77,6 +77,7 @@ Depends: ${misc:Depends}, ${python:Depends}, univention-join, python-univention, python-openssl, + python-faulthandler, python-pam, python-polib, python-notifier (>= 0.9.5-1) diff --git a/management/univention-management-console/src/univention/management/console/log.py b/management/univention-management-console/src/univention/management/console/log.py index 840afe4..785202a 100644 --- a/management/univention-management-console/src/univention/management/console/log.py +++ b/management/univention-management-console/src/univention/management/console/log.py @@ -38,6 +38,7 @@ """ import univention.debug as ud +import faulthandler import logging import grp import os @@ -70,6 +71,8 @@ def log_init(filename, log_level=2): if filename[0] != '/': filename = '/var/log/univention/%s.log' % filename fd = ud.init(filename, ud.FLUSH, ud.NO_FUNCTION) + faulthandler.disable() + faulthandler.enable(fd) adm = grp.getgrnam('adm') os.chown(filename, 0, adm.gr_gid) os.chmod(filename, 0o640) @@ -93,7 +96,9 @@ def log_reopen(): """Reopenes the logfile and reset the current loglevel""" if not _debug_ready: return - ud.reopen() + fd = ud.reopen() + faulthandler.disable() + faulthandler.enable(fd) _reset_debug_loglevel() log_set_level(_debug_loglevel)