Accepting request 228741 from home:cbosdonnat:branches:Virtualization

Updated to 1.2.3

OBS-URL: https://build.opensuse.org/request/show/228741
OBS-URL: https://build.opensuse.org/package/show/Virtualization/libvirt?expand=0&rev=362
This commit is contained in:
Cédric Bosdonnat 2014-04-02 12:48:46 +00:00 committed by Git OBS Bridge
parent a397ef8391
commit 36ec00cd38
12 changed files with 106 additions and 78 deletions

View File

@ -1,7 +1,7 @@
Index: libvirt-1.2.2/tests/vircgrouptest.c
Index: libvirt-1.2.3/tests/vircgrouptest.c
===================================================================
--- libvirt-1.2.2.orig/tests/vircgrouptest.c
+++ libvirt-1.2.2/tests/vircgrouptest.c
--- libvirt-1.2.3.orig/tests/vircgrouptest.c
+++ libvirt-1.2.3/tests/vircgrouptest.c
@@ -33,7 +33,6 @@
# include "virlog.h"
# include "virfile.h"
@ -10,7 +10,7 @@ Index: libvirt-1.2.2/tests/vircgrouptest.c
# define VIR_FROM_THIS VIR_FROM_NONE
@@ -531,68 +530,6 @@ static int testCgroupAvailable(const voi
@@ -533,68 +532,6 @@ static int testCgroupAvailable(const voi
return 0;
}
@ -71,7 +71,7 @@ Index: libvirt-1.2.2/tests/vircgrouptest.c
-
- ret = 0;
-
-cleanup:
- cleanup:
- virCgroupFree(&cgroup);
- return ret;
-}
@ -79,7 +79,7 @@ Index: libvirt-1.2.2/tests/vircgrouptest.c
static int testCgroupGetMemoryUsage(const void *args ATTRIBUTE_UNUSED)
{
virCgroupPtr cgroup = NULL;
@@ -798,9 +735,6 @@ mymain(void)
@@ -800,9 +737,6 @@ mymain(void)
if (virtTestRun("virCgroupGetMemoryUsage works", testCgroupGetMemoryUsage, NULL) < 0)
ret = -1;

View File

@ -1,19 +1,13 @@
Index: libvirt-1.2.2/examples/apparmor/Makefile.am
Index: libvirt-1.2.3/examples/apparmor/Makefile.am
===================================================================
--- libvirt-1.2.2.orig/examples/apparmor/Makefile.am
+++ libvirt-1.2.2/examples/apparmor/Makefile.am
@@ -14,13 +14,25 @@
## License along with this library. If not, see
## <http://www.gnu.org/licenses/>.
-EXTRA_DIST= \
- TEMPLATE \
- libvirt-qemu \
--- libvirt-1.2.3.orig/examples/apparmor/Makefile.am
+++ libvirt-1.2.3/examples/apparmor/Makefile.am
@@ -18,10 +18,22 @@ EXTRA_DIST= \
TEMPLATE \
libvirt-qemu \
libvirt-lxc \
- usr.lib.libvirt.virt-aa-helper \
- usr.sbin.libvirtd
+EXTRA_DIST= \
+ TEMPLATE \
+ libvirt-qemu \
+ usr.lib.libvirt.virt-aa-helper.in \
+ usr.sbin.libvirtd.in
@ -33,10 +27,10 @@ Index: libvirt-1.2.2/examples/apparmor/Makefile.am
apparmordir = $(sysconfdir)/apparmor.d/
apparmor_DATA = \
usr.lib.libvirt.virt-aa-helper \
Index: libvirt-1.2.2/examples/apparmor/usr.lib.libvirt.virt-aa-helper.in
Index: libvirt-1.2.3/examples/apparmor/usr.lib.libvirt.virt-aa-helper.in
===================================================================
--- /dev/null
+++ libvirt-1.2.2/examples/apparmor/usr.lib.libvirt.virt-aa-helper.in
+++ libvirt-1.2.3/examples/apparmor/usr.lib.libvirt.virt-aa-helper.in
@@ -0,0 +1,48 @@
+# Last Modified: Mon Apr 5 15:10:27 2010
+#include <tunables/global>
@ -86,11 +80,11 @@ Index: libvirt-1.2.2/examples/apparmor/usr.lib.libvirt.virt-aa-helper.in
+ /**.[iI][sS][oO] r,
+ /**/disk{,.*} r,
+}
Index: libvirt-1.2.2/examples/apparmor/usr.sbin.libvirtd.in
Index: libvirt-1.2.3/examples/apparmor/usr.sbin.libvirtd.in
===================================================================
--- /dev/null
+++ libvirt-1.2.2/examples/apparmor/usr.sbin.libvirtd.in
@@ -0,0 +1,66 @@
+++ libvirt-1.2.3/examples/apparmor/usr.sbin.libvirtd.in
@@ -0,0 +1,67 @@
+# Last Modified: Mon Apr 5 15:03:58 2010
+#include <tunables/global>
+@{LIBVIRT}="libvirt"
@ -106,7 +100,6 @@ Index: libvirt-1.2.2/examples/apparmor/usr.sbin.libvirtd.in
+ capability sys_admin,
+ capability sys_module,
+ capability sys_ptrace,
+ capability sys_pacct,
+ capability sys_nice,
+ capability sys_chroot,
+ capability setuid,
@ -118,7 +111,9 @@ Index: libvirt-1.2.2/examples/apparmor/usr.sbin.libvirtd.in
+ capability mknod,
+ capability fsetid,
+ capability audit_write,
+ capability ipc_lock,
+
+ # Needed for vfio
+ capability sys_resource,
+
+ network inet stream,
+ network inet dgram,
@ -157,9 +152,9 @@ Index: libvirt-1.2.2/examples/apparmor/usr.sbin.libvirtd.in
+ change_profile -> @{LIBVIRT}-[0-9a-f]*-[0-9a-f]*-[0-9a-f]*-[0-9a-f]*-[0-9a-f]*,
+
+}
Index: libvirt-1.2.2/examples/apparmor/usr.lib.libvirt.virt-aa-helper
Index: libvirt-1.2.3/examples/apparmor/usr.lib.libvirt.virt-aa-helper
===================================================================
--- libvirt-1.2.2.orig/examples/apparmor/usr.lib.libvirt.virt-aa-helper
--- libvirt-1.2.3.orig/examples/apparmor/usr.lib.libvirt.virt-aa-helper
+++ /dev/null
@@ -1,48 +0,0 @@
-# Last Modified: Mon Apr 5 15:10:27 2010
@ -210,11 +205,11 @@ Index: libvirt-1.2.2/examples/apparmor/usr.lib.libvirt.virt-aa-helper
- /**.[iI][sS][oO] r,
- /**/disk{,.*} r,
-}
Index: libvirt-1.2.2/examples/apparmor/usr.sbin.libvirtd
Index: libvirt-1.2.3/examples/apparmor/usr.sbin.libvirtd
===================================================================
--- libvirt-1.2.2.orig/examples/apparmor/usr.sbin.libvirtd
--- libvirt-1.2.3.orig/examples/apparmor/usr.sbin.libvirtd
+++ /dev/null
@@ -1,60 +0,0 @@
@@ -1,63 +0,0 @@
-# Last Modified: Mon Apr 5 15:03:58 2010
-#include <tunables/global>
-@{LIBVIRT}="libvirt"
@ -242,6 +237,9 @@ Index: libvirt-1.2.2/examples/apparmor/usr.sbin.libvirtd
- capability fsetid,
- capability audit_write,
-
- # Needed for vfio
- capability sys_resource,
-
- network inet stream,
- network inet dgram,
- network inet6 stream,

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:237074ec79c2de75c79c05dfaa074543ae5fd75261e7e1f9fc4b8a424bf96692
size 20497389

