@Best I have just upgraded to 5.0.2 and am seeing the same behavior as mschlee:
(3221356597, 'The operation cannot be performed.')
Traceback (most recent call last):
File "/usr/share/univention-monitoring-client/scripts//check_univention_samba_drs_failures", line 78, in write_metrics
consecutive_sync_failures = _CheckSambaDrsRepl().check()
File "/usr/share/univention-monitoring-client/scripts//check_univention_samba_drs_failures", line 59, in check
(info_type, info) = self.drsuapi.DsReplicaGetInfo(self.drsuapi_handle, 1, req1)
samba.NTSTATUSError: (3221356597, 'The operation cannot be performed.')
These emails come every five minutes.
The temporary fixed I used was slightly different as is looks like the update changed check_univention_samba_drs_failures
I commented out the try/except block beginning on line 77:
class CheckSambaDrsRepl(Alert):
def write_metrics(self):
# return OK, if samba autostart is false
if not ucr.is_true('samba4/autostart', False):
self.write_metric('univention_samba_drs_failures', 0)
self.log.debug('samba4/autostart is not true')
return
try:
consecutive_sync_failures = _CheckSambaDrsRepl().check()
except (CommandError, RuntimeError) as exc:
self.write_metric('univention_samba_drs_failures', -1)
# self.log.exception(str(exc))
return
msg = None
for server, failures in consecutive_sync_failures.items():
text = '%s failures on %s' % (failures, server)
msg = msg + ', ' + text if msg else text
self.write_metric('univention_samba_drs_failures', sum(consecutive_sync_failures.values()))
self.log.debug(msg or 'no drs failures')
As mschlee said,
This is probably not the desired solution. Any thoughts ?