From 092541b7fb973f767f7c39f36e79b90b70da1ce5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B6rn=20Busse?= Date: Thu, 4 Mar 2021 22:28:07 +0100 Subject: [PATCH] Decode line in stderr cmd output --- hbase-exporter | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/hbase-exporter b/hbase-exporter index 82418d7..0035c33 100755 --- a/hbase-exporter +++ b/hbase-exporter @@ -170,13 +170,13 @@ class zk(): logging.info("zk: server %s: %s", address, mode) num_active_servers += 1 - if match.group(1) == "leader": + if match.group(1) == "leader" or match.group(1) == "standalone": zk_has_leader = 1 zk_leader_address = address prom_zookeeper_has_leader.set(zk_has_leader) for line in error: - logging.info(line) + logging.info(line.decode('utf-8')) prom_zookeeper_num_live.set(num_active_servers) logging.info("zk: %d active ZooKeeper servers", num_active_servers)