3
libvirt-1.2.3.tar.bz2 Normal file
View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:030e1da22cbdd98427de96f087e0fbea5f15a2685799af161b4001f287175973
size 20734026

View File

@ -128,7 +128,7 @@ Index: libvirt-1.2.2/src/interface/interface_backend_netcf.c
+ vp = VIR_LOG_DEBUG;
+ break;
+ }
+ virLogMessage(VIR_LOG_FROM_FILE, vp, file, line, func, 0, "%s", msg);
+ virLogMessage(&virLogSelf, vp, file, line, func, 0, "%s", msg);
+}
+#endif

View File

@ -1,3 +1,15 @@
-------------------------------------------------------------------
Wed Apr 2 12:06:04 UTC 2014 - cbosdonnat@suse.com
- Update to libvirt 1.2.3
- add new virDomainCoreDumpWithFormat API
- conf: Introduce virDomainDeviceGetInfo API
- more features and fixes on bhyve driver
- lot of cleanups and improvement on the Xen driver
- Many incremental improvements and bug fixes, see
http://libvirt.org/news.html
-------------------------------------------------------------------
Fri Mar 14 13:44:06 MDT 2014 - jfehlig@suse.com

View File

@ -235,7 +235,7 @@
Name: libvirt
Url: http://libvirt.org/
Version: 1.2.2
Version: 1.2.3
Release: 0
Summary: Library providing a simple virtualization API
License: LGPL-2.1+
@ -1319,7 +1319,8 @@ rm -rf $RPM_BUILD_ROOT
cd tests
make
# These tests don't current work in a mock build root
for i in nodeinfotest seclabeltest
# qemuargv2xmltest: needs qemu user/group to be setup
for i in nodeinfotest seclabeltest qemuxml2argvtest
do
rm -f $i
printf 'int main(void) { return 0; }' > $i.c
@ -1475,6 +1476,7 @@ fi
%config(noreplace) %{_sysconfdir}/apparmor.d/usr.sbin.libvirtd
%config(noreplace) %{_sysconfdir}/apparmor.d/usr.lib.libvirt.virt-aa-helper
%config(noreplace) %{_sysconfdir}/apparmor.d/abstractions/libvirt-qemu
%config(noreplace) %{_sysconfdir}/apparmor.d/abstractions/libvirt-lxc
%config(noreplace) %{_sysconfdir}/apparmor.d/libvirt/TEMPLATE
%{_libdir}/%{name}/virt-aa-helper
%endif

