[libvirt] [PATCHv3 3/3] Always check return value of qemuDomainObjExitMonitor

2015-01-14 Thread Ján Tomko
Depending on the context, either error out if the domain has disappeared in the meantime, or just ignore the value to allow marking the function as ATTRIBUTE_RETURN_CHECK. --- src/qemu/qemu_domain.c| 11 ++-- src/qemu/qemu_domain.h| 3 +- src/qemu/qemu_driver.c| 163

[libvirt] [PATCHv3 2/3] Fix vmdef usage after domain crash in monitor on device attach

2015-01-14 Thread Ján Tomko
https://bugzilla.redhat.com/show_bug.cgi?id=1161024 If the domain crashed while we were in monitor, we cannot rely on the REALLOC done on live definition, since vm-def now points to the persistent definition. Skip adding the attached devices to domain definition if the domain crashed. In

[libvirt] [PATCHv3 0/3] Fix vmdef usage after ExitMonitor

2015-01-14 Thread Ján Tomko
The patches 1-2, 6-8 from v2 have been pushed already Device removal and device detach are now squashed together. Both attach and detach skip audit when the domain crashed. (Left to be cleaned up by a separate series) Patches checking the return value in all other non-fatal cases were squashed

[libvirt] [PATCHv3 1/3] Fix vmdef usage after domain crash in monitor on device detach

2015-01-14 Thread Ján Tomko
https://bugzilla.redhat.com/show_bug.cgi?id=1161024 In the device type-specific functions, exit early if the domain has disappeared, because the cleanup should have been done by qemuProcessStop. Check the return value in processDeviceDeletedEvent and qemuProcessUpdateDevices. Fix vmdef usage

Re: [libvirt] [PATCH 3/3] storage: Adjustments to disk backend to use stateDir

2015-01-14 Thread John Ferlan
On 01/14/2015 04:46 AM, Daniel P. Berrange wrote: On Tue, Jan 13, 2015 at 04:12:32PM -0500, John Ferlan wrote: https://bugzilla.redhat.com/show_bug.cgi?id=1138516 The disk backend uses 'parted' in order to create and delete partitions on the disk for use in the pool. At creation time, one

[libvirt] Plans for next release

2015-01-14 Thread Daniel Veillard
It's start to think pushing a new release. Last one was mid-december so we ought to push one this month, I will be travelling the last week and since February is short I suppose pushing the release a bit early is not a problem. We have around 180 commits already, and I would like to push for

[libvirt] [python PATCH] build: make it easier to backport event ids

2015-01-14 Thread Eric Blake
In some cases, it is very easy for downstream distros to backport enum values without requiring a .so bump. Keying the conditional code off of the upstream version where the enum value was added is not ideal, because downstream then has to patch that the feature is available in their build that

Re: [libvirt] question about the flow of live migration with non-shared storage in libvirt

2015-01-14 Thread Eric Blake
On 01/14/2015 02:44 AM, Zhang Haoyu wrote: Hi, Someone can help detail the the flow of live migration with non-shared storage in libvirt? Especially, the flow of migration of non-shared storage part? The code is in src/qemu/qemu_migration.c. Also, read src/qemu/MIGRATION.txt. Libvirt

[libvirt] [PATCH v3] qemu: Allow UEFI paths to be specified at compile time

2015-01-14 Thread Michal Privoznik
Up until now there are just two ways how to specify UEFI paths to libvirt. The first one is editing qemu.conf, the other is editing qemu_conf.c and recompile which is not that fancy. So, new configure option is introduced: --with-loader-nvram which takes a list of pairs of UEFI firmware and NVRAM

Re: [libvirt] [PATCHv2 13/14] Exit early after domain crash in monitor on snapshots

2015-01-14 Thread Ján Tomko
On 01/13/2015 03:43 PM, John Ferlan wrote: no commit message On 01/07/2015 10:42 AM, Ján Tomko wrote: --- src/qemu/qemu_domain.c | 2 +- src/qemu/qemu_driver.c | 18 ++ 2 files changed, 7 insertions(+), 13 deletions(-) diff --git a/src/qemu/qemu_domain.c

