Page MenuHomePhabricator

check_systemd_state fails unexpectedly when run with Python 3
Closed, ResolvedPublic

Description

@jcrespo reported failure on check_systemd_state after it being moved to python3

Followup to: Iff63b9122c1d97d11500b6a360d0f6b151ea4b14 / b31b13b

I got the following error message on systemd icinga check:

"CRITICAL - b'degraded': unexpected"

It is apparently failing on all boxes that use it.

Event Timeline

To be specific, not as much "fails unexpectedly", it actually does the right thing (alerts when systemd is degraded and only then) but for the wrong reasons (detecting b'degraded' as an unrecognized state, rather than declaring 'degraded' as a bad state).

Change 630891 had a related patch set uploaded (by CRusnov; owner: CRusnov):
[operations/puppet@production] base/check_systemd_state.py: Fix encoding issue

https://gerrit.wikimedia.org/r/630891

Change 630891 merged by CRusnov:
[operations/puppet@production] base/check_systemd_state.py: Fix encoding issue

https://gerrit.wikimedia.org/r/630891