View File

@ -1,9 +1,9 @@
Adjust libvirtd sysconfig file to conform to SUSE standards
Index: libvirt-1.2.2/daemon/libvirtd.sysconf
Index: libvirt-1.2.3/daemon/libvirtd.sysconf
===================================================================
--- libvirt-1.2.2.orig/daemon/libvirtd.sysconf
+++ libvirt-1.2.2/daemon/libvirtd.sysconf
--- libvirt-1.2.3.orig/daemon/libvirtd.sysconf
+++ libvirt-1.2.3/daemon/libvirtd.sysconf
@@ -1,16 +1,25 @@
+## Path: System/Virtualization/libvirt
+
@ -34,13 +34,31 @@ Index: libvirt-1.2.2/daemon/libvirtd.sysconf
# Override the QEMU/SDL default audio driver probing when
# starting virtual machines using SDL graphics
#
@@ -20,5 +29,7 @@
@@ -20,14 +29,16 @@
#
#SDL_AUDIODRIVER=pulse
-# Override the maximum number of opened files
-# Override the maximum number of opened files.
-# This only works with traditional init scripts.
-# In the systemd world, the limit can only be changed by overriding
-# LimitNOFILE for libvirtd.service. To do that, just create a *.conf
-# file in /etc/systemd/system/libvirtd.service.d/ (for example
-# /etc/systemd/system/libvirtd.service.d/openfiles.conf) and write
-# the following two lines in it:
-# [Service]
-# LimitNOFILE=2048
-#
-#LIBVIRTD_NOFILES_LIMIT=2048
+## Type: integer
+## Default: 2048
+## Override the maximum number of opened files
+## Override the maximum number of opened files.
+## This only works with traditional init scripts.
+## In the systemd world, the limit can only be changed by overriding
+## LimitNOFILE for libvirtd.service. To do that, just create a *.conf
+## file in /etc/systemd/system/libvirtd.service.d/ (for example
+## /etc/systemd/system/libvirtd.service.d/openfiles.conf) and write
+## the following two lines in it:
+## [Service]
+## LimitNOFILE=2048
+##
+LIBVIRTD_NOFILES_LIMIT=2048

