diff --git a/add-nocow-to-vol-xml.patch b/add-nocow-to-vol-xml.patch index c8ffd62..40f5adb 100644 --- a/add-nocow-to-vol-xml.patch +++ b/add-nocow-to-vol-xml.patch @@ -8,10 +8,10 @@ Date: Wed May 7 12:45:40 2014 +0800 Signed-off-by: Chunyan Liu -Index: libvirt-1.2.5/docs/schemas/storagevol.rng +Index: libvirt-1.2.6/docs/schemas/storagevol.rng =================================================================== ---- libvirt-1.2.5.orig/docs/schemas/storagevol.rng -+++ libvirt-1.2.5/docs/schemas/storagevol.rng +--- libvirt-1.2.6.orig/docs/schemas/storagevol.rng ++++ libvirt-1.2.6/docs/schemas/storagevol.rng @@ -138,6 +138,11 @@ @@ -24,11 +24,11 @@ Index: libvirt-1.2.5/docs/schemas/storagevol.rng -Index: libvirt-1.2.5/src/conf/storage_conf.c +Index: libvirt-1.2.6/src/conf/storage_conf.c =================================================================== ---- libvirt-1.2.5.orig/src/conf/storage_conf.c -+++ libvirt-1.2.5/src/conf/storage_conf.c -@@ -1395,6 +1395,9 @@ virStorageVolDefParseXML(virStoragePoolD +--- libvirt-1.2.6.orig/src/conf/storage_conf.c ++++ libvirt-1.2.6/src/conf/storage_conf.c +@@ -1397,6 +1397,9 @@ virStorageVolDefParseXML(virStoragePoolD virStringFreeList(version); } @@ -38,10 +38,10 @@ Index: libvirt-1.2.5/src/conf/storage_conf.c if (options->featureFromString && virXPathNode("./target/features", ctxt)) { if ((n = virXPathNodeSet("./target/features/*", ctxt, &nodes)) < 0) goto error; -Index: libvirt-1.2.5/src/storage/storage_backend.c +Index: libvirt-1.2.6/src/storage/storage_backend.c =================================================================== ---- libvirt-1.2.5.orig/src/storage/storage_backend.c -+++ libvirt-1.2.5/src/storage/storage_backend.c +--- libvirt-1.2.6.orig/src/storage/storage_backend.c ++++ libvirt-1.2.6/src/storage/storage_backend.c @@ -37,6 +37,9 @@ #ifdef __linux__ # include @@ -99,10 +99,10 @@ Index: libvirt-1.2.5/src/storage/storage_backend.c vol->target.features) < 0) { virCommandFree(cmd); return NULL; -Index: libvirt-1.2.5/src/util/virstoragefile.h +Index: libvirt-1.2.6/src/util/virstoragefile.h =================================================================== ---- libvirt-1.2.5.orig/src/util/virstoragefile.h -+++ libvirt-1.2.5/src/util/virstoragefile.h +--- libvirt-1.2.6.orig/src/util/virstoragefile.h ++++ libvirt-1.2.6/src/util/virstoragefile.h @@ -232,6 +232,7 @@ struct _virStorageSource { * pool-specific enum for storage volumes */ virBitmapPtr features; diff --git a/disable-virCgroupGetPercpuStats-test.patch b/disable-virCgroupGetPercpuStats-test.patch index 399616e..3ca99d8 100644 --- a/disable-virCgroupGetPercpuStats-test.patch +++ b/disable-virCgroupGetPercpuStats-test.patch @@ -1,7 +1,7 @@ -Index: libvirt-1.2.5/tests/vircgrouptest.c +Index: libvirt-1.2.6/tests/vircgrouptest.c =================================================================== ---- libvirt-1.2.5.orig/tests/vircgrouptest.c -+++ libvirt-1.2.5/tests/vircgrouptest.c +--- libvirt-1.2.6.orig/tests/vircgrouptest.c ++++ libvirt-1.2.6/tests/vircgrouptest.c @@ -33,7 +33,6 @@ # include "virlog.h" # include "virfile.h" diff --git a/fix-pci-attach-xen-driver.patch b/fix-pci-attach-xen-driver.patch index 5d0146a..dd96ee8 100644 --- a/fix-pci-attach-xen-driver.patch +++ b/fix-pci-attach-xen-driver.patch @@ -8,11 +8,11 @@ uses the 'device_configure' RPC. This patch changes the xend driver to always call 'device_configure' for PCI devices to be consistent with the usage in the xen tools. -Index: libvirt-1.2.5/src/xen/xend_internal.c +Index: libvirt-1.2.6/src/xen/xend_internal.c =================================================================== ---- libvirt-1.2.5.orig/src/xen/xend_internal.c -+++ libvirt-1.2.5/src/xen/xend_internal.c -@@ -2219,6 +2219,7 @@ xenDaemonAttachDeviceFlags(virConnectPtr +--- libvirt-1.2.6.orig/src/xen/xend_internal.c ++++ libvirt-1.2.6/src/xen/xend_internal.c +@@ -2222,6 +2222,7 @@ xenDaemonAttachDeviceFlags(virConnectPtr virBuffer buf = VIR_BUFFER_INITIALIZER; char class[8], ref[80]; char *target = NULL; @@ -20,7 +20,7 @@ Index: libvirt-1.2.5/src/xen/xend_internal.c virCheckFlags(VIR_DOMAIN_AFFECT_LIVE | VIR_DOMAIN_AFFECT_CONFIG, -1); -@@ -2317,8 +2318,18 @@ xenDaemonAttachDeviceFlags(virConnectPtr +@@ -2320,8 +2321,18 @@ xenDaemonAttachDeviceFlags(virConnectPtr } sexpr = virBufferContentAndReset(&buf); diff --git a/ia64-clone.patch b/ia64-clone.patch deleted file mode 100644 index d103da5..0000000 --- a/ia64-clone.patch +++ /dev/null @@ -1,66 +0,0 @@ -Index: libvirt-1.2.5/src/lxc/lxc_container.c -=================================================================== ---- libvirt-1.2.5.orig/src/lxc/lxc_container.c -+++ libvirt-1.2.5/src/lxc/lxc_container.c -@@ -164,12 +164,19 @@ int lxcContainerHasReboot(void) - VIR_FREE(buf); - cmd = v ? LINUX_REBOOT_CMD_CAD_ON : LINUX_REBOOT_CMD_CAD_OFF; - -+#ifdef __ia64__ -+ stacksize *= 2; -+#endif - if (VIR_ALLOC_N(stack, stacksize) < 0) - return -1; - - childStack = stack + stacksize; - -+#ifdef __ia64__ -+ cpid = __clone2(lxcContainerRebootChild, childStack, stacksize, flags, &cmd); -+#else - cpid = clone(lxcContainerRebootChild, childStack, flags, &cmd); -+#endif - VIR_FREE(stack); - if (cpid < 0) { - virReportSystemError(errno, "%s", -@@ -2007,6 +2014,9 @@ int lxcContainerStart(virDomainDefPtr de - .handshakefd = handshakefd - }; - -+#ifdef __ia64__ -+ stacksize *= 2; -+#endif - /* allocate a stack for the container */ - if (VIR_ALLOC_N(stack, stacksize) < 0) - return -1; -@@ -2032,7 +2042,11 @@ int lxcContainerStart(virDomainDefPtr de - cflags |= CLONE_NEWNET; - } - -+#ifdef __ia64__ -+ pid = __clone2(lxcContainerChild, stacktop, stacksize, cflags, &args); -+#else - pid = clone(lxcContainerChild, stacktop, cflags, &args); -+#endif - VIR_FREE(stack); - VIR_DEBUG("clone() completed, new container PID is %d", pid); - -@@ -2066,12 +2080,19 @@ int lxcContainerAvailable(int features) - if (features & LXC_CONTAINER_FEATURE_NET) - flags |= CLONE_NEWNET; - -+#ifdef __ia64__ -+ stacksize *= 2; -+#endif - if (VIR_ALLOC_N(stack, stacksize) < 0) - return -1; - - childStack = stack + stacksize; - -+#ifdef __ia64__ -+ cpid = __clone2(lxcContainerDummyChild, childStack, stacksize, flags, NULL); -+#else - cpid = clone(lxcContainerDummyChild, childStack, flags, NULL); -+#endif - VIR_FREE(stack); - if (cpid < 0) { - char ebuf[1024] ATTRIBUTE_UNUSED; diff --git a/install-apparmor-profiles.patch b/install-apparmor-profiles.patch index f0f2b5d..9bb3c88 100644 --- a/install-apparmor-profiles.patch +++ b/install-apparmor-profiles.patch @@ -1,7 +1,7 @@ -Index: libvirt-1.2.5/examples/apparmor/Makefile.am +Index: libvirt-1.2.6/examples/apparmor/Makefile.am =================================================================== ---- libvirt-1.2.5.orig/examples/apparmor/Makefile.am -+++ libvirt-1.2.5/examples/apparmor/Makefile.am +--- libvirt-1.2.6.orig/examples/apparmor/Makefile.am ++++ libvirt-1.2.6/examples/apparmor/Makefile.am @@ -18,10 +18,22 @@ EXTRA_DIST= \ TEMPLATE \ libvirt-qemu \ @@ -27,10 +27,10 @@ Index: libvirt-1.2.5/examples/apparmor/Makefile.am apparmordir = $(sysconfdir)/apparmor.d/ apparmor_DATA = \ usr.lib.libvirt.virt-aa-helper \ -Index: libvirt-1.2.5/examples/apparmor/usr.lib.libvirt.virt-aa-helper.in +Index: libvirt-1.2.6/examples/apparmor/usr.lib.libvirt.virt-aa-helper.in =================================================================== --- /dev/null -+++ libvirt-1.2.5/examples/apparmor/usr.lib.libvirt.virt-aa-helper.in ++++ libvirt-1.2.6/examples/apparmor/usr.lib.libvirt.virt-aa-helper.in @@ -0,0 +1,48 @@ +# Last Modified: Mon Apr 5 15:10:27 2010 +#include @@ -80,10 +80,10 @@ Index: libvirt-1.2.5/examples/apparmor/usr.lib.libvirt.virt-aa-helper.in + /**.[iI][sS][oO] r, + /**/disk{,.*} r, +} -Index: libvirt-1.2.5/examples/apparmor/usr.sbin.libvirtd.in +Index: libvirt-1.2.6/examples/apparmor/usr.sbin.libvirtd.in =================================================================== --- /dev/null -+++ libvirt-1.2.5/examples/apparmor/usr.sbin.libvirtd.in ++++ libvirt-1.2.6/examples/apparmor/usr.sbin.libvirtd.in @@ -0,0 +1,67 @@ +# Last Modified: Mon Apr 5 15:03:58 2010 +#include @@ -152,9 +152,9 @@ Index: libvirt-1.2.5/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.5/examples/apparmor/usr.lib.libvirt.virt-aa-helper +Index: libvirt-1.2.6/examples/apparmor/usr.lib.libvirt.virt-aa-helper =================================================================== ---- libvirt-1.2.5.orig/examples/apparmor/usr.lib.libvirt.virt-aa-helper +--- libvirt-1.2.6.orig/examples/apparmor/usr.lib.libvirt.virt-aa-helper +++ /dev/null @@ -1,48 +0,0 @@ -# Last Modified: Mon Apr 5 15:10:27 2010 @@ -205,9 +205,9 @@ Index: libvirt-1.2.5/examples/apparmor/usr.lib.libvirt.virt-aa-helper - /**.[iI][sS][oO] r, - /**/disk{,.*} r, -} -Index: libvirt-1.2.5/examples/apparmor/usr.sbin.libvirtd +Index: libvirt-1.2.6/examples/apparmor/usr.sbin.libvirtd =================================================================== ---- libvirt-1.2.5.orig/examples/apparmor/usr.sbin.libvirtd +--- libvirt-1.2.6.orig/examples/apparmor/usr.sbin.libvirtd +++ /dev/null @@ -1,63 +0,0 @@ -# Last Modified: Mon Apr 5 15:03:58 2010 diff --git a/libvirt-1.2.5.tar.bz2 b/libvirt-1.2.5.tar.bz2 deleted file mode 100644 index 4d946f6..0000000 --- a/libvirt-1.2.5.tar.bz2 +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:ab638db48934320857ba0693975520eb577686e655117d7a2a0f2da196f7c65b -size 20703638 diff --git a/libvirt-1.2.6.tar.bz2 b/libvirt-1.2.6.tar.bz2 new file mode 100644 index 0000000..ab64a59 --- /dev/null +++ b/libvirt-1.2.6.tar.bz2 @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:99c005cf2a22a3919c5efa9b815181e776cb214b7005c24620a8a4a76efae544 +size 21124173 diff --git a/libvirt-guests-init-script.patch b/libvirt-guests-init-script.patch index a7fc008..47e134e 100644 --- a/libvirt-guests-init-script.patch +++ b/libvirt-guests-init-script.patch @@ -1,9 +1,9 @@ Adjust libvirt-guests init files to conform to SUSE standards -Index: libvirt-1.2.5/tools/libvirt-guests.init.in +Index: libvirt-1.2.6/tools/libvirt-guests.init.in =================================================================== ---- libvirt-1.2.5.orig/tools/libvirt-guests.init.in -+++ libvirt-1.2.5/tools/libvirt-guests.init.in +--- libvirt-1.2.6.orig/tools/libvirt-guests.init.in ++++ libvirt-1.2.6/tools/libvirt-guests.init.in @@ -3,15 +3,15 @@ # the following is the LSB init header # @@ -28,10 +28,10 @@ Index: libvirt-1.2.5/tools/libvirt-guests.init.in ### END INIT INFO # the following is chkconfig init header -Index: libvirt-1.2.5/tools/libvirt-guests.sh.in +Index: libvirt-1.2.6/tools/libvirt-guests.sh.in =================================================================== ---- libvirt-1.2.5.orig/tools/libvirt-guests.sh.in -+++ libvirt-1.2.5/tools/libvirt-guests.sh.in +--- libvirt-1.2.6.orig/tools/libvirt-guests.sh.in ++++ libvirt-1.2.6/tools/libvirt-guests.sh.in @@ -16,14 +16,13 @@ # License along with this library. If not, see # . @@ -189,10 +189,10 @@ Index: libvirt-1.2.5/tools/libvirt-guests.sh.in esac -exit $RETVAL +rc_exit -Index: libvirt-1.2.5/tools/libvirt-guests.sysconf +Index: libvirt-1.2.6/tools/libvirt-guests.sysconf =================================================================== ---- libvirt-1.2.5.orig/tools/libvirt-guests.sysconf -+++ libvirt-1.2.5/tools/libvirt-guests.sysconf +--- libvirt-1.2.6.orig/tools/libvirt-guests.sysconf ++++ libvirt-1.2.6/tools/libvirt-guests.sysconf @@ -1,19 +1,29 @@ +## Path: System/Virtualization/libvirt-guests + diff --git a/libvirt-suse-netcontrol.patch b/libvirt-suse-netcontrol.patch index cf7124e..8d1c5c1 100644 --- a/libvirt-suse-netcontrol.patch +++ b/libvirt-suse-netcontrol.patch @@ -1,7 +1,7 @@ -Index: libvirt-1.2.5/configure.ac +Index: libvirt-1.2.6/configure.ac =================================================================== ---- libvirt-1.2.5.orig/configure.ac -+++ libvirt-1.2.5/configure.ac +--- libvirt-1.2.6.orig/configure.ac ++++ libvirt-1.2.6/configure.ac @@ -237,6 +237,7 @@ LIBVIRT_CHECK_FUSE LIBVIRT_CHECK_GLUSTER LIBVIRT_CHECK_HAL @@ -26,7 +26,7 @@ Index: libvirt-1.2.5/configure.ac esac if test "$with_interface" = "yes" ; then -@@ -2815,6 +2817,7 @@ LIBVIRT_RESULT_FUSE +@@ -2822,6 +2824,7 @@ LIBVIRT_RESULT_FUSE LIBVIRT_RESULT_GLUSTER LIBVIRT_RESULT_HAL LIBVIRT_RESULT_NETCF @@ -34,11 +34,11 @@ Index: libvirt-1.2.5/configure.ac LIBVIRT_RESULT_NUMACTL LIBVIRT_RESULT_OPENWSMAN LIBVIRT_RESULT_PCIACCESS -Index: libvirt-1.2.5/src/Makefile.am +Index: libvirt-1.2.6/src/Makefile.am =================================================================== ---- libvirt-1.2.5.orig/src/Makefile.am -+++ libvirt-1.2.5/src/Makefile.am -@@ -813,6 +813,10 @@ if WITH_NETCF +--- libvirt-1.2.6.orig/src/Makefile.am ++++ libvirt-1.2.6/src/Makefile.am +@@ -818,6 +818,10 @@ if WITH_NETCF INTERFACE_DRIVER_SOURCES += \ interface/interface_backend_netcf.c endif WITH_NETCF @@ -49,7 +49,7 @@ Index: libvirt-1.2.5/src/Makefile.am if WITH_UDEV INTERFACE_DRIVER_SOURCES += \ interface/interface_backend_udev.c -@@ -1403,10 +1407,15 @@ if WITH_NETCF +@@ -1414,10 +1418,15 @@ if WITH_NETCF libvirt_driver_interface_la_CFLAGS += $(NETCF_CFLAGS) libvirt_driver_interface_la_LIBADD += $(NETCF_LIBS) else ! WITH_NETCF @@ -65,11 +65,11 @@ Index: libvirt-1.2.5/src/Makefile.am endif ! WITH_NETCF if WITH_DRIVER_MODULES libvirt_driver_interface_la_LIBADD += ../gnulib/lib/libgnu.la -Index: libvirt-1.2.5/tools/virsh.c +Index: libvirt-1.2.6/tools/virsh.c =================================================================== ---- libvirt-1.2.5.orig/tools/virsh.c -+++ libvirt-1.2.5/tools/virsh.c -@@ -3252,6 +3252,8 @@ vshShowVersion(vshControl *ctl ATTRIBUTE +--- libvirt-1.2.6.orig/tools/virsh.c ++++ libvirt-1.2.6/tools/virsh.c +@@ -3320,6 +3320,8 @@ vshShowVersion(vshControl *ctl ATTRIBUTE vshPrint(ctl, " Interface"); # if defined(WITH_NETCF) vshPrint(ctl, " netcf"); @@ -78,10 +78,10 @@ Index: libvirt-1.2.5/tools/virsh.c # elif defined(WITH_UDEV) vshPrint(ctl, " udev"); # endif -Index: libvirt-1.2.5/src/interface/interface_backend_netcf.c +Index: libvirt-1.2.6/src/interface/interface_backend_netcf.c =================================================================== ---- libvirt-1.2.5.orig/src/interface/interface_backend_netcf.c -+++ libvirt-1.2.5/src/interface/interface_backend_netcf.c +--- libvirt-1.2.6.orig/src/interface/interface_backend_netcf.c ++++ libvirt-1.2.6/src/interface/interface_backend_netcf.c @@ -23,7 +23,12 @@ #include @@ -165,10 +165,10 @@ Index: libvirt-1.2.5/src/interface/interface_backend_netcf.c return 0; } -Index: libvirt-1.2.5/src/interface/interface_driver.c +Index: libvirt-1.2.6/src/interface/interface_driver.c =================================================================== ---- libvirt-1.2.5.orig/src/interface/interface_driver.c -+++ libvirt-1.2.5/src/interface/interface_driver.c +--- libvirt-1.2.6.orig/src/interface/interface_driver.c ++++ libvirt-1.2.6/src/interface/interface_driver.c @@ -30,8 +30,15 @@ interfaceRegister(void) if (netcfIfaceRegister() == 0) return 0; @@ -186,10 +186,10 @@ Index: libvirt-1.2.5/src/interface/interface_driver.c if (udevIfaceRegister() == 0) return 0; #endif /* WITH_UDEV */ -Index: libvirt-1.2.5/m4/virt-netcontrol.m4 +Index: libvirt-1.2.6/m4/virt-netcontrol.m4 =================================================================== --- /dev/null -+++ libvirt-1.2.5/m4/virt-netcontrol.m4 ++++ libvirt-1.2.6/m4/virt-netcontrol.m4 @@ -0,0 +1,35 @@ +dnl The libnetcontrol library +dnl diff --git a/libvirt.changes b/libvirt.changes index e114576..b2c6c77 100644 --- a/libvirt.changes +++ b/libvirt.changes @@ -1,3 +1,25 @@ +------------------------------------------------------------------- +Wed Jul 2 12:49:36 MDT 2014 - jfehlig@suse.com + +- Move 'Requires' of qemu from libvirt-daemon-qemu subpackage to + libvirt-daemon-driver-qemu + bnc#885267 + +------------------------------------------------------------------- +Wed Jul 2 12:42:35 MDT 2014 - jfehlig@suse.com + +- Temporarily disable virt-aa-helper-test, which fails in Factory + +------------------------------------------------------------------- +Wed Jul 2 11:31:22 MDT 2014 - jfehlig@suse.com + +- Update to libvirt 1.2.6 + - libxl: add migration support and fixes + - Many incremental improvements and bug fixes, see + http://libvirt.org/news.html + - Drop upstream patch libxl-migration-support.patch + - Drop ia64-clone.patch since libvirt is not built for IA64 + ------------------------------------------------------------------- Wed Jun 25 13:42:00 UTC 2014 - cbosdonnat@suse.com diff --git a/libvirt.spec b/libvirt.spec index 10b6e32..2e8ffed 100644 --- a/libvirt.spec +++ b/libvirt.spec @@ -235,7 +235,7 @@ Name: libvirt Url: http://libvirt.org/ -Version: 1.2.5 +Version: 1.2.6 Release: 0 Summary: Library providing a simple virtualization API License: LGPL-2.1+ @@ -430,14 +430,12 @@ Source99: baselibs.conf # Upstream patches # Need to go upstream Patch100: xen-name-for-devid.patch -Patch101: ia64-clone.patch -Patch102: xen-pv-cdrom.patch -Patch103: add-nocow-to-vol-xml.patch +Patch101: xen-pv-cdrom.patch +Patch102: add-nocow-to-vol-xml.patch # pending review upstream patches -Patch150: libxl-migration-support.patch -Patch151: lxc-keep-caps-feature.patch -Patch152: lxc-keep-caps-feature-conversion.patch -Patch153: lxc-keep-caps-feature-doc.patch +Patch150: lxc-keep-caps-feature.patch +Patch151: lxc-keep-caps-feature-conversion.patch +Patch152: lxc-keep-caps-feature-doc.patch # Our patches Patch200: libvirtd-defaults.patch Patch201: libvirtd-init-script.patch @@ -685,6 +683,7 @@ Requires: xz %if 0%{?suse_version} > 1210 Requires: lzop %endif +Requires: qemu %description daemon-driver-qemu The qemu driver plugin for the libvirtd daemon, providing @@ -775,7 +774,6 @@ Requires: libvirt-daemon-driver-qemu = %{version}-%{release} Requires: libvirt-daemon-driver-secret = %{version}-%{release} Requires: libvirt-daemon-driver-storage = %{version}-%{release} %endif -Requires: qemu %description daemon-qemu Server side daemon and driver required to manage the virtualization @@ -952,11 +950,9 @@ namespaces. %patch100 -p1 %patch101 -p1 %patch102 -p1 -%patch103 -p1 %patch150 -p1 %patch151 -p1 %patch152 -p1 -%patch153 -p1 %patch200 -p1 %patch201 -p1 %patch202 -p1 @@ -1333,6 +1329,8 @@ EXTRA="$EXTRA virnetsockettest" %ifarch aarch64 EXTRA="$EXTRA virportallocatortest" %endif +# temporarily disable failing virt-aa-helper-test +EXTRA="$EXTRA virt-aa-helper-test" for i in nodeinfotest seclabeltest $EXTRA do rm -f $i @@ -1504,6 +1502,7 @@ fi %dir %attr(0700, root, root) %{_sysconfdir}/libvirt/qemu/networks/autostart %dir %attr(0700, root, root) %{_localstatedir}/lib/libvirt/network/ %dir %attr(0755, root, root) %{_localstatedir}/lib/libvirt/dnsmasq/ +%attr(0755, root, root) %{_libdir}/%{name}/libvirt_leaseshelper %dir %{_datadir}/libvirt/networks/ %{_datadir}/libvirt/networks/default.xml %endif @@ -1579,6 +1578,7 @@ fi %dir %attr(0700, root, root) %{_sysconfdir}/libvirt/qemu/networks/autostart %dir %attr(0700, root, root) %{_localstatedir}/lib/libvirt/network/ %dir %attr(0755, root, root) %{_localstatedir}/lib/libvirt/dnsmasq/ +%attr(0755, root, root) %{_libdir}/%{name}/libvirt_leaseshelper %dir %{_libdir}/%{name}/connection-driver %{_libdir}/%{name}/connection-driver/libvirt_driver_network.so %endif @@ -1736,7 +1736,9 @@ fi %{_bindir}/virt-pki-validate %{_bindir}/virt-host-validate %dir %{_libdir}/%{name} -%{_libdir}/lib*.so.* +%{_libdir}/libvirt.so.* +%{_libdir}/libvirt-qemu.so.* +%{_libdir}/libvirt-lxc.so.* %attr(0755, root, root) %{_libdir}/%{name}/libvirt-guests.sh %{_localstatedir}/adm/fillup-templates/sysconfig.libvirt-guests %if %{with_systemd} @@ -1772,9 +1774,17 @@ fi %files devel %defattr(-, root, root) +%{_libdir}/libvirt.so +%{_libdir}/libvirt-qemu.so +%{_libdir}/libvirt-lxc.so %{_includedir}/libvirt -%{_libdir}/*.so +%{_includedir}/libvirt/virterror.h +%{_includedir}/libvirt/libvirt.h +%{_includedir}/libvirt/libvirt-qemu.h +%{_includedir}/libvirt/libvirt-lxc.h %{_libdir}/pkgconfig/libvirt.pc +%{_libdir}/pkgconfig/libvirt-qemu.pc +%{_libdir}/pkgconfig/libvirt-lxc.pc %dir %{_datadir}/libvirt/api/ %{_datadir}/libvirt/api/libvirt-api.xml %{_datadir}/libvirt/api/libvirt-qemu-api.xml diff --git a/libvirtd-defaults.patch b/libvirtd-defaults.patch index de420da..e145973 100644 --- a/libvirtd-defaults.patch +++ b/libvirtd-defaults.patch @@ -1,7 +1,7 @@ -Index: libvirt-1.2.5/daemon/libvirtd.conf +Index: libvirt-1.2.6/daemon/libvirtd.conf =================================================================== ---- libvirt-1.2.5.orig/daemon/libvirtd.conf -+++ libvirt-1.2.5/daemon/libvirtd.conf +--- libvirt-1.2.6.orig/daemon/libvirtd.conf ++++ libvirt-1.2.6/daemon/libvirtd.conf @@ -18,8 +18,8 @@ # It is necessary to setup a CA and issue server certificates before # using this capability. @@ -13,10 +13,10 @@ Index: libvirt-1.2.5/daemon/libvirtd.conf # Listen for unencrypted TCP connections on the public TCP/IP port. # NB, must pass the --listen flag to the libvirtd process for this to -Index: libvirt-1.2.5/daemon/libvirtd-config.c +Index: libvirt-1.2.6/daemon/libvirtd-config.c =================================================================== ---- libvirt-1.2.5.orig/daemon/libvirtd-config.c -+++ libvirt-1.2.5/daemon/libvirtd-config.c +--- libvirt-1.2.6.orig/daemon/libvirtd-config.c ++++ libvirt-1.2.6/daemon/libvirtd-config.c @@ -229,7 +229,7 @@ daemonConfigNew(bool privileged ATTRIBUT if (VIR_ALLOC(data) < 0) return NULL; @@ -26,10 +26,10 @@ Index: libvirt-1.2.5/daemon/libvirtd-config.c data->listen_tcp = 0; if (VIR_STRDUP(data->tls_port, LIBVIRTD_TLS_PORT) < 0 || -Index: libvirt-1.2.5/daemon/test_libvirtd.aug.in +Index: libvirt-1.2.6/daemon/test_libvirtd.aug.in =================================================================== ---- libvirt-1.2.5.orig/daemon/test_libvirtd.aug.in -+++ libvirt-1.2.5/daemon/test_libvirtd.aug.in +--- libvirt-1.2.6.orig/daemon/test_libvirtd.aug.in ++++ libvirt-1.2.6/daemon/test_libvirtd.aug.in @@ -2,7 +2,7 @@ module Test_libvirtd = ::CONFIG:: diff --git a/libvirtd-init-script.patch b/libvirtd-init-script.patch index d797040..cd92c4e 100644 --- a/libvirtd-init-script.patch +++ b/libvirtd-init-script.patch @@ -1,9 +1,9 @@ Adjust libvirtd sysconfig file to conform to SUSE standards -Index: libvirt-1.2.5/daemon/libvirtd.sysconf +Index: libvirt-1.2.6/daemon/libvirtd.sysconf =================================================================== ---- libvirt-1.2.5.orig/daemon/libvirtd.sysconf -+++ libvirt-1.2.5/daemon/libvirtd.sysconf +--- libvirt-1.2.6.orig/daemon/libvirtd.sysconf ++++ libvirt-1.2.6/daemon/libvirtd.sysconf @@ -1,16 +1,25 @@ +## Path: System/Virtualization/libvirt + diff --git a/libxl-migration-support.patch b/libxl-migration-support.patch deleted file mode 100644 index 65f284c..0000000 --- a/libxl-migration-support.patch +++ /dev/null @@ -1,1028 +0,0 @@ -From 766944b3f8ea6099b847c59f4cbe4d63802a461e Mon Sep 17 00:00:00 2001 -From: Jim Fehlig -Date: Tue, 25 Feb 2014 16:59:59 -0700 -Subject: [PATCH] libxl: add migration support - -This patch adds initial migration support to the libxl driver, -using the VIR_DRV_FEATURE_MIGRATION_PARAMS family of migration -functions. - -Signed-off-by: Jim Fehlig ---- - po/POTFILES.in | 1 + - src/Makefile.am | 3 +- - src/libxl/libxl_conf.h | 6 + - src/libxl/libxl_domain.h | 1 + - src/libxl/libxl_driver.c | 235 ++++++++++++++++++ - src/libxl/libxl_migration.c | 577 ++++++++++++++++++++++++++++++++++++++++++++ - src/libxl/libxl_migration.h | 78 ++++++ - 7 files changed, 900 insertions(+), 1 deletion(-) - -Index: libvirt-1.2.5/po/POTFILES.in -=================================================================== ---- libvirt-1.2.5.orig/po/POTFILES.in -+++ libvirt-1.2.5/po/POTFILES.in -@@ -74,6 +74,7 @@ src/lxc/lxc_process.c - src/libxl/libxl_domain.c - src/libxl/libxl_driver.c - src/libxl/libxl_conf.c -+src/libxl/libxl_migration.c - src/network/bridge_driver.c - src/network/bridge_driver_linux.c - src/node_device/node_device_driver.c -Index: libvirt-1.2.5/src/Makefile.am -=================================================================== ---- libvirt-1.2.5.orig/src/Makefile.am -+++ libvirt-1.2.5/src/Makefile.am -@@ -707,7 +707,8 @@ XENAPI_DRIVER_SOURCES = \ - LIBXL_DRIVER_SOURCES = \ - libxl/libxl_conf.c libxl/libxl_conf.h \ - libxl/libxl_domain.c libxl/libxl_domain.h \ -- libxl/libxl_driver.c libxl/libxl_driver.h -+ libxl/libxl_driver.c libxl/libxl_driver.h \ -+ libxl/libxl_migration.c libxl/libxl_migration.h - - UML_DRIVER_SOURCES = \ - uml/uml_conf.c uml/uml_conf.h \ -Index: libvirt-1.2.5/src/libxl/libxl_conf.h -=================================================================== ---- libvirt-1.2.5.orig/src/libxl/libxl_conf.h -+++ libvirt-1.2.5/src/libxl/libxl_conf.h -@@ -43,6 +43,9 @@ - # define LIBXL_VNC_PORT_MIN 5900 - # define LIBXL_VNC_PORT_MAX 65535 - -+# define LIBXL_MIGRATION_PORT_MIN 49152 -+# define LIBXL_MIGRATION_PORT_MAX 49216 -+ - # define LIBXL_CONFIG_DIR SYSCONFDIR "/libvirt/libxl" - # define LIBXL_AUTOSTART_DIR LIBXL_CONFIG_DIR "/autostart" - # define LIBXL_STATE_DIR LOCALSTATEDIR "/run/libvirt/libxl" -@@ -115,6 +118,9 @@ struct _libxlDriverPrivate { - /* Immutable pointer, self-locking APIs */ - virPortAllocatorPtr reservedVNCPorts; - -+ /* Immutable pointer, self-locking APIs */ -+ virPortAllocatorPtr migrationPorts; -+ - /* Immutable pointer, lockless APIs*/ - virSysinfoDefPtr hostsysinfo; - }; -Index: libvirt-1.2.5/src/libxl/libxl_domain.h -=================================================================== ---- libvirt-1.2.5.orig/src/libxl/libxl_domain.h -+++ libvirt-1.2.5/src/libxl/libxl_domain.h -@@ -69,6 +69,7 @@ struct _libxlDomainObjPrivate { - virChrdevsPtr devs; - libxl_evgen_domain_death *deathW; - libxlDriverPrivatePtr driver; -+ unsigned short migrationPort; - - struct libxlDomainJobObj job; - }; -Index: libvirt-1.2.5/src/libxl/libxl_driver.c -=================================================================== ---- libvirt-1.2.5.orig/src/libxl/libxl_driver.c -+++ libvirt-1.2.5/src/libxl/libxl_driver.c -@@ -45,6 +45,7 @@ - #include "libxl_domain.h" - #include "libxl_driver.h" - #include "libxl_conf.h" -+#include "libxl_migration.h" - #include "xen_xm.h" - #include "xen_sxpr.h" - #include "virtypedparam.h" -@@ -209,6 +210,7 @@ libxlStateCleanup(void) - virObjectUnref(libxl_driver->xmlopt); - virObjectUnref(libxl_driver->domains); - virObjectUnref(libxl_driver->reservedVNCPorts); -+ virObjectUnref(libxl_driver->migrationPorts); - - virObjectEventStateFree(libxl_driver->domainEventState); - virSysinfoDefFree(libxl_driver->hostsysinfo); -@@ -301,6 +303,13 @@ libxlStateInitialize(bool privileged, - LIBXL_VNC_PORT_MAX))) - goto error; - -+ /* Allocate bitmap for migration port reservation */ -+ if (!(libxl_driver->migrationPorts = -+ virPortAllocatorNew(_("migration"), -+ LIBXL_MIGRATION_PORT_MIN, -+ LIBXL_MIGRATION_PORT_MAX))) -+ goto error; -+ - if (!(libxl_driver->domains = virDomainObjListNew())) - goto error; - -@@ -4155,6 +4164,7 @@ libxlConnectSupportsFeature(virConnectPt - - switch (feature) { - case VIR_DRV_FEATURE_TYPED_PARAM_STRING: -+ case VIR_DRV_FEATURE_MIGRATION_PARAMS: - return 1; - default: - return 0; -@@ -4333,6 +4343,226 @@ libxlNodeDeviceReset(virNodeDevicePtr de - return ret; - } - -+static char * -+libxlDomainMigrateBegin3Params(virDomainPtr domain, -+ virTypedParameterPtr params, -+ int nparams, -+ char **cookieout ATTRIBUTE_UNUSED, -+ int *cookieoutlen ATTRIBUTE_UNUSED, -+ unsigned int flags) -+{ -+ const char *xmlin = NULL; -+ virDomainObjPtr vm = NULL; -+ -+ virCheckFlags(LIBXL_MIGRATION_FLAGS, NULL); -+ if (virTypedParamsValidate(params, nparams, LIBXL_MIGRATION_PARAMETERS) < 0) -+ return NULL; -+ -+ if (virTypedParamsGetString(params, nparams, -+ VIR_MIGRATE_PARAM_DEST_XML, -+ &xmlin) < 0) -+ return NULL; -+ -+ if (!(vm = libxlDomObjFromDomain(domain))) -+ return NULL; -+ -+ if (virDomainMigrateBegin3ParamsEnsureACL(domain->conn, vm->def) < 0) { -+ virObjectUnlock(vm); -+ return NULL; -+ } -+ -+ if (!virDomainObjIsActive(vm)) { -+ virReportError(VIR_ERR_OPERATION_INVALID, -+ "%s", _("domain is not running")); -+ virObjectUnlock(vm); -+ return NULL; -+ } -+ -+ return libxlDomainMigrationBegin(domain->conn, vm, xmlin); -+} -+ -+static int -+libxlDomainMigratePrepare3Params(virConnectPtr dconn, -+ virTypedParameterPtr params, -+ int nparams, -+ const char *cookiein ATTRIBUTE_UNUSED, -+ int cookieinlen ATTRIBUTE_UNUSED, -+ char **cookieout ATTRIBUTE_UNUSED, -+ int *cookieoutlen ATTRIBUTE_UNUSED, -+ char **uri_out, -+ unsigned int flags) -+{ -+ libxlDriverPrivatePtr driver = dconn->privateData; -+ virDomainDefPtr def = NULL; -+ const char *dom_xml = NULL; -+ const char *dname = NULL; -+ const char *uri_in = NULL; -+ -+ virCheckFlags(LIBXL_MIGRATION_FLAGS, -1); -+ if (virTypedParamsValidate(params, nparams, LIBXL_MIGRATION_PARAMETERS) < 0) -+ goto error; -+ -+ if (virTypedParamsGetString(params, nparams, -+ VIR_MIGRATE_PARAM_DEST_XML, -+ &dom_xml) < 0 || -+ virTypedParamsGetString(params, nparams, -+ VIR_MIGRATE_PARAM_DEST_NAME, -+ &dname) < 0 || -+ virTypedParamsGetString(params, nparams, -+ VIR_MIGRATE_PARAM_URI, -+ &uri_in) < 0) -+ -+ goto error; -+ -+ if (!(def = libxlDomainMigrationPrepareDef(driver, dom_xml, dname))) -+ goto error; -+ -+ if (virDomainMigratePrepare3ParamsEnsureACL(dconn, def) < 0) -+ goto error; -+ -+ if (libxlDomainMigrationPrepare(dconn, def, uri_in, uri_out) < 0) -+ goto error; -+ -+ return 0; -+ -+ error: -+ virDomainDefFree(def); -+ return -1; -+} -+ -+static int -+libxlDomainMigratePerform3Params(virDomainPtr dom, -+ const char *dconnuri, -+ virTypedParameterPtr params, -+ int nparams, -+ const char *cookiein ATTRIBUTE_UNUSED, -+ int cookieinlen ATTRIBUTE_UNUSED, -+ char **cookieout ATTRIBUTE_UNUSED, -+ int *cookieoutlen ATTRIBUTE_UNUSED, -+ unsigned int flags) -+{ -+ libxlDriverPrivatePtr driver = dom->conn->privateData; -+ virDomainObjPtr vm = NULL; -+ const char *dom_xml = NULL; -+ const char *dname = NULL; -+ const char *uri = NULL; -+ int ret = -1; -+ -+ virCheckFlags(LIBXL_MIGRATION_FLAGS, -1); -+ if (virTypedParamsValidate(params, nparams, LIBXL_MIGRATION_PARAMETERS) < 0) -+ goto cleanup; -+ -+ if (virTypedParamsGetString(params, nparams, -+ VIR_MIGRATE_PARAM_DEST_XML, -+ &dom_xml) < 0 || -+ virTypedParamsGetString(params, nparams, -+ VIR_MIGRATE_PARAM_DEST_NAME, -+ &dname) < 0 || -+ virTypedParamsGetString(params, nparams, -+ VIR_MIGRATE_PARAM_URI, -+ &uri) < 0) -+ -+ goto cleanup; -+ -+ if (!(vm = libxlDomObjFromDomain(dom))) -+ goto cleanup; -+ -+ if (virDomainMigratePerform3ParamsEnsureACL(dom->conn, vm->def) < 0) -+ goto cleanup; -+ -+ if (libxlDomainMigrationPerform(driver, vm, dom_xml, dconnuri, -+ uri, dname, flags) < 0) { -+ /* Job terminated and vm unlocked if MigrationPerform failed */ -+ vm = NULL; -+ goto cleanup; -+ } -+ -+ ret = 0; -+ -+ cleanup: -+ if (vm) -+ virObjectUnlock(vm); -+ return ret; -+} -+ -+static virDomainPtr -+libxlDomainMigrateFinish3Params(virConnectPtr dconn, -+ virTypedParameterPtr params, -+ int nparams, -+ const char *cookiein ATTRIBUTE_UNUSED, -+ int cookieinlen ATTRIBUTE_UNUSED, -+ char **cookieout ATTRIBUTE_UNUSED, -+ int *cookieoutlen ATTRIBUTE_UNUSED, -+ unsigned int flags, -+ int cancelled) -+{ -+ libxlDriverPrivatePtr driver = dconn->privateData; -+ virDomainObjPtr vm = NULL; -+ const char *dname = NULL; -+ -+ virCheckFlags(LIBXL_MIGRATION_FLAGS, NULL); -+ if (virTypedParamsValidate(params, nparams, LIBXL_MIGRATION_PARAMETERS) < 0) -+ return NULL; -+ -+ if (virTypedParamsGetString(params, nparams, -+ VIR_MIGRATE_PARAM_DEST_NAME, -+ &dname) < 0) -+ return NULL; -+ -+ if (!dname || -+ !(vm = virDomainObjListFindByName(driver->domains, dname))) { -+ /* Migration obviously failed if the domain doesn't exist */ -+ virReportError(VIR_ERR_OPERATION_FAILED, -+ _("Migration failed. No domain on destination host " -+ "with matching name '%s'"), -+ NULLSTR(dname)); -+ return NULL; -+ } -+ -+ if (virDomainMigrateFinish3ParamsEnsureACL(dconn, vm->def) < 0) { -+ virObjectUnlock(vm); -+ return NULL; -+ } -+ -+ if (!virDomainObjIsActive(vm)) { -+ /* Migration failed if domain is inactive */ -+ virReportError(VIR_ERR_OPERATION_FAILED, -+ "%s", _("Migration failed. Domain is not running " -+ "on destination host")); -+ virObjectUnlock(vm); -+ return NULL; -+ } -+ -+ return libxlDomainMigrationFinish(dconn, vm, flags, cancelled); -+} -+ -+static int -+libxlDomainMigrateConfirm3Params(virDomainPtr domain, -+ virTypedParameterPtr params, -+ int nparams, -+ const char *cookiein ATTRIBUTE_UNUSED, -+ int cookieinlen ATTRIBUTE_UNUSED, -+ unsigned int flags, -+ int cancelled) -+{ -+ libxlDriverPrivatePtr driver = domain->conn->privateData; -+ virDomainObjPtr vm = NULL; -+ -+ virCheckFlags(LIBXL_MIGRATION_FLAGS, -1); -+ if (virTypedParamsValidate(params, nparams, LIBXL_MIGRATION_PARAMETERS) < 0) -+ return -1; -+ -+ if (!(vm = libxlDomObjFromDomain(domain))) -+ return -1; -+ -+ if (virDomainMigrateConfirm3ParamsEnsureACL(domain->conn, vm->def) < 0) { -+ virObjectUnlock(vm); -+ return -1; -+ } -+ -+ return libxlDomainMigrationConfirm(driver, vm, flags, cancelled); -+} -+ - - static virDriver libxlDriver = { - .no = VIR_DRV_LIBXL, -@@ -4423,6 +4653,11 @@ static virDriver libxlDriver = { - .nodeDeviceDetachFlags = libxlNodeDeviceDetachFlags, /* 1.2.3 */ - .nodeDeviceReAttach = libxlNodeDeviceReAttach, /* 1.2.3 */ - .nodeDeviceReset = libxlNodeDeviceReset, /* 1.2.3 */ -+ .domainMigrateBegin3Params = libxlDomainMigrateBegin3Params, /* 1.2.3 */ -+ .domainMigratePrepare3Params = libxlDomainMigratePrepare3Params, /* 1.2.3 */ -+ .domainMigratePerform3Params = libxlDomainMigratePerform3Params, /* 1.2.3 */ -+ .domainMigrateFinish3Params = libxlDomainMigrateFinish3Params, /* 1.2.3 */ -+ .domainMigrateConfirm3Params = libxlDomainMigrateConfirm3Params, /* 1.2.3 */ - }; - - static virStateDriver libxlStateDriver = { -Index: libvirt-1.2.5/src/libxl/libxl_migration.c -=================================================================== ---- /dev/null -+++ libvirt-1.2.5/src/libxl/libxl_migration.c -@@ -0,0 +1,577 @@ -+/* -+ * libxl_migration.c: methods for handling migration with libxenlight -+ * -+ * Copyright (C) 2014 SUSE LINUX Products GmbH, Nuernberg, Germany. -+ * -+ * This library is free software; you can redistribute it and/or -+ * modify it under the terms of the GNU Lesser General Public -+ * License as published by the Free Software Foundation; either -+ * version 2.1 of the License, or (at your option) any later version. -+ * -+ * This library is distributed in the hope that it will be useful, -+ * but WITHOUT ANY WARRANTY; without even the implied warranty of -+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -+ * Lesser General Public License for more details. -+ * -+ * You should have received a copy of the GNU Lesser General Public -+ * License along with this library. If not, see -+ * . -+ * -+ * Authors: -+ * Jim Fehlig -+ * Chunyan Liu -+ */ -+ -+#include -+ -+#include "internal.h" -+#include "virlog.h" -+#include "virerror.h" -+#include "virconf.h" -+#include "datatypes.h" -+#include "virfile.h" -+#include "viralloc.h" -+#include "viruuid.h" -+#include "vircommand.h" -+#include "virstring.h" -+#include "virobject.h" -+#include "rpc/virnetsocket.h" -+#include "libxl_domain.h" -+#include "libxl_driver.h" -+#include "libxl_conf.h" -+#include "libxl_migration.h" -+ -+#define VIR_FROM_THIS VIR_FROM_LIBXL -+ -+VIR_LOG_INIT("libxl.libxl_migration"); -+ -+typedef struct _libxlMigrationDstArgs { -+ virObject parent; -+ -+ virConnectPtr conn; -+ virDomainObjPtr vm; -+ -+ /* for freeing listen sockets */ -+ virNetSocketPtr *socks; -+ size_t nsocks; -+} libxlMigrationDstArgs; -+ -+static virClassPtr libxlMigrationDstArgsClass; -+ -+static void -+libxlMigrationDstArgsDispose(void *obj) -+{ -+ libxlMigrationDstArgs *args = obj; -+ -+ VIR_FREE(args->socks); -+} -+ -+static int -+libxlMigrationDstArgsOnceInit(void) -+{ -+ if (!(libxlMigrationDstArgsClass = virClassNew(virClassForObject(), -+ "libxlMigrationDstArgs", -+ sizeof(libxlMigrationDstArgs), -+ libxlMigrationDstArgsDispose))) -+ return -1; -+ -+ return 0; -+} -+ -+VIR_ONCE_GLOBAL_INIT(libxlMigrationDstArgs) -+ -+static void -+libxlDoMigrateReceive(virNetSocketPtr sock, -+ int events ATTRIBUTE_UNUSED, -+ void *opaque) -+{ -+ libxlMigrationDstArgs *args = opaque; -+ virConnectPtr conn = args->conn; -+ virDomainObjPtr vm = args->vm; -+ virNetSocketPtr *socks = args->socks; -+ size_t nsocks = args->nsocks; -+ libxlDriverPrivatePtr driver = conn->privateData; -+ virNetSocketPtr client_sock; -+ int recvfd = -1; -+ size_t i; -+ int ret; -+ -+ virNetSocketAccept(sock, &client_sock); -+ if (client_sock == NULL) { -+ virReportError(VIR_ERR_OPERATION_INVALID, "%s", -+ _("Fail to accept migration connection")); -+ goto cleanup; -+ } -+ VIR_DEBUG("Accepted migration connection\n"); -+ recvfd = virNetSocketDupFD(client_sock, true); -+ virObjectUnref(client_sock); -+ -+ virObjectLock(vm); -+ ret = libxlDomainStart(driver, vm, false, recvfd); -+ virObjectUnlock(vm); -+ -+ if (ret < 0 && !vm->persistent) -+ virDomainObjListRemove(driver->domains, vm); -+ -+ cleanup: -+ /* Remove all listen socks from event handler, and close them. */ -+ for (i = 0; i < nsocks; i++) { -+ virNetSocketUpdateIOCallback(socks[i], 0); -+ virNetSocketRemoveIOCallback(socks[i]); -+ virNetSocketClose(socks[i]); -+ virObjectUnref(socks[i]); -+ } -+ -+ VIR_FORCE_CLOSE(recvfd); -+} -+ -+static int -+libxlDoMigrateSend(libxlDriverPrivatePtr driver, -+ virDomainObjPtr vm, -+ unsigned long flags, -+ int sockfd) -+{ -+ libxlDomainObjPrivatePtr priv; -+ libxlDriverConfigPtr cfg = libxlDriverConfigGet(driver); -+ virObjectEventPtr event = NULL; -+ int xl_flags = 0; -+ int ret; -+ -+ if (flags & VIR_MIGRATE_LIVE) -+ xl_flags = LIBXL_SUSPEND_LIVE; -+ -+ priv = vm->privateData; -+ ret = libxl_domain_suspend(priv->ctx, vm->def->id, sockfd, -+ xl_flags, NULL); -+ if (ret != 0) { -+ /* attempt to resume the domain on failure */ -+ if (libxl_domain_resume(priv->ctx, vm->def->id, 0, 0) != 0) { -+ VIR_DEBUG("Failed to resume domain following failed migration"); -+ virDomainObjSetState(vm, VIR_DOMAIN_PAUSED, -+ VIR_DOMAIN_PAUSED_MIGRATION); -+ event = virDomainEventLifecycleNewFromObj(vm, VIR_DOMAIN_EVENT_SUSPENDED, -+ VIR_DOMAIN_EVENT_SUSPENDED_MIGRATED); -+ ignore_value(virDomainSaveStatus(driver->xmlopt, cfg->stateDir, vm)); -+ } -+ virReportError(VIR_ERR_INTERNAL_ERROR, "%s", -+ _("Failed to send migration data to destination host")); -+ ret = -1; -+ goto cleanup; -+ } -+ -+ cleanup: -+ if (event) -+ libxlDomainEventQueue(driver, event); -+ virObjectUnref(cfg); -+ return ret; -+} -+ -+static bool -+libxlDomainMigrationIsAllowed(virDomainDefPtr def) -+{ -+ /* Migration is not allowed if definition contains any hostdevs */ -+ if (def->nhostdevs > 0) { -+ virReportError(VIR_ERR_OPERATION_INVALID, "%s", -+ _("domain has assigned host devices")); -+ return false; -+ } -+ -+ return true; -+} -+ -+char * -+libxlDomainMigrationBegin(virConnectPtr conn, -+ virDomainObjPtr vm, -+ const char *xmlin) -+{ -+ libxlDriverPrivatePtr driver = conn->privateData; -+ libxlDriverConfigPtr cfg = libxlDriverConfigGet(driver); -+ virDomainDefPtr tmpdef = NULL; -+ virDomainDefPtr def; -+ char *xml = NULL; -+ -+ if (libxlDomainObjBeginJob(driver, vm, LIBXL_JOB_MODIFY) < 0) -+ goto cleanup; -+ -+ if (xmlin) { -+ if (!(tmpdef = virDomainDefParseString(xmlin, cfg->caps, -+ driver->xmlopt, -+ 1 << VIR_DOMAIN_VIRT_XEN, -+ VIR_DOMAIN_XML_INACTIVE))) -+ goto endjob; -+ -+ def = tmpdef; -+ } else { -+ def = vm->def; -+ } -+ -+ if (!libxlDomainMigrationIsAllowed(def)) -+ goto endjob; -+ -+ xml = virDomainDefFormat(def, VIR_DOMAIN_XML_SECURE); -+ -+ cleanup: -+ if (vm) -+ virObjectUnlock(vm); -+ -+ virDomainDefFree(tmpdef); -+ virObjectUnref(cfg); -+ return xml; -+ -+ endjob: -+ if (!libxlDomainObjEndJob(driver, vm)) -+ vm = NULL; -+ goto cleanup; -+} -+ -+virDomainDefPtr -+libxlDomainMigrationPrepareDef(libxlDriverPrivatePtr driver, -+ const char *dom_xml, -+ const char *dname) -+{ -+ libxlDriverConfigPtr cfg = libxlDriverConfigGet(driver); -+ virDomainDefPtr def; -+ char *name = NULL; -+ -+ if (!dom_xml) { -+ virReportError(VIR_ERR_INTERNAL_ERROR, "%s", -+ _("no domain XML passed")); -+ return NULL; -+ } -+ -+ if (!(def = virDomainDefParseString(dom_xml, cfg->caps, driver->xmlopt, -+ 1 << VIR_DOMAIN_VIRT_XEN, -+ VIR_DOMAIN_XML_INACTIVE))) -+ goto cleanup; -+ -+ if (dname) { -+ name = def->name; -+ if (VIR_STRDUP(def->name, dname) < 0) { -+ virDomainDefFree(def); -+ def = NULL; -+ } -+ } -+ -+ cleanup: -+ virObjectUnref(cfg); -+ VIR_FREE(name); -+ return def; -+} -+ -+int -+libxlDomainMigrationPrepare(virConnectPtr dconn, -+ virDomainDefPtr def, -+ const char *uri_in, -+ char **uri_out) -+{ -+ libxlDriverPrivatePtr driver = dconn->privateData; -+ virDomainObjPtr vm = NULL; -+ char *hostname = NULL; -+ unsigned short port; -+ char portstr[100]; -+ virURIPtr uri = NULL; -+ virNetSocketPtr *socks = NULL; -+ size_t nsocks = 0; -+ int nsocks_listen = 0; -+ libxlMigrationDstArgs *args; -+ size_t i; -+ int ret = -1; -+ -+ if (!(vm = virDomainObjListAdd(driver->domains, def, -+ driver->xmlopt, -+ VIR_DOMAIN_OBJ_LIST_ADD_LIVE | -+ VIR_DOMAIN_OBJ_LIST_ADD_CHECK_LIVE, -+ NULL))) -+ goto cleanup; -+ -+ /* Create socket connection to receive migration data */ -+ if (!uri_in) { -+ if ((hostname = virGetHostname()) == NULL) -+ goto cleanup; -+ -+ if (STRPREFIX(hostname, "localhost")) { -+ virReportError(VIR_ERR_INTERNAL_ERROR, "%s", -+ _("hostname on destination resolved to localhost," -+ " but migration requires an FQDN")); -+ goto cleanup; -+ } -+ -+ if (virPortAllocatorAcquire(driver->migrationPorts, &port) < 0) -+ goto cleanup; -+ -+ if (virAsprintf(uri_out, "tcp://%s:%d", hostname, port) < 0) -+ goto cleanup; -+ } else { -+ if (!(STRPREFIX(uri_in, "tcp://"))) { -+ /* not full URI, add prefix tcp:// */ -+ char *tmp; -+ if (virAsprintf(&tmp, "tcp://%s", uri_in) < 0) -+ goto cleanup; -+ uri = virURIParse(tmp); -+ VIR_FREE(tmp); -+ } else { -+ uri = virURIParse(uri_in); -+ } -+ -+ if (uri == NULL) { -+ virReportError(VIR_ERR_INVALID_ARG, -+ _("unable to parse URI: %s"), -+ uri_in); -+ goto cleanup; -+ } -+ -+ if (uri->server == NULL) { -+ virReportError(VIR_ERR_INVALID_ARG, -+ _("missing host in migration URI: %s"), -+ uri_in); -+ goto cleanup; -+ } else { -+ hostname = uri->server; -+ } -+ -+ if (uri->port == 0) { -+ if (virPortAllocatorAcquire(driver->migrationPorts, &port) < 0) -+ goto cleanup; -+ -+ } else { -+ port = uri->port; -+ } -+ -+ if (virAsprintf(uri_out, "tcp://%s:%d", hostname, port) < 0) -+ goto cleanup; -+ } -+ -+ snprintf(portstr, sizeof(portstr), "%d", port); -+ -+ if (virNetSocketNewListenTCP(hostname, portstr, &socks, &nsocks) < 0) { -+ virReportError(VIR_ERR_OPERATION_FAILED, "%s", -+ _("Fail to create socket for incoming migration")); -+ goto cleanup; -+ } -+ -+ if (libxlMigrationDstArgsInitialize() < 0) -+ goto cleanup; -+ -+ if (!(args = virObjectNew(libxlMigrationDstArgsClass))) -+ goto cleanup; -+ -+ args->conn = dconn; -+ args->vm = vm; -+ args->socks = socks; -+ args->nsocks = nsocks; -+ -+ for (i = 0; i < nsocks; i++) { -+ if (virNetSocketSetBlocking(socks[i], true) < 0) -+ continue; -+ -+ if (virNetSocketListen(socks[i], 1) < 0) -+ continue; -+ -+ if (virNetSocketAddIOCallback(socks[i], -+ VIR_EVENT_HANDLE_READABLE, -+ libxlDoMigrateReceive, -+ args, -+ virObjectFreeCallback) < 0) -+ continue; -+ -+ /* -+ * Successfully added sock to event loop. Take a ref on args to -+ * ensure it is not freed until sock is removed from the event loop. -+ * Ref is dropped in virObjectFreeCallback after being removed -+ * from the event loop. -+ */ -+ virObjectRef(args); -+ nsocks_listen++; -+ } -+ -+ /* Done with args in this function, drop reference */ -+ virObjectUnref(args); -+ -+ if (!nsocks_listen) -+ goto cleanup; -+ -+ ret = 0; -+ goto done; -+ -+ cleanup: -+ for (i = 0; i < nsocks; i++) { -+ virNetSocketClose(socks[i]); -+ virObjectUnref(socks[i]); -+ } -+ -+ done: -+ virURIFree(uri); -+ if (vm) -+ virObjectUnlock(vm); -+ return ret; -+} -+ -+int -+libxlDomainMigrationPerform(libxlDriverPrivatePtr driver, -+ virDomainObjPtr vm, -+ const char *dom_xml ATTRIBUTE_UNUSED, -+ const char *dconnuri ATTRIBUTE_UNUSED, -+ const char *uri_str, -+ const char *dname ATTRIBUTE_UNUSED, -+ unsigned int flags) -+{ -+ char *hostname = NULL; -+ unsigned short port = 0; -+ char portstr[100]; -+ virURIPtr uri = NULL; -+ virNetSocketPtr sock; -+ int sockfd = -1; -+ int saved_errno = EINVAL; -+ int ret = -1; -+ -+ /* parse dst host:port from uri */ -+ uri = virURIParse(uri_str); -+ if (uri == NULL || uri->server == NULL || uri->port == 0) -+ goto cleanup; -+ -+ hostname = uri->server; -+ port = uri->port; -+ snprintf(portstr, sizeof(portstr), "%d", port); -+ -+ /* socket connect to dst host:port */ -+ if (virNetSocketNewConnectTCP(hostname, portstr, &sock) < 0) { -+ virReportSystemError(saved_errno, -+ _("unable to connect to '%s:%s'"), -+ hostname, portstr); -+ goto cleanup; -+ } -+ -+ if (virNetSocketSetBlocking(sock, true) < 0) { -+ virObjectUnref(sock); -+ goto cleanup; -+ } -+ -+ sockfd = virNetSocketDupFD(sock, true); -+ virObjectUnref(sock); -+ -+ /* suspend vm and send saved data to dst through socket fd */ -+ virObjectUnlock(vm); -+ ret = libxlDoMigrateSend(driver, vm, flags, sockfd); -+ virObjectLock(vm); -+ -+ cleanup: -+ /* If failure, terminate the job started in MigrationBegin */ -+ if (ret == -1) { -+ if (libxlDomainObjEndJob(driver, vm)) -+ virObjectUnlock(vm); -+ } -+ VIR_FORCE_CLOSE(sockfd); -+ virURIFree(uri); -+ return ret; -+} -+ -+virDomainPtr -+libxlDomainMigrationFinish(virConnectPtr dconn, -+ virDomainObjPtr vm, -+ unsigned int flags, -+ int cancelled) -+{ -+ libxlDriverPrivatePtr driver = dconn->privateData; -+ libxlDriverConfigPtr cfg = libxlDriverConfigGet(driver); -+ libxlDomainObjPrivatePtr priv = vm->privateData; -+ virObjectEventPtr event = NULL; -+ virDomainPtr dom = NULL; -+ -+ virPortAllocatorRelease(driver->migrationPorts, priv->migrationPort); -+ priv->migrationPort = 0; -+ -+ if (cancelled) -+ goto cleanup; -+ -+ if (!(flags & VIR_MIGRATE_PAUSED)) { -+ if (libxl_domain_unpause(priv->ctx, vm->def->id) != 0) { -+ virReportError(VIR_ERR_OPERATION_FAILED, "%s", -+ _("Failed to unpause domain")); -+ goto cleanup; -+ } -+ -+ virDomainObjSetState(vm, VIR_DOMAIN_RUNNING, -+ VIR_DOMAIN_RUNNING_MIGRATED); -+ event = virDomainEventLifecycleNewFromObj(vm, -+ VIR_DOMAIN_EVENT_RESUMED, -+ VIR_DOMAIN_EVENT_RESUMED_MIGRATED); -+ } else { -+ virDomainObjSetState(vm, VIR_DOMAIN_PAUSED, VIR_DOMAIN_PAUSED_USER); -+ event = virDomainEventLifecycleNewFromObj(vm, -+ VIR_DOMAIN_EVENT_SUSPENDED, -+ VIR_DOMAIN_EVENT_SUSPENDED_PAUSED); -+ } -+ -+ if (virDomainSaveStatus(driver->xmlopt, cfg->stateDir, vm) < 0) -+ goto cleanup; -+ -+ dom = virGetDomain(dconn, vm->def->name, vm->def->uuid); -+ -+ if (dom == NULL) { -+ libxl_domain_destroy(priv->ctx, vm->def->id, NULL); -+ libxlDomainCleanup(driver, vm, VIR_DOMAIN_SHUTOFF_FAILED); -+ event = virDomainEventLifecycleNewFromObj(vm, VIR_DOMAIN_EVENT_STOPPED, -+ VIR_DOMAIN_EVENT_STOPPED_FAILED); -+ libxlDomainEventQueue(driver, event); -+ } -+ -+ cleanup: -+ if (event) -+ libxlDomainEventQueue(driver, event); -+ if (vm) -+ virObjectUnlock(vm); -+ virObjectUnref(cfg); -+ return dom; -+} -+ -+int -+libxlDomainMigrationConfirm(libxlDriverPrivatePtr driver, -+ virDomainObjPtr vm, -+ unsigned int flags, -+ int cancelled) -+{ -+ libxlDriverConfigPtr cfg = libxlDriverConfigGet(driver); -+ libxlDomainObjPrivatePtr priv = vm->privateData; -+ virObjectEventPtr event = NULL; -+ int ret = -1; -+ -+ if (cancelled) { -+ if (libxl_domain_resume(priv->ctx, vm->def->id, 1, 0) == 0) { -+ ret = 0; -+ } else { -+ VIR_DEBUG("Unable to resume domain '%s' after failed migration", -+ vm->def->name); -+ virDomainObjSetState(vm, VIR_DOMAIN_PAUSED, -+ VIR_DOMAIN_PAUSED_MIGRATION); -+ event = virDomainEventLifecycleNewFromObj(vm, VIR_DOMAIN_EVENT_SUSPENDED, -+ VIR_DOMAIN_EVENT_SUSPENDED_MIGRATED); -+ ignore_value(virDomainSaveStatus(driver->xmlopt, cfg->stateDir, vm)); -+ } -+ goto cleanup; -+ } -+ -+ libxl_domain_destroy(priv->ctx, vm->def->id, NULL); -+ libxlDomainCleanup(driver, vm, VIR_DOMAIN_SHUTOFF_MIGRATED); -+ event = virDomainEventLifecycleNewFromObj(vm, VIR_DOMAIN_EVENT_STOPPED, -+ VIR_DOMAIN_EVENT_STOPPED_MIGRATED); -+ -+ VIR_DEBUG("Domain '%s' successfully migrated", vm->def->name); -+ -+ if (flags & VIR_MIGRATE_UNDEFINE_SOURCE) -+ virDomainDeleteConfig(cfg->configDir, cfg->autostartDir, vm); -+ -+ if (!vm->persistent || (flags & VIR_MIGRATE_UNDEFINE_SOURCE)) -+ virDomainObjListRemove(driver->domains, vm); -+ -+ ret = 0; -+ -+ cleanup: -+ if (!libxlDomainObjEndJob(driver, vm)) -+ vm = NULL; -+ if (event) -+ libxlDomainEventQueue(driver, event); -+ if (vm) -+ virObjectUnlock(vm); -+ virObjectUnref(cfg); -+ return ret; -+} -Index: libvirt-1.2.5/src/libxl/libxl_migration.h -=================================================================== ---- /dev/null -+++ libvirt-1.2.5/src/libxl/libxl_migration.h -@@ -0,0 +1,78 @@ -+/* -+ * libxl_migration.h: methods for handling migration with libxenlight -+ * -+ * Copyright (c) 2014 SUSE LINUX Products GmbH, Nuernberg, Germany. -+ * -+ * This library is free software; you can redistribute it and/or -+ * modify it under the terms of the GNU Lesser General Public -+ * License as published by the Free Software Foundation; either -+ * version 2.1 of the License, or (at your option) any later version. -+ * -+ * This library is distributed in the hope that it will be useful, -+ * but WITHOUT ANY WARRANTY; without even the implied warranty of -+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -+ * Lesser General Public License for more details. -+ * -+ * You should have received a copy of the GNU Lesser General Public -+ * License along with this library. If not, see -+ * . -+ * -+ * Authors: -+ * Jim Fehlig -+ */ -+ -+#ifndef LIBXL_MIGRATION_H -+# define LIBXL_MIGRATION_H -+ -+# include "libxl_conf.h" -+ -+# define LIBXL_MIGRATION_FLAGS \ -+ (VIR_MIGRATE_LIVE | \ -+ VIR_MIGRATE_UNDEFINE_SOURCE | \ -+ VIR_MIGRATE_PAUSED) -+ -+/* All supported migration parameters and their types. */ -+# define LIBXL_MIGRATION_PARAMETERS \ -+ VIR_MIGRATE_PARAM_URI, VIR_TYPED_PARAM_STRING, \ -+ VIR_MIGRATE_PARAM_DEST_NAME, VIR_TYPED_PARAM_STRING, \ -+ VIR_MIGRATE_PARAM_DEST_XML, VIR_TYPED_PARAM_STRING, \ -+ NULL -+ -+char * -+libxlDomainMigrationBegin(virConnectPtr conn, -+ virDomainObjPtr vm, -+ const char *xmlin); -+ -+virDomainDefPtr -+libxlDomainMigrationPrepareDef(libxlDriverPrivatePtr driver, -+ const char *dom_xml, -+ const char *dname); -+ -+int -+libxlDomainMigrationPrepare(virConnectPtr dconn, -+ virDomainDefPtr def, -+ const char *uri_in, -+ char **uri_out); -+ -+int -+libxlDomainMigrationPerform(libxlDriverPrivatePtr driver, -+ virDomainObjPtr vm, -+ const char *dom_xml, -+ const char *dconnuri, -+ const char *uri_str, -+ const char *dname, -+ unsigned int flags); -+ -+virDomainPtr -+libxlDomainMigrationFinish(virConnectPtr dconn, -+ virDomainObjPtr vm, -+ unsigned int flags, -+ int cancelled); -+ -+int -+libxlDomainMigrationConfirm(libxlDriverPrivatePtr driver, -+ virDomainObjPtr vm, -+ unsigned int flags, -+ int cancelled); -+ -+#endif /* LIBXL_DRIVER_H */ diff --git a/lxc-keep-caps-feature-conversion.patch b/lxc-keep-caps-feature-conversion.patch index 7516716..89f3a76 100644 --- a/lxc-keep-caps-feature-conversion.patch +++ b/lxc-keep-caps-feature-conversion.patch @@ -18,11 +18,11 @@ Subject: [PATCH 2/3] lxc domain from xml: convert lxc.cap.drop tests/lxcconf2xmldata/lxcconf2xml-vlannetwork.xml | 4 ++++ 12 files changed, 61 insertions(+) -diff --git a/src/lxc/lxc_native.c b/src/lxc/lxc_native.c -index f4c4556..29ec188 100644 ---- a/src/lxc/lxc_native.c -+++ b/src/lxc/lxc_native.c -@@ -838,6 +838,28 @@ lxcSetBlkioTune(virDomainDefPtr def, virConfPtr properties) +Index: libvirt-1.2.6/src/lxc/lxc_native.c +=================================================================== +--- libvirt-1.2.6.orig/src/lxc/lxc_native.c ++++ libvirt-1.2.6/src/lxc/lxc_native.c +@@ -838,6 +838,28 @@ lxcSetBlkioTune(virDomainDefPtr def, vir return 0; } @@ -61,10 +61,10 @@ index f4c4556..29ec188 100644 goto cleanup; error: -diff --git a/tests/lxcconf2xmldata/lxcconf2xml-blkiotune.xml b/tests/lxcconf2xmldata/lxcconf2xml-blkiotune.xml -index 36b8e52..c9c0469 100644 ---- a/tests/lxcconf2xmldata/lxcconf2xml-blkiotune.xml -+++ b/tests/lxcconf2xmldata/lxcconf2xml-blkiotune.xml +Index: libvirt-1.2.6/tests/lxcconf2xmldata/lxcconf2xml-blkiotune.xml +=================================================================== +--- libvirt-1.2.6.orig/tests/lxcconf2xmldata/lxcconf2xml-blkiotune.xml ++++ libvirt-1.2.6/tests/lxcconf2xmldata/lxcconf2xml-blkiotune.xml @@ -25,6 +25,8 @@ @@ -74,10 +74,10 @@ index 36b8e52..c9c0469 100644 destroy -diff --git a/tests/lxcconf2xmldata/lxcconf2xml-cpusettune.xml b/tests/lxcconf2xmldata/lxcconf2xml-cpusettune.xml -index 932ab61..e7863fa 100644 ---- a/tests/lxcconf2xmldata/lxcconf2xml-cpusettune.xml -+++ b/tests/lxcconf2xmldata/lxcconf2xml-cpusettune.xml +Index: libvirt-1.2.6/tests/lxcconf2xmldata/lxcconf2xml-cpusettune.xml +=================================================================== +--- libvirt-1.2.6.orig/tests/lxcconf2xmldata/lxcconf2xml-cpusettune.xml ++++ libvirt-1.2.6/tests/lxcconf2xmldata/lxcconf2xml-cpusettune.xml @@ -13,6 +13,8 @@ @@ -87,10 +87,10 @@ index 932ab61..e7863fa 100644 destroy -diff --git a/tests/lxcconf2xmldata/lxcconf2xml-cputune.xml b/tests/lxcconf2xmldata/lxcconf2xml-cputune.xml -index 1bab1c6..50c5358 100644 ---- a/tests/lxcconf2xmldata/lxcconf2xml-cputune.xml -+++ b/tests/lxcconf2xmldata/lxcconf2xml-cputune.xml +Index: libvirt-1.2.6/tests/lxcconf2xmldata/lxcconf2xml-cputune.xml +=================================================================== +--- libvirt-1.2.6.orig/tests/lxcconf2xmldata/lxcconf2xml-cputune.xml ++++ libvirt-1.2.6/tests/lxcconf2xmldata/lxcconf2xml-cputune.xml @@ -15,6 +15,8 @@ @@ -100,10 +100,10 @@ index 1bab1c6..50c5358 100644 destroy -diff --git a/tests/lxcconf2xmldata/lxcconf2xml-idmap.xml b/tests/lxcconf2xmldata/lxcconf2xml-idmap.xml -index 050ccd6..80a83ff 100644 ---- a/tests/lxcconf2xmldata/lxcconf2xml-idmap.xml -+++ b/tests/lxcconf2xmldata/lxcconf2xml-idmap.xml +Index: libvirt-1.2.6/tests/lxcconf2xmldata/lxcconf2xml-idmap.xml +=================================================================== +--- libvirt-1.2.6.orig/tests/lxcconf2xmldata/lxcconf2xml-idmap.xml ++++ libvirt-1.2.6/tests/lxcconf2xmldata/lxcconf2xml-idmap.xml @@ -14,6 +14,8 @@ @@ -113,10 +113,10 @@ index 050ccd6..80a83ff 100644 destroy -diff --git a/tests/lxcconf2xmldata/lxcconf2xml-macvlannetwork.xml b/tests/lxcconf2xmldata/lxcconf2xml-macvlannetwork.xml -index 996c0f7..3105b8c 100644 ---- a/tests/lxcconf2xmldata/lxcconf2xml-macvlannetwork.xml -+++ b/tests/lxcconf2xmldata/lxcconf2xml-macvlannetwork.xml +Index: libvirt-1.2.6/tests/lxcconf2xmldata/lxcconf2xml-macvlannetwork.xml +=================================================================== +--- libvirt-1.2.6.orig/tests/lxcconf2xmldata/lxcconf2xml-macvlannetwork.xml ++++ libvirt-1.2.6/tests/lxcconf2xmldata/lxcconf2xml-macvlannetwork.xml @@ -8,6 +8,10 @@ exe /sbin/init @@ -128,10 +128,10 @@ index 996c0f7..3105b8c 100644 destroy restart -diff --git a/tests/lxcconf2xmldata/lxcconf2xml-memtune.xml b/tests/lxcconf2xmldata/lxcconf2xml-memtune.xml -index b7c919e..7df1ef0 100644 ---- a/tests/lxcconf2xmldata/lxcconf2xml-memtune.xml -+++ b/tests/lxcconf2xmldata/lxcconf2xml-memtune.xml +Index: libvirt-1.2.6/tests/lxcconf2xmldata/lxcconf2xml-memtune.xml +=================================================================== +--- libvirt-1.2.6.orig/tests/lxcconf2xmldata/lxcconf2xml-memtune.xml ++++ libvirt-1.2.6/tests/lxcconf2xmldata/lxcconf2xml-memtune.xml @@ -15,6 +15,8 @@ @@ -141,10 +141,10 @@ index b7c919e..7df1ef0 100644 destroy -diff --git a/tests/lxcconf2xmldata/lxcconf2xml-nonenetwork.xml b/tests/lxcconf2xmldata/lxcconf2xml-nonenetwork.xml -index 6d9e16d..e002b99 100644 ---- a/tests/lxcconf2xmldata/lxcconf2xml-nonenetwork.xml -+++ b/tests/lxcconf2xmldata/lxcconf2xml-nonenetwork.xml +Index: libvirt-1.2.6/tests/lxcconf2xmldata/lxcconf2xml-nonenetwork.xml +=================================================================== +--- libvirt-1.2.6.orig/tests/lxcconf2xmldata/lxcconf2xml-nonenetwork.xml ++++ libvirt-1.2.6/tests/lxcconf2xmldata/lxcconf2xml-nonenetwork.xml @@ -8,6 +8,10 @@ exe /sbin/init @@ -156,10 +156,10 @@ index 6d9e16d..e002b99 100644 destroy restart -diff --git a/tests/lxcconf2xmldata/lxcconf2xml-nonetwork.xml b/tests/lxcconf2xmldata/lxcconf2xml-nonetwork.xml -index 101324a..dc9d635 100644 ---- a/tests/lxcconf2xmldata/lxcconf2xml-nonetwork.xml -+++ b/tests/lxcconf2xmldata/lxcconf2xml-nonetwork.xml +Index: libvirt-1.2.6/tests/lxcconf2xmldata/lxcconf2xml-nonetwork.xml +=================================================================== +--- libvirt-1.2.6.orig/tests/lxcconf2xmldata/lxcconf2xml-nonetwork.xml ++++ libvirt-1.2.6/tests/lxcconf2xmldata/lxcconf2xml-nonetwork.xml @@ -10,6 +10,8 @@ @@ -169,10 +169,10 @@ index 101324a..dc9d635 100644 destroy -diff --git a/tests/lxcconf2xmldata/lxcconf2xml-physnetwork.xml b/tests/lxcconf2xmldata/lxcconf2xml-physnetwork.xml -index 5fe1b03..cfaceb5 100644 ---- a/tests/lxcconf2xmldata/lxcconf2xml-physnetwork.xml -+++ b/tests/lxcconf2xmldata/lxcconf2xml-physnetwork.xml +Index: libvirt-1.2.6/tests/lxcconf2xmldata/lxcconf2xml-physnetwork.xml +=================================================================== +--- libvirt-1.2.6.orig/tests/lxcconf2xmldata/lxcconf2xml-physnetwork.xml ++++ libvirt-1.2.6/tests/lxcconf2xmldata/lxcconf2xml-physnetwork.xml @@ -8,6 +8,10 @@ exe /sbin/init @@ -184,10 +184,10 @@ index 5fe1b03..cfaceb5 100644 destroy restart -diff --git a/tests/lxcconf2xmldata/lxcconf2xml-simple.xml b/tests/lxcconf2xmldata/lxcconf2xml-simple.xml -index b3c3659..549fc39 100644 ---- a/tests/lxcconf2xmldata/lxcconf2xml-simple.xml -+++ b/tests/lxcconf2xmldata/lxcconf2xml-simple.xml +Index: libvirt-1.2.6/tests/lxcconf2xmldata/lxcconf2xml-simple.xml +=================================================================== +--- libvirt-1.2.6.orig/tests/lxcconf2xmldata/lxcconf2xml-simple.xml ++++ libvirt-1.2.6/tests/lxcconf2xmldata/lxcconf2xml-simple.xml @@ -8,6 +8,14 @@ exe /sbin/init @@ -203,10 +203,10 @@ index b3c3659..549fc39 100644 destroy restart -diff --git a/tests/lxcconf2xmldata/lxcconf2xml-vlannetwork.xml b/tests/lxcconf2xmldata/lxcconf2xml-vlannetwork.xml -index 45348ed..712be3e 100644 ---- a/tests/lxcconf2xmldata/lxcconf2xml-vlannetwork.xml -+++ b/tests/lxcconf2xmldata/lxcconf2xml-vlannetwork.xml +Index: libvirt-1.2.6/tests/lxcconf2xmldata/lxcconf2xml-vlannetwork.xml +=================================================================== +--- libvirt-1.2.6.orig/tests/lxcconf2xmldata/lxcconf2xml-vlannetwork.xml ++++ libvirt-1.2.6/tests/lxcconf2xmldata/lxcconf2xml-vlannetwork.xml @@ -8,6 +8,10 @@ exe /sbin/init @@ -218,6 +218,3 @@ index 45348ed..712be3e 100644 destroy restart --- -1.8.4.5 - diff --git a/lxc-keep-caps-feature-doc.patch b/lxc-keep-caps-feature-doc.patch index 44bfd82..5ece112 100644 --- a/lxc-keep-caps-feature-doc.patch +++ b/lxc-keep-caps-feature-doc.patch @@ -8,11 +8,11 @@ Subject: [PATCH 3/3] lxc: update doc to mention features/capabilities/* domain docs/drvlxc.html.in | 47 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 47 insertions(+) -diff --git a/docs/drvlxc.html.in b/docs/drvlxc.html.in -index fc4bc20..403ce24 100644 ---- a/docs/drvlxc.html.in -+++ b/docs/drvlxc.html.in -@@ -540,6 +540,53 @@ debootstrap, whatever) under /opt/vm-1-root: +Index: libvirt-1.2.6/docs/drvlxc.html.in +=================================================================== +--- libvirt-1.2.6.orig/docs/drvlxc.html.in ++++ libvirt-1.2.6/docs/drvlxc.html.in +@@ -540,6 +540,53 @@ debootstrap, whatever) under /opt/vm-1-r </domain> @@ -66,6 +66,3 @@ index fc4bc20..403ce24 100644

Container usage / management

--- -1.8.4.5 - diff --git a/lxc-keep-caps-feature.patch b/lxc-keep-caps-feature.patch index a561abf..09a2f86 100644 --- a/lxc-keep-caps-feature.patch +++ b/lxc-keep-caps-feature.patch @@ -25,10 +25,10 @@ this mechanism. 9 files changed, 602 insertions(+), 25 deletions(-) create mode 100644 tests/domainschemadata/domain-caps-features.xml -Index: libvirt-1.2.5/docs/schemas/domaincommon.rng +Index: libvirt-1.2.6/docs/schemas/domaincommon.rng =================================================================== ---- libvirt-1.2.5.orig/docs/schemas/domaincommon.rng -+++ libvirt-1.2.5/docs/schemas/domaincommon.rng +--- libvirt-1.2.6.orig/docs/schemas/domaincommon.rng ++++ libvirt-1.2.6/docs/schemas/domaincommon.rng @@ -3744,6 +3744,9 @@ @@ -39,7 +39,7 @@ Index: libvirt-1.2.5/docs/schemas/domaincommon.rng -@@ -4290,6 +4293,200 @@ +@@ -4311,6 +4314,200 @@ @@ -240,7 +240,7 @@ Index: libvirt-1.2.5/docs/schemas/domaincommon.rng -@@ -4298,6 +4495,16 @@ +@@ -4319,6 +4516,16 @@ @@ -257,10 +257,10 @@ Index: libvirt-1.2.5/docs/schemas/domaincommon.rng