Change in vdsm[master]: Skip hosted engine stats processing when it is not configured
msivak at redhat.com
msivak at redhat.com
Tue Aug 4 14:13:59 UTC 2015
Martin Sivák has uploaded a new change for review.
Change subject: Skip hosted engine stats processing when it is not configured
......................................................................
Skip hosted engine stats processing when it is not configured
This changes the data collecting to ignore hosted engine when
the host id is reported as None or 0.
Change-Id: I7b49fa02ae8035c1eb98582299260a59d3bba0e0
Bug-Url: https://bugzilla.redhat.com/show_bug.cgi?id=1248539
Signed-off-by: Martin Sivak <msivak at redhat.com>
---
M vdsm.spec.in
M vdsm/API.py
M vdsm/logger.conf.in
3 files changed, 13 insertions(+), 3 deletions(-)
git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/54/44354/1
diff --git a/vdsm.spec.in b/vdsm.spec.in
index fd21bc1..a3de25c 100644
--- a/vdsm.spec.in
+++ b/vdsm.spec.in
@@ -188,7 +188,7 @@
Requires: fence-agents-all
Requires: kernel >= 3.15.0
# Subprocess and thread bug was found on python 2.7.2
-Requires: python >= 2.7.3
+Requires: python >= 2.7.3t
Requires: initscripts >= 9.42.2-1
Requires: device-mapper-multipath >= 0.4.9-56
Requires: e2fsprogs >= 1.41.14
diff --git a/vdsm/API.py b/vdsm/API.py
index 664ad05..8661db7 100644
--- a/vdsm/API.py
+++ b/vdsm/API.py
@@ -1801,8 +1801,12 @@
try:
instance = haClient.HAClient()
host_id = instance.get_local_host_id()
+
# If a host id is available, consider HA configured
- i['configured'] = True
+ if host_id:
+ i['configured'] = True
+ else:
+ return i
stats = instance.get_all_stats()
if 0 in stats:
diff --git a/vdsm/logger.conf.in b/vdsm/logger.conf.in
index 617c175..e2b1763 100644
--- a/vdsm/logger.conf.in
+++ b/vdsm/logger.conf.in
@@ -1,5 +1,5 @@
[loggers]
-keys=root,vds,Storage,virt,ovirt_hosted_engine_ha,IOProcess,connectivity
+keys=root,vds,Storage,virt,ovirt_hosted_engine_ha,ovirt_hosted_engine_ha_config,IOProcess,connectivity
[handlers]
keys=console,syslog,logfile,connlogfile
@@ -30,6 +30,12 @@
qualname=ovirt_hosted_engine_ha
propagate=1
+[logger_ovirt_hosted_engine_ha_config]
+level=ERROR
+handlers=
+qualname=ovirt_hosted_engine_ha.config
+propagate=0
+
[logger_IOProcess]
level=INFO
handlers=logfile
--
To view, visit https://gerrit.ovirt.org/44354
To unsubscribe, visit https://gerrit.ovirt.org/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I7b49fa02ae8035c1eb98582299260a59d3bba0e0
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Martin Sivák <msivak at redhat.com>
More information about the vdsm-patches
mailing list