[libvirt] [PATCH V5 0/3] Parser for xen-xl config format

2015-01-14 Thread Jim Fehlig
V5 of xen-xl parser. V4 was close https://www.redhat.com/archives/libvir-list/2015-January/msg00429.html but the tests did not exersice the spice parsing/formatting code. It is now fixed in V5, along with addressing a few V4 comments from eblake. Jim Fehlig (1): Introduce support for

[libvirt] [PATCH V5 1/3] Introduce support for parsing/formatting Xen xl config format

2015-01-14 Thread Jim Fehlig
Introduce a parser/formatter for the xl config format. Since the deprecation of xm/xend, the VM config file format has diverged as new features are added to libxl. This patch adds support for parsing and formating the xl config format. It supports the existing xm config format, plus adds

[libvirt] [PATCH V5 2/3] tests: Tests for the xen-xl parser

2015-01-14 Thread Jim Fehlig
From: Kiarie Kahurani davidkiar...@gmail.com Add disk and spice config tests for the xen_xl config parser Signed-off-by: Kiarie Kahurani davidkiar...@gmail.com Signed-off-by: Jim Fehlig jfeh...@suse.com --- V5: Enable spice test. Fix invalid config in the test data files and an actual bug in

[libvirt] [PATCH V5 3/3] libxl: Add support for parsing/formating Xen XL config

2015-01-14 Thread Jim Fehlig
From: Kiarie Kahurani davidkiar...@gmail.com Now that xenconfig supports parsing and formatting Xen's XL config format, integrate it into the libxl driver's connectDomainXML{From,To}Native functions. Signed-off-by: Kiarie Kahurani davidkiar...@gmail.com Signed-off-by: Jim Fehlig jfeh...@suse.com

Re: [libvirt] Attempting to pivot disk with incomplete mirror results in hang

2015-01-14 Thread Scott Sullivan
On 01/13/2015 11:48 PM, Eric Blake wrote: On 01/13/2015 12:43 PM, Scott Sullivan wrote: I have what appears to be a bug when pivoting a disk during a block copy that is not yet 100% finished, resulting in the pivot command hanging. I have verified this problem on libvirt 1.2.10. I couldn't

Re: [libvirt] [PATCH V4 1/3] Introduce support for parsing/formatting Xen xl config format

2015-01-14 Thread Jim Fehlig
Eric Blake wrote: On 01/13/2015 04:47 PM, Jim Fehlig wrote: +++ b/src/Makefile.am @@ -1005,6 +1005,10 @@ XENCONFIG_SOURCES = \ xenconfig/xen_common.c xenconfig/xen_common.h \ xenconfig/xen_sxpr.c xenconfig/xen_sxpr.h

Re: [libvirt] [PATCH 0/4] Misc work on systemd/lxc

2015-01-14 Thread Michal Privoznik
On 14.01.2015 15:05, Daniel P. Berrange wrote: This is just a few patches working towards an eventual goal of being ble to tell system the tap/veth devices associated with a qemu/lxc guest. Daniel P. Berrange (4): Add support for systemd-machined CreateMachineWithNetwork Add

Re: [libvirt] [PATCH V5 0/3] Parser for xen-xl config format

2015-01-14 Thread Eric Blake
On 01/14/2015 08:50 AM, Jim Fehlig wrote: V5 of xen-xl parser. V4 was close https://www.redhat.com/archives/libvir-list/2015-January/msg00429.html but the tests did not exersice the spice parsing/formatting code. It is now fixed in V5, along with addressing a few V4 comments from eblake.

Re: [libvirt] [PATCH V5 0/3] Parser for xen-xl config format

2015-01-14 Thread Jim Fehlig
Eric Blake wrote: On 01/14/2015 08:50 AM, Jim Fehlig wrote: V5 of xen-xl parser. V4 was close https://www.redhat.com/archives/libvir-list/2015-January/msg00429.html but the tests did not exersice the spice parsing/formatting code. It is now fixed in V5, along with addressing a few V4

Re: [libvirt] [PATCH v2 2/2] check IOMMU group devices usage when preparing device for vfio passthrough

