[libvirt] [PATCH] Fix Memory Leak in virStorageFileGetMetadataRecurse()

2014-04-17 Thread Nehal J Wani
While running virstoragetest, valgrind pointed out the following memory leak: ==8142== 2 bytes in 1 blocks are definitely lost in loss record 1 of 92 ==8142==at 0x4A069EE: malloc (vg_replace_malloc.c:270) ==8142==by 0x4E7B53E: mdir_name (dirname-lgpl.c:78) ==8142==by 0x4CBE2B0: virStor

[libvirt] [PATCH] Only set QEMU_CAPS_NO_HPET on x86

2014-04-17 Thread Ján Tomko
QEMU only supports it on x86, but we've been assuming it for all QEMUs when doing QMP capability detection. https://bugzilla.redhat.com/show_bug.cgi?id=1066145 --- src/qemu/qemu_capabilities.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/qemu/qemu_capabilities.c b/src/q

[libvirt] [PATCH] Remove QEMU_CAPS_MACHINE_USB_OPT from ComputeCmdFlags

2014-04-17 Thread Ján Tomko
The version check is for >1.3.0, but ComputeCmdFlags is only called for QEMU older than 1.2.0. --- src/qemu/qemu_capabilities.c | 4 1 file changed, 4 deletions(-) diff --git a/src/qemu/qemu_capabilities.c b/src/qemu/qemu_capabilities.c index 381b3ec..5814c7c 100644 --- a/src/qemu/qemu_capab

Re: [libvirt] [PATCH] docs: document that vfio is default for hostdev networks too

2014-04-17 Thread Martin Kletzander
On Thu, Apr 17, 2014 at 04:53:50PM +0300, Laine Stump wrote: When the default was changed from kvm to vfio, the documentation for hostdev and interface was changed, but the documentation in was forgotten. When was that done? I'd suggest adjusting that to match versions when KVM was added and

Re: [libvirt] libvirt-libxl driver defaulting to tap disk and not working (ubuntu 12.10 + xen 4.5 + libvirt 1.2.3 + openstack)

2014-04-17 Thread John Haxby
On 17/04/14 10:51, Tian, Shuangtai wrote: > > As I recall, tap2 is deprecated and libxl will fail with it. Perhaps try tap or just leaving the driver as default? jch -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list

Re: [libvirt] [PATCH] Qemu fails to restore when guest has selinux static context

2014-04-17 Thread Martin Kletzander
On Tue, Apr 08, 2014 at 09:11:33AM -0400, Shivaprasad G Bhat wrote: The file handle passed from libvirt to qemu is not set to the context of the guest. So, set the selinux context of fd before passing it to qemu Signed-off-by: Shivaprasad G Bhat --- src/qemu/qemu_driver.c |3 +++ 1 file chang

[libvirt] [PATCH] docs: document that vfio is default for hostdev networks too

2014-04-17 Thread Laine Stump
When the default was changed from kvm to vfio, the documentation for hostdev and interface was changed, but the documentation in was forgotten. --- docs/formatnetwork.html.in | 23 +-- 1 file changed, 13 insertions(+), 10 deletions(-) diff --git a/docs/formatnetwork.html.in b

[libvirt] [PATCHv2 4/4] network: centralize check for active network during interface attach

2014-04-17 Thread Laine Stump
The check for a network being active during interface attach was being done individually in several places (by both the lxc driver and the qemu driver), but those places were too specific, leading to it *not* being checked when allocating a connection/device from a macvtap or hostdev network. This

[libvirt] [PATCHv2 1/4] network: create statedir during driver initialization

2014-04-17 Thread Laine Stump
This directory should be created when the network driver is first started up, not just when a dhcp daemon is run. This hasn't posed a problem in the past, because the directory has always been pre-existing. --- Change from V1: mistakenly went to "cleanup" on error rather than "error" :-P src/netw

[libvirt] [PATCHv2 3/4] network: set macvtap/hostdev networks active if their state file exists

2014-04-17 Thread Laine Stump
libvirt attempts to determine at startup time which networks are already active, and set their active flags. Previously it has done this by assuming that all networks are inactive, then setting the active flag if the network has a bridge device associated with it and that bridge device exists. This

[libvirt] [PATCHv2 2/4] network: change location of network state xml files

2014-04-17 Thread Laine Stump
For some reason these have been stored in /var/lib, although other drivers (e.g. qemu and lxc) store their state files in /var/run. It's much nicer to store state files in /var/run because it is automatically cleared out when the system reboots. We can then use existence of the state file as a con

[libvirt] [PATCHv2 0/4] network: fix active status & usage of inactive networks

2014-04-17 Thread Laine Stump
The original patch series is here: https://www.redhat.com/archives/libvir-list/2014-April/msg00454.html This repost addresses problems pointed out by John Ferlan in his review (and other things that I thought better of during the revisions). All 4 patches are required to address https://bug

Re: [libvirt] [PATCHv2 2/2] security_dac: Honor norelabel attribute

2014-04-17 Thread Ján Tomko
On 04/04/2014 02:34 PM, Michal Privoznik wrote: > The inspiration for this patch comes from a question on the list > asking if there's a way to not label some disks. Well, in DAC driver > there's not. Even if user have requested norelabel: > > > > > > > >

Re: [libvirt] qemu: Unlock the NWFilter update lock by leaving via the cleanup label

2014-04-17 Thread Stefan Berger
On 04/17/2014 02:31 AM, Ján Tomko wrote: On 04/16/2014 11:54 PM, Stefan Berger wrote: Fix a locking problem by leaving the function via the cleanup label. Signed-off-by: Stefan Berger --- src/qemu/qemu_driver.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) ACK Pushed. -- li

Re: [libvirt] [PATCH 11/26] Introduce an object for managing firewall rulesets

2014-04-17 Thread Stefan Berger
On 04/08/2014 11:38 AM, Daniel P. Berrange wrote: The network and nwfilter drivers both have a need to update firewall rules. The currently share no code for interacting with iptables / firewalld. The nwfilter driver is fairly tied to the concept of creating shell scripts to execute which makes i

[libvirt] [PATCH] qemu: don't check for backing chains for formats w/o snapshot support

2014-04-17 Thread Martin Kletzander
Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1019926 Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=868673 Signed-off-by: Martin Kletzander --- src/libvirt_private.syms | 2 +- src/qemu/qemu_domain.c| 3 +++ src/util/virstoragefile.c | 15 +++ src/util/virstora

[libvirt] libvirt-libxl driver defaulting to tap disk and not working (ubuntu 12.10 + xen 4.5 + libvirt 1.2.3 + openstack)

2014-04-17 Thread Tian, Shuangtai
HI I am an openstacker, when I used the latest libvirt and xen code to run the openstack. Can not create the vm. there is an error in libxl log, you can see the log: Os : Ubuntu 12.10 Compiled against library: libvirt 1.2.3 Using library: libvirt 1.2.3 Using API: Xen 1.2.3 Running hypervisor: Xen

Re: [libvirt] [PATCH 23/26] Convert nwfilter ebiptablesApplyNewRules to virFirewall

2014-04-17 Thread Daniel P. Berrange
On Wed, Apr 16, 2014 at 03:38:39PM -0400, Stefan Berger wrote: > > } > > > > if (HAS_ENTRY_ITEM(&ipHdr->dataComment)) { > >-printCommentVar(prefix, ipHdr->dataComment.u.string); > >- > > /* keep comments behind everything else -- they are packet eval. > > no-o