client/tools/rhn-virtualization/rhn-virtualization.spec | 6 +++
client/tools/rhn-virtualization/virtualization/support.py | 23 +++++++++-----
rel-eng/packages/rhn-virtualization | 2 -
3 files changed, 21 insertions(+), 10 deletions(-)
New commits:
commit ffe0bf7382a99497ea721c6f9e4891737d7394bb
Author: Stephen Herr <sherr(a)redhat.com>
Date: Thu Feb 7 15:04:26 2013 -0500
Automatic commit of package [rhn-virtualization] release [5.4.44-1].
diff --git a/client/tools/rhn-virtualization/rhn-virtualization.spec
b/client/tools/rhn-virtualization/rhn-virtualization.spec
index 5e96f15..3f43502 100644
--- a/client/tools/rhn-virtualization/rhn-virtualization.spec
+++ b/client/tools/rhn-virtualization/rhn-virtualization.spec
@@ -10,7 +10,7 @@ License: GPLv2
URL:
https://fedorahosted.org/spacewalk
Source0:
https://fedorahosted.org/releases/s/p/spacewalk/%{name}-%{version}.tar.gz
-Version: 5.4.43
+Version: 5.4.44
Release: 1%{?dist}
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildArch: noarch
@@ -151,6 +151,10 @@ fi
%doc LICENSE
%changelog
+* Thu Feb 07 2013 Stephen Herr <sherr(a)redhat.com> 5.4.44-1
+- 908899 - rhn-virtualization-host needs to consistantly use the new function
+ definition
+
* Wed Feb 06 2013 Jan Pazdziora 5.4.43-1
- support studio KVM image type
diff --git a/rel-eng/packages/rhn-virtualization b/rel-eng/packages/rhn-virtualization
index 9ac60af..870f4cb 100644
--- a/rel-eng/packages/rhn-virtualization
+++ b/rel-eng/packages/rhn-virtualization
@@ -1 +1 @@
-5.4.43-1 client/tools/rhn-virtualization/
+5.4.44-1 client/tools/rhn-virtualization/
commit 5f8c84dcff4c4d942c9e52485e8821b166c1771a
Author: Stephen Herr <sherr(a)redhat.com>
Date: Thu Feb 7 15:02:57 2013 -0500
908899 - rhn-virtualization-host needs to consistantly use the new function
definition
diff --git a/client/tools/rhn-virtualization/virtualization/support.py
b/client/tools/rhn-virtualization/virtualization/support.py
index b6748bf..9f162a4 100755
--- a/client/tools/rhn-virtualization/virtualization/support.py
+++ b/client/tools/rhn-virtualization/virtualization/support.py
@@ -7,10 +7,10 @@
# FOR A PARTICULAR PURPOSE. You should have received a copy of GPLv2
# along with this software; if not, see
#
http://www.gnu.org/licenses/old-licenses/gpl-2.0.txt.
-#
+#
# Red Hat trademarks are not licensed under GPLv2. No permission is
# granted to use or replicate Red Hat trademarks that are incorporated
-# in this software or its documentation.
+# in this software or its documentation.
#
import sys
@@ -49,6 +49,12 @@ def _check_status(daemon):
return True
vdsm_enabled = _check_status("vdsmd")
+# override vdsm_enabled if we can't read information from it
+try:
+ from virtualization import localvdsm
+except ImportError:
+ vdsm_enabled = False
+
###############################################################################
# Public Interface
@@ -72,14 +78,15 @@ def refresh(fail_on_error=False):
# First, declare our own existence.
plan.add(
- EventType.EXISTS,
- TargetType.SYSTEM,
+ EventType.EXISTS,
+ TargetType.SYSTEM,
{ PropertyType.IDENTITY : domain_identity,
PropertyType.UUID : my_uuid })
# Now, crawl each of the domains on this host.
if vdsm_enabled:
- domains = poller.poll_through_vdsm()
+ server = localvdsm.connect()
+ domains = poller.poll_through_vdsm(server)
else:
domains = poller.poll_hypervisor()
@@ -172,13 +179,13 @@ def schedulePoller(minute, hour, dom, month, dow):
def _is_host_domain(fail_on_error=False):
"""
- This function returns true if this system is currently a host domain.
+ This function returns true if this system is currently a host domain.
Simply having virtualization enabled is sufficient.
We can figure out if Xen/Qemu is running by checking for the type
"""
if vdsm_enabled:
- # since vdsm is enabled, lets move further and
+ # since vdsm is enabled, lets move further and
# see what we get
return True
if not libvirt:
@@ -197,7 +204,7 @@ def _is_host_domain(fail_on_error=False):
def _fetch_host_uuid():
"""
- This function returns the UUID of the host system. This will always be
+ This function returns the UUID of the host system. This will always be
16 zeros.
"""
return '0000000000000000'