2015-01-14 Thread Michal Privoznik
On 14.01.2015 12:03, Shivaprasad G Bhat wrote: The virsh start domain fails with qemu error when the hostdevices of the same iommu group are used actively by other vms. It is not clear which hostdev from the same iommu group is used by any of the running guests. User has to go through every

Re: [libvirt] [PATCH v2 0/2] check IOMMU group devices usage when preparing device for vfio passthrough

2015-01-14 Thread Michal Privoznik
On 14.01.2015 12:01, Shivaprasad G Bhat wrote: If a device in the same iommu group is in use by a different vm, the guest boot fails with the below error during vfio passthrough. bash-4.2$ virsh start demo error: Failed to

Re: [libvirt] [PATCH v2 1/2] Implement virPCIDeviceGetAddress function

2015-01-14 Thread Michal Privoznik
On 14.01.2015 12:02, Shivaprasad G Bhat wrote: Basically a getter function which is implemented for accessing the address fields in virPCIDevice. Signed-off-by: Shivaprasad G Bhat sb...@linux.vnet.ibm.com --- src/util/virpci.c | 16 src/util/virpci.h |1 + 2 files

[libvirt] [PATCH v4 2/2] qemu_process: detect updated video ram size values from QEMU

2015-01-14 Thread Pavel Hrdina
QEMU internally updates the size of video memory if the domain XML had provided too low memory size or there are some dependencies for a QXL devices 'vgamem' and 'ram' size. We need to know about the changes and store them into the status XML to not break migration or managedsave through different

Re: [libvirt] [PATCH] qemu_driver: fix setting vcpus for offline domain

2015-01-14 Thread Peter Krempa
On Tue, Jan 13, 2015 at 02:46:03PM +0100, Pavel Hrdina wrote: Commit e3435caf fixed hot-plugging of vcpus with strict memory pinning on NUMA hosts, but unfortunately it also broke updating number of vcpus for offline guests using our API. The issue is that we try to create a cpu cgroup for

Re: [libvirt] [PATCH] qemu_driver: fix setting vcpus for offline domain

2015-01-14 Thread Pavel Hrdina
On 01/14/2015 10:23 AM, Peter Krempa wrote: On Tue, Jan 13, 2015 at 02:46:03PM +0100, Pavel Hrdina wrote: Commit e3435caf fixed hot-plugging of vcpus with strict memory pinning on NUMA hosts, but unfortunately it also broke updating number of vcpus for offline guests using our API. The issue

Re: [libvirt] [PATCH 3/3] storage: Adjustments to disk backend to use stateDir

2015-01-14 Thread Daniel P. Berrange
On Tue, Jan 13, 2015 at 04:12:32PM -0500, John Ferlan wrote: https://bugzilla.redhat.com/show_bug.cgi?id=1138516 The disk backend uses 'parted' in order to create and delete partitions on the disk for use in the pool. At creation time, one can specify a specific name for the volume as well

Re: [libvirt] [PATCH v4 2/2] qemu_process: detect updated video ram size values from QEMU

2015-01-14 Thread Jiri Denemark
On Wed, Jan 14, 2015 at 10:27:29 +0100, Pavel Hrdina wrote: QEMU internally updates the size of video memory if the domain XML had provided too low memory size or there are some dependencies for a QXL devices 'vgamem' and 'ram' size. We need to know about the changes and store them into the

[libvirt] question about the flow of live migration with non-shared storage in libvirt

2015-01-14 Thread Zhang Haoyu
Hi, Someone can help detail the the flow of live migration with non-shared storage in libvirt? Especially, the flow of migration of non-shared storage part? Thanks, Zhang Haoyu -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list

[libvirt] [PATCH v2 1/2] Implement virPCIDeviceGetAddress function

2015-01-14 Thread Shivaprasad G Bhat
Basically a getter function which is implemented for accessing the address fields in virPCIDevice. Signed-off-by: Shivaprasad G Bhat sb...@linux.vnet.ibm.com --- src/util/virpci.c | 16 src/util/virpci.h |1 + 2 files changed, 17 insertions(+) diff --git

[libvirt] [PATCH v2 0/2] check IOMMU group devices usage when preparing device for vfio passthrough

