Hello community,
here is the log from the commit of package vhostmd for openSUSE:Factory checked in at 2014-06-16 21:36:10
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/vhostmd (Old)
and /work/SRC/openSUSE:Factory/.vhostmd.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "vhostmd"
Changes:
--------
--- /work/SRC/openSUSE:Factory/vhostmd/vhostmd.changes 2013-12-19 12:38:12.000000000 +0100
+++ /work/SRC/openSUSE:Factory/.vhostmd.new/vhostmd.changes 2014-06-16 21:36:11.000000000 +0200
@@ -1,0 +2,21 @@
+Fri Jun 13 19:34:33 UTC 2014 - mlatimer@suse.com
+
+- Further updates to vmhostd.xml
+ - Support both xen and non-xen hypervisors (kvm)
+ - Document reserved characters in 'action' field
+ - Revert xen_version back to major/minor/extra to maintain compatability
+ with xend
+ - Minor syntax and legibility cleanup
+ vhostmd-conf.patch
+ bnc#872736
+
+-------------------------------------------------------------------
+Wed Jun 11 23:02:06 UTC 2014 - mlatimer@suse.com
+
+- Various updates to vmhostd.xml
+ - Replace xm commands with xl commands
+ - Add /sbin and /bin to <path>
+ - Use xen_version for VirtualizationProductInfo
+ vhostmd-conf.patch
+
+-------------------------------------------------------------------
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ vhostmd.spec ++++++
--- /var/tmp/diff_new_pack.gvhJwN/_old 2014-06-16 21:36:12.000000000 +0200
+++ /var/tmp/diff_new_pack.gvhJwN/_new 2014-06-16 21:36:12.000000000 +0200
@@ -1,7 +1,7 @@
#
# spec file for package vhostmd
#
-# Copyright (c) 2013 SUSE LINUX Products GmbH, Nuernberg, Germany.
+# Copyright (c) 2014 SUSE LINUX Products GmbH, Nuernberg, Germany.
# Copyright (c) 2010 Novell Inc.
#
# All modifications and additions to the file contributed by third parties
@@ -17,6 +17,7 @@
#
+
Name: vhostmd
ExclusiveArch: %ix86 x86_64
BuildRequires: libtool
++++++ vhostmd-conf.patch ++++++
--- /var/tmp/diff_new_pack.gvhJwN/_old 2014-06-16 21:36:12.000000000 +0200
+++ /var/tmp/diff_new_pack.gvhJwN/_new 2014-06-16 21:36:12.000000000 +0200
@@ -2,26 +2,167 @@
===================================================================
--- vhostmd-0.4.orig/vhostmd.xml
+++ vhostmd-0.4/vhostmd.xml
-@@ -30,7 +30,6 @@ within the vm element.
+@@ -3,7 +3,7 @@
+
+ <!--
+
+-Copyright (C) 2008 Novell, Inc.
++Copyright (C) 2014 SUSE, Inc.
+
+ Configuration file for virtual host metrics daemon (vhostmd).
+
+@@ -18,6 +18,12 @@ A metric's value is set to the output pr
+ the vm currently under inspection is substituted for NAME. Only useful
+ within the vm element.
+
++NOTE - 'action' must be a valid shell builtin, script or external
++command found in the path specified by the global <path> element.
++When chaining commands, '&', '<' and '>' are reserved characters,
++therefore '&', '<' and '>' must be used instead. For example,
++the logical && operator must be replaced with "&&".
++
+ -->
+
+ <vhostmd>
+@@ -28,52 +34,74 @@ within the vm element.
+ <size unit="k">256</size>
+ </disk>
5
- <path>/usr/bin:/usr/sbin:/usr/share/vhostmd/scripts</path>
+- <path>/usr/bin:/usr/sbin:/usr/share/vhostmd/scripts</path>
++ <path>/usr/sbin:/sbin:/usr/bin:/bin:/usr/share/vhostmd/scripts</path>
<transport>vbd</transport>
- <!-- <transport>xenstore</transport> -->
</globals>
<metrics>
<metric type="string" context="host">
-@@ -84,12 +83,12 @@ within the vm element.
+ <name>HostName</name>
+- <action>virsh CONNECT hostname | tr -d '[:space:]'</action>
++ <action>
++ virsh CONNECT hostname | tr -d '[:space:]'
++ </action>
+ </metric>
+ <metric type="string" context="host">
+ <name>VirtualizationVendor</name>
+- <action>/bin/rpm -q --info xen | grep Vendor: | \
+- awk '{print substr($0, index($0,$5)) }'</action>
++ <action>
++ [ -f /proc/xen/privcmd ] && RPM="xen" || RPM="libvirt"; \
++ rpm -q --queryformat "%{VENDOR}\n" $RPM | sort -u | sed -e 's/<.*//' -e 's/ *$//'
++ </action>
+ </metric>
+ <metric type="string" context="host">
+ <name>VirtualizationProductInfo</name>
+- <action>xm info | gawk '/^xen_(major|minor|extra)/ {print $3}' | \
+- tr -d . | tr '[:space:]' .</action>
++ <action>
++ [ -f /proc/xen/privcmd ] && xl info | \
++ awk '/^xen_(major|minor|extra)/ {print $3}' | sed -e 'N;s/\n/./' -e 'N;s/\n//' || \
++ rpm -q --queryformat "%{VERSION}-%{RELEASE}\n" libvirt | sort -u
++ </action>
+ </metric>
+ <metric type="uint32" context="host">
+ <name>TotalPhyCPUs</name>
+- <action>xm info | gawk '/^nr_cpus/ {print $3}'</action>
++ <action>
++ virsh nodeinfo | awk '/^CPU\(s\)/ {print $2}'
++ </action>
+ </metric>
+ <metric type="uint32" context="host">
+ <name>NumCPUs</name>
+- <action>xm info | gawk '/^nr_cpus/ {print $3}'</action>
++ <action>
++ virsh nodeinfo | awk '/^CPU\(s\)/ {print $2}'
++ </action>
+ </metric>
+ <metric type="uint64" context="host">
+ <name>TotalPhyMem</name>
+- <action>xm info | gawk '/^total_memory/ {print $3}'</action>
++ <action>
++ echo $((`virsh nodeinfo | awk '/^Memory/ {print $3}'` / 1024))
++ </action>
+ </metric>
+ <metric type="uint64" context="host">
+ <name>UsedMem</name>
+- <action>echo "$((`xentop -b -i 1 | gawk '/Domain-0/ {print $5}'` / 1024))"</action>
++ <action>
++ [ -f /proc/xen/privcmd ] && echo "$((`xentop -b -i 1 | awk '/Domain-0/ {print $5}'` / 1024))" || \
++ free | egrep -i '^[[:space:]]*(.*buffers/cache:)' | awk '{ printf "%d\n", $3/1024; }'
++ </action>
+ </metric>
+ <metric type="uint64" context="host">
+ <name>FreeMem</name>
+- <action>xm info | gawk '/^max_free_memory/ {print $3}'</action>
++ <action>
++ [ -f /proc/xen/privcmd ] && xl info | awk '/^free_memory/ {print $3}' || \
++ free | egrep -i '^[[:space:]]*(.*buffers/cache:)' | awk '{ printf "%d\n", $4/1024; }'
++ </action>
+ </metric>
+ <metric type="uint64" context="host">
+ <name>PagedInMemory</name>
+- <action>echo "$((`vmstat -s | gawk '/pages paged in/ {print $1}'` / 1024))"</action>
++ <action>
++ vmstat -s | awk '/pages paged in/ {printf "%d\n", $1 / 1024 * $(getconf PAGESIZE) / 1024;}'
++ </action>
+ </metric>
+ <metric type="uint64" context="host">
+ <name>PagedOutMemory</name>
+- <action>echo "$((`vmstat -s | gawk '/pages paged out/ {print $1}'` / 1024))"</action>
++ <action>
++ vmstat -s | awk '/pages paged out/ {printf "%d\n", $1 / 1024 * $(getconf PAGESIZE) / 1024;}'
++ </action>
+ </metric>
+ <metric type="group" context="host">
+ <name>PageRates</name>
+@@ -83,13 +111,48 @@ within the vm element.
+ </metric>
<metric type="real64" context="host">
<name>TotalCPUTime</name>
- <action>virsh CONNECT dominfo 0 | sed 's/: */:/' | \
+- <action>virsh CONNECT dominfo 0 | sed 's/: */:/' | \
- gawk -F: '/CPU time/ {print $2;}'</action>
-+ gawk -F: '/CPU time/ {print $2;}' | sed 's/s//'</action>
++ <action>
++ [ -f /proc/xen/privcmd ] && xl list | awk '/^Domain-0/ {print $6}' || \
++ awk '
++ function user_hz( hz)
++ {
++ cmd = "getconf CLK_TCK";
++ cmd | getline;
++ hz = $1;
++ close(cmd);
++
++ return hz;
++ }
++
++ BEGIN {
++ USER_HZ = user_hz();
++ TotalCPUTime = 0;
++
++ while ( 0 < ( getline < "/proc/stat" ) )
++ {
++ if ( "cpu" == $1 )
++ {
++ TotalCPUTime = $2 + $3 + $4;
++
++ break;
++ }
++ }
++ close("/proc/stat");
++
++ #printf "USER_HZ = %d\n", USER_HZ | "cat 1>&2";
++ TotalCPUTime /= USER_HZ;
++ printf "%f\n", TotalCPUTime;
++
++ #close("cat 1>&2");
++ }'
++ </action>
</metric>
<metric type="real64" context="vm">
<name>TotalCPUTime</name>
- <action>virsh CONNECT dominfo NAME | sed 's/: */:/' | \
+- <action>virsh CONNECT dominfo NAME | sed 's/: */:/' | \
- gawk -F: '/CPU time/ {print $2;}'</action>
-+ gawk -F: '/CPU time/ {print $2;}' | sed 's/s//'</action>
++ <action>
++ virsh CONNECT dominfo NAME | sed 's/: */:/' | \
++ awk -F: '/CPU time/ {print $2;}' | sed 's/s//'
++ </action>
</metric>
</metrics>
</vhostmd>
--
To unsubscribe, e-mail: opensuse-commit+unsubscribe@opensuse.org
For additional commands, e-mail: opensuse-commit+help@opensuse.org