View File

@ -1,8 +1,8 @@
Index: libvirt-1.2.2/src/libxl/libxl_conf.c
Index: libvirt-1.2.3/src/libxl/libxl_conf.c
===================================================================
--- libvirt-1.2.2.orig/src/libxl/libxl_conf.c
+++ libvirt-1.2.2/src/libxl/libxl_conf.c
@@ -565,6 +565,30 @@ libxlMakeChrdevStr(virDomainChrDefPtr de
--- libvirt-1.2.3.orig/src/libxl/libxl_conf.c
+++ libvirt-1.2.3/src/libxl/libxl_conf.c
@@ -567,6 +567,30 @@ libxlMakeChrdevStr(virDomainChrDefPtr de
}
static int
@ -33,8 +33,8 @@ Index: libvirt-1.2.2/src/libxl/libxl_conf.c
libxlMakeDomBuildInfo(virDomainObjPtr vm, libxl_domain_config *d_config)
{
virDomainDefPtr def = vm->def;
@@ -1195,6 +1219,9 @@ libxlBuildDomainConfig(libxlDriverPrivat
if (libxlMakeVfbList(driver, def, d_config) < 0)
@@ -1322,6 +1346,9 @@ libxlBuildDomainConfig(libxlDriverPrivat
if (libxlMakePciList(def, d_config) < 0)
return -1;
+ if (libxlFixupDomBuildInfo(def, d_config) < 0)

View File

@ -1,7 +1,7 @@
Index: libvirt-1.2.2/src/qemu/qemu.conf
Index: libvirt-1.2.3/src/qemu/qemu.conf
===================================================================
--- libvirt-1.2.2.orig/src/qemu/qemu.conf
+++ libvirt-1.2.2/src/qemu/qemu.conf
--- libvirt-1.2.3.orig/src/qemu/qemu.conf
+++ libvirt-1.2.3/src/qemu/qemu.conf
@@ -200,7 +200,16 @@
# a special value; security_driver can be set to that value in
# isolation, but it cannot appear in a list of drivers.
@ -19,13 +19,15 @@ Index: libvirt-1.2.2/src/qemu/qemu.conf
# If set to non-zero, then the default security labeling
# will make guests confined. If set to zero, then guests
@@ -402,10 +411,25 @@
@@ -402,11 +411,22 @@
#allow_disk_format_probing = 1
-# To enable 'Sanlock' project based locking of the file
-# content (to prevent two VMs writing to the same
-# disk), uncomment this
-# In order to prevent accidentally starting two domains that
-# share one writable disk, libvirt offers two approaches for
-# locking files. The first one is sanlock, the other one,
-# virtlockd, is then our own implementation. Accepted values
-# are "sanlock" and "lockd".
+# SUSE note:
+# Two lock managers are supported: lockd and sanlock. lockd, which
+# is provided by the virtlockd service, uses advisory locks (flock(2))
@ -40,11 +42,8 @@ Index: libvirt-1.2.2/src/qemu/qemu.conf
+# has the disadvantage of not being able to be restarted without
+# first terminating all virtual machines for which it holds leases.
+#
+# To enable lockd or sanlock based protection of virtual machine disk
+# content (to prevent two VMs writing to the same disk), uncomment one
+# of the following
+# Specify lockd or sanlock to enable protection of virtual machine disk
+# content.
#
+#lock_manager = "lockd"
#lock_manager = "sanlock"
#lock_manager = "lockd"

View File

@ -1,11 +1,11 @@
Index: libvirt-1.2.2/daemon/libvirtd.service.in
Index: libvirt-1.2.3/daemon/libvirtd.service.in
===================================================================
--- libvirt-1.2.2.orig/daemon/libvirtd.service.in
+++ libvirt-1.2.2/daemon/libvirtd.service.in
@@ -9,6 +9,8 @@ Before=libvirt-guests.service
After=network.target
--- libvirt-1.2.3.orig/daemon/libvirtd.service.in
+++ libvirt-1.2.3/daemon/libvirtd.service.in
@@ -10,6 +10,8 @@ After=network.target
After=dbus.service
After=iscsid.service
After=apparmor.service
+Wants=xencommons.service
+After=xencommons.service
Documentation=man:libvirtd(8)

View File

@ -14,11 +14,11 @@
is inactive. We obviously can't search xenstore when the domain is
inactive.
Index: libvirt-1.2.2/src/xen/xend_internal.c
Index: libvirt-1.2.3/src/xen/xend_internal.c
===================================================================
--- libvirt-1.2.2.orig/src/xen/xend_internal.c
+++ libvirt-1.2.2/src/xen/xend_internal.c
@@ -70,7 +70,7 @@
--- libvirt-1.2.3.orig/src/xen/xend_internal.c
+++ libvirt-1.2.3/src/xen/xend_internal.c
@@ -72,7 +72,7 @@ VIR_LOG_INIT("xen.xend_internal");
#define XEND_RCV_BUF_MAX_LEN (256 * 1024)
static int
@ -27,7 +27,7 @@ Index: libvirt-1.2.2/src/xen/xend_internal.c
virDomainDeviceDefPtr dev, char *class,
char *ref, int ref_len);
@@ -3326,18 +3326,18 @@ xenDaemonDomainBlockPeek(virConnectPtr c
@@ -3328,37 +3328,35 @@ xenDaemonDomainBlockPeek(virConnectPtr c
* Returns 0 in case of success, -1 in case of failure.
*/
static int
@ -43,14 +43,13 @@ Index: libvirt-1.2.2/src/xen/xend_internal.c
- char *xref;
- char *tmp;
+ unsigned int i;
const char *driver = virDomainDiskGetDriver(dev->data.disk);
if (dev->type == VIR_DOMAIN_DEVICE_DISK) {
+ if (dev->data.disk->dst == NULL)
+ return -1;
if (dev->data.disk->driverName &&
STREQ(dev->data.disk->driverName, "tap"))
strcpy(class, "tap");
@@ -3347,19 +3347,17 @@ virDomainXMLDevID(virConnectPtr conn,
if (STREQ_NULLABLE(driver, "tap") || STREQ_NULLABLE(driver, "tap2"))
strcpy(class, driver);
else
strcpy(class, "vbd");
@ -81,7 +80,7 @@ Index: libvirt-1.2.2/src/xen/xend_internal.c
} else if (dev->type == VIR_DOMAIN_DEVICE_NET) {
char mac[VIR_MAC_STRING_BUFLEN];
virDomainNetDefPtr netdef = dev->data.net;
@@ -3367,16 +3365,22 @@ virDomainXMLDevID(virConnectPtr conn,
@@ -3366,16 +3364,22 @@ virDomainXMLDevID(virConnectPtr conn,
strcpy(class, "vif");
@ -114,7 +113,7 @@ Index: libvirt-1.2.2/src/xen/xend_internal.c
} else if (dev->type == VIR_DOMAIN_DEVICE_HOSTDEV &&
dev->data.hostdev->mode == VIR_DOMAIN_HOSTDEV_MODE_SUBSYS &&
dev->data.hostdev->source.subsys.type == VIR_DOMAIN_HOSTDEV_SUBSYS_TYPE_PCI) {
@@ -3392,17 +3396,44 @@ virDomainXMLDevID(virConnectPtr conn,
@@ -3391,17 +3395,44 @@ virDomainXMLDevID(virConnectPtr conn,
strcpy(class, "pci");