2015-01-14 Thread Shivaprasad G Bhat
If a device in the same iommu group is in use by a different vm, the guest boot fails with the below error during vfio passthrough. bash-4.2$ virsh start demo error: Failed to start domain demo error: internal error: process

[libvirt] [PATCH v2 2/2] check IOMMU group devices usage when preparing device for vfio passthrough

2015-01-14 Thread Shivaprasad G Bhat
The virsh start domain fails with qemu error when the hostdevices of the same iommu group are used actively by other vms. It is not clear which hostdev from the same iommu group is used by any of the running guests. User has to go through every guest xml to figure out who is using the hostdev of

Re: [libvirt] [PATCH v3 1/2] qemu_monitor: introduce new function to get QOM path

2015-01-14 Thread Pavel Hrdina
On 01/13/2015 04:47 PM, Jiri Denemark wrote: On Fri, Jan 09, 2015 at 14:26:25 +0100, Pavel Hrdina wrote: The search is done recursively only through QOM object that has a type prefixed with child as this indicate that the QOM is a parent for other QOM objects. The usage is that you give known

Re: [libvirt] [PATCH v4 2/2] qemu_process: detect updated video ram size values from QEMU

2015-01-14 Thread Pavel Hrdina
On 01/14/2015 11:38 AM, Jiri Denemark wrote: On Wed, Jan 14, 2015 at 10:27:29 +0100, Pavel Hrdina wrote: QEMU internally updates the size of video memory if the domain XML had provided too low memory size or there are some dependencies for a QXL devices 'vgamem' and 'ram' size. We need to know

Re: [libvirt] [PATCH 1/2] Move struct _virPCIDevice definition from virpci.c to virpci.h

2015-01-14 Thread Shivaprasad bhat
Thanks for the comments Michal. I just posted the v2 for review. Regards. Shiva On Mon, Jan 12, 2015 at 2:43 PM, Michal Privoznik mpriv...@redhat.com wrote: On 04.12.2014 08:27, Shivaprasad G Bhat wrote: The struct members can't be referenced from files including the .h. Moving the

[libvirt] [PATCH 4/4] Change int to size_t in size var for tap/vhost FDs

2015-01-14 Thread Daniel P. Berrange
A number of methods take an int for a parameter that indicates the size of an array. The correct type for array sizes is size_t --- src/qemu/qemu_command.c | 18 +- src/qemu/qemu_command.h | 10 +- src/qemu/qemu_hotplug.c | 4 ++-- src/util/virnetdevtap.c | 8

[libvirt] [PATCH 0/4] Misc work on systemd/lxc

2015-01-14 Thread Daniel P. Berrange
This is just a few patches working towards an eventual goal of being ble to tell system the tap/veth devices associated with a qemu/lxc guest. Daniel P. Berrange (4): Add support for systemd-machined CreateMachineWithNetwork Add systemd/dtrace probes for DBus APIs Log dtrace/systemd probes

[libvirt] [PATCH 3/4] Log dtrace/systemd probes at INFO level instead of DEBUG

2015-01-14 Thread Daniel P. Berrange
Every dtrace/systemd probe also include a libvirt log message. These are logged at level DEBUG currently, which means if you want to see all probes they are drowned by the rest of the DEBUG messages. Since we don't really use the INFO log level for much, it seems reasonable to suggest we log all

[libvirt] [PATCH 2/4] Add systemd/dtrace probes for DBus APIs

2015-01-14 Thread Daniel P. Berrange
When debugging libvirt it is helpful to set probes around RPC calls. We already have probes for libvirt's native RPC layer, so it makes sense to add them for the DBus RPC layer too. --- src/libvirt_probes.d | 5 + src/util/virdbus.c | 26 +++--- 2 files changed, 28

[libvirt] [PATCH 1/4] Add support for systemd-machined CreateMachineWithNetwork

2015-01-14 Thread Daniel P. Berrange
systemd-machined introduced a new method CreateMachineWithNetwork that obsoletes CreateMachine. It expects to be given a list of VETH/TAP device indexes for the host side device(s) associated with a container/machine. This falls back to the old CreateeMachine method when the new one is not