Re: [libvirt] [Qemu-devel] Close the BlockDriverState when guest eject the media

2014-10-21 Thread Gonglei
On 2014/10/21 13:53, Weidong Huang wrote: On 2014/10/20 19:39, Kevin Wolf wrote: Am 20.10.2014 um 13:27 hat Weidong Huang geschrieben: On 2014/10/20 17:41, Kevin Wolf wrote: Am 18.10.2014 um 12:02 hat Weidong Huang geschrieben: Hi ALL: There are two ways to eject the cdrom tray. One is

Re: [libvirt] [Qemu-devel] spec, RFC: TLS support for NBDµ

2014-10-21 Thread Markus Armbruster
Wouter Verhelst w...@uter.be writes: On Mon, Oct 20, 2014 at 01:51:43PM +0200, Markus Armbruster wrote: Stefan Hajnoczi stefa...@redhat.com writes: On Mon, Oct 20, 2014 at 08:58:14AM +0100, Daniel P. Berrange wrote: On Sat, Oct 18, 2014 at 07:33:22AM +0100, Richard W.M. Jones wrote: On

[libvirt] [libvirt-python PATCH] Fix cannot use VIR_CONNECT_GET_ALL_DOMAINS_STATS_ENFORCE_STATS flags in domainListGetStats

2014-10-21 Thread Luyao Huang
When set flags=libvirt.VIR_CONNECT_GET_ALL_DOMAINS_STATS_ENFORCE_STATS, python will report a error: OverflowError: signed integer is greater than maximum Because VIR_CONNECT_GET_ALL_DOMAINS_STATS_ENFORCE_STATS = 2147483648 (2**31), and it set a signed int in PyArg_ParseTuple function. if

Re: [libvirt] [Qemu-devel] spec, RFC: TLS support for NBD

2014-10-21 Thread Daniel P. Berrange
On Tue, Oct 21, 2014 at 12:10:39AM +0200, Wouter Verhelst wrote: On Mon, Oct 20, 2014 at 01:56:43PM +0200, Florian Weimer wrote: I cannot comment on whether the proposed STARTTLS command is at the correct stage of the NBD protocol. If there is a protocol description for NBD, I can have a

Re: [libvirt] [PATCH] - make virDomainDetachDeviceFlags respect VIR_DOMAIN_DEVICE_MODIFY_FORCE

2014-10-21 Thread Martin Kletzander
On Fri, Oct 10, 2014 at 09:05:01AM +0200, Marcin Gibuła wrote: Hi, currently, there is no way to force disk detach from KVM guest if guest does not cooperate. This patch makes virDomainDetachDeviceFlags() respect VIR_DOMAIN_DEVICE_MODIFY_FORCE flag. When it's on, libvirt will always call

[libvirt] [PATCH] qemu: unref cfg after TerminateMachine has been called

2014-10-21 Thread Martin Kletzander
Commit 60627f6d added the code that requests driver cfg, but forgot to unref it. Signed-off-by: Martin Kletzander mklet...@redhat.com --- src/qemu/qemu_cgroup.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/qemu/qemu_cgroup.c b/src/qemu/qemu_cgroup.c index fa894c5..b5bdb36 100644 ---

Re: [libvirt] [PATCH] qemu: move setting emulatorpin ahead of monitor showing up

2014-10-21 Thread Martin Kletzander
On Thu, Oct 16, 2014 at 10:18:48PM +0800, Wang Rui wrote: From: Zhou yimin zhouyi...@huawei.com If VM is configured with many devices(including passthrough devices) and large memory, libvirtd will take seconds(in the worst case) to wait for monitor. In this period the qemu process may run on

[libvirt] [PATCH] docs: Mention repository locations in contributor guidelines

2014-10-21 Thread Martin Kletzander
Signed-off-by: Martin Kletzander mklet...@redhat.com --- HACKING | 18 +++--- docs/hacking.html.in | 5 + 2 files changed, 16 insertions(+), 7 deletions(-) diff --git a/HACKING b/HACKING index add0841..f8546cb 100644 --- a/HACKING +++ b/HACKING @@ -14,7 +14,11 @@

Re: [libvirt] [PATCH] qemu: x86_64 is good enough for i686

2014-10-21 Thread Martin Kletzander
On Thu, Oct 16, 2014 at 09:28:00PM +0200, Lubomir Rintel wrote: virt-manager on Fedora sets up i686 hosts with /usr/bin/qemu-kvm emulator, which in turn unconditionally execs qemu-system-x86_64 querying capabilities then fails: Error launching details: invalid argument: architecture from

Re: [libvirt] [PATCH] qemu: x86_64 is good enough for i686

2014-10-21 Thread Daniel P. Berrange
On Tue, Oct 21, 2014 at 01:33:00PM +0200, Martin Kletzander wrote: On Thu, Oct 16, 2014 at 09:28:00PM +0200, Lubomir Rintel wrote: virt-manager on Fedora sets up i686 hosts with /usr/bin/qemu-kvm emulator, which in turn unconditionally execs qemu-system-x86_64 querying capabilities then fails:

Re: [libvirt] [PATCH] docs: Mention repository locations in contributor guidelines

2014-10-21 Thread Peter Krempa
On 10/21/14 12:25, Martin Kletzander wrote: Signed-off-by: Martin Kletzander mklet...@redhat.com --- HACKING | 18 +++--- docs/hacking.html.in | 5 + 2 files changed, 16 insertions(+), 7 deletions(-) ACK, Peter signature.asc Description: OpenPGP digital

Re: [libvirt] [PATCH] qemu: unref cfg after TerminateMachine has been called

2014-10-21 Thread Peter Krempa
On 10/21/14 12:25, Martin Kletzander wrote: Commit 60627f6d added the code that requests driver cfg, but forgot to Commit ID doesn't exist in libvirt.git unref it. Signed-off-by: Martin Kletzander mklet...@redhat.com --- src/qemu/qemu_cgroup.c | 2 ++ 1 file changed, 2 insertions(+)

Re: [libvirt] [PATCH/RFC] Add missing delta from Ubuntu to apparmor profiles

2014-10-21 Thread Stefan Bader
On 20.10.2014 12:48, Stefan Bader wrote: On 19.10.2014 17:07, intrigeri wrote: Hi Stefan, Stefan Bader wrote (19 Oct 2014 11:07:40 GMT) : Yeah, I actually did but it felt a bit hackish but then I am told anything looks a bit hackish when it involves autoconf. These are again against

Re: [libvirt] [PATCH] qemu: unref cfg after TerminateMachine has been called

2014-10-21 Thread Martin Kletzander
On Tue, Oct 21, 2014 at 01:49:37PM +0200, Peter Krempa wrote: On 10/21/14 12:25, Martin Kletzander wrote: Commit 60627f6d added the code that requests driver cfg, but forgot to Commit ID doesn't exist in libvirt.git Yep, my fault, it's 4882618ed13b469d92fa8b2b4a158fdb17dbe9f1, thanks for

Re: [libvirt] [libvirt-python PATCH] Fix cannot use VIR_CONNECT_GET_ALL_DOMAINS_STATS_ENFORCE_STATS flags in domainListGetStats

2014-10-21 Thread Peter Krempa
On 10/21/14 11:04, Luyao Huang wrote: When set flags=libvirt.VIR_CONNECT_GET_ALL_DOMAINS_STATS_ENFORCE_STATS, python will report a error: OverflowError: signed integer is greater than maximum Because VIR_CONNECT_GET_ALL_DOMAINS_STATS_ENFORCE_STATS = 2147483648 (2**31), and it set a

[libvirt] [PATCH v2] Fix cast errors with clang

2014-10-21 Thread Roman Bogorodskiy
Build with clang fails with: CC util/libvirt_util_la-virsocketaddr.lo util/virsocketaddr.c:904:17: error: cast from 'struct sockaddr *' to 'struct sockaddr_in *' increases required alignment from 1 to 4 [-Werror,-Wcast-align] inet4 = (struct sockaddr_in*) res-ai_addr;

Re: [libvirt] [PATCH] Fix cast errors with clang

2014-10-21 Thread Roman Bogorodskiy
Eric Blake wrote: On 10/18/2014 10:41 AM, Roman Bogorodskiy wrote: Build with clang fails with: CC util/libvirt_util_la-virsocketaddr.lo util/virsocketaddr.c:904:17: error: cast from 'struct sockaddr *' to 'struct sockaddr_in *' increases required alignment from 1 to 4

[libvirt] [python PATCH 2/3] Fix parsing of 'flags' argument for bulk stats functions

2014-10-21 Thread Peter Krempa
From: Luyao Huang lhu...@redhat.com When 'flags' is set to 'libvirt.VIR_CONNECT_GET_ALL_DOMAINS_STATS_ENFORCE_STATS, python will report a error: OverflowError: signed integer is greater than maximum as VIR_CONNECT_GET_ALL_DOMAINS_STATS_ENFORCE_STATS is defined as 131. This happens as

[libvirt] [python PATCH 3/3] Fix rest of unsigned integer handling

2014-10-21 Thread Peter Krempa
As in the previous patch, fix all places where 'flags' is converted as a signed argument to unsigned including the python code generator. --- generator.py| 2 +- libvirt-lxc-override.c | 2 +- libvirt-override.c | 128

[libvirt] [python PATCH 1/3] Fix function name when parsing arguments in libvirt_virNodeAllocPages

2014-10-21 Thread Peter Krempa
The override function was copiedpasted from virConnectGetAllDomainStats and the function name after the collon was not changed. Fix the issue as an invalid name would appear in the error message. --- libvirt-override.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git

[libvirt] [python PATCH 0/3] Fix multiple python binding issues

2014-10-21 Thread Peter Krempa
Luyao Huang (1): Fix parsing of 'flags' argument for bulk stats functions Peter Krempa (2): Fix function name when parsing arguments in libvirt_virNodeAllocPages Fix rest of unsigned integer handling generator.py| 2 +- libvirt-lxc-override.c | 2 +- libvirt-override.c

Re: [libvirt] [PATCH] Add support for /run/initctl

2014-10-21 Thread Rick Harris
Hi all, A few weeks ago I proposed a patch to fix LXC shutdown for distros that use `/run/initctl` instead of `/dev/initctl`. Replying here so that it gets some more visibility. Would love some feedback here: are people happy with the general approach? This is my first libvirt patch: is the

Re: [libvirt] [PATCH v4] network: Add bandwidth support to ethernet interfaces

2014-10-21 Thread Anirban Chakraborty
On 10/10/14, 3:23 PM, Anirban Chakraborty abc...@juniper.net wrote: v4: Changed function virNetDevSupportBandwidth to use switch statement. Fixed syntax issues Fold the two patches into one as the second patch was a one liner v3: Addressed issues pointed out in V2 Split into two patches v2:

Re: [libvirt] Close the BlockDriverState when guest eject the media

2014-10-21 Thread Weidong Huang
On 2014/10/20 19:39, Kevin Wolf wrote: Am 20.10.2014 um 13:27 hat Weidong Huang geschrieben: On 2014/10/20 17:41, Kevin Wolf wrote: Am 18.10.2014 um 12:02 hat Weidong Huang geschrieben: Hi ALL: There are two ways to eject the cdrom tray. One is by the eject's qmp commmand(eject_device).

Re: [libvirt] [PATCH v2] Fix cast errors with clang

2014-10-21 Thread Eric Blake
On 10/21/2014 08:22 AM, Roman Bogorodskiy wrote: Build with clang fails with: CC util/libvirt_util_la-virsocketaddr.lo util/virsocketaddr.c:904:17: error: cast from 'struct sockaddr *' to 'struct sockaddr_in *' increases required alignment from 1 to 4 [-Werror,-Wcast-align]

Re: [libvirt] [Qemu-devel] spec, RFC: TLS support for NBD

2014-10-21 Thread Wouter Verhelst
On Tue, Oct 21, 2014 at 10:35:06AM +0100, Daniel P. Berrange wrote: On Tue, Oct 21, 2014 at 12:10:39AM +0200, Wouter Verhelst wrote: On Mon, Oct 20, 2014 at 01:56:43PM +0200, Florian Weimer wrote: I cannot comment on whether the proposed STARTTLS command is at the correct stage of the

Re: [libvirt] [python PATCH 2/3] Fix parsing of 'flags' argument for bulk stats functions

2014-10-21 Thread Eric Blake
On 10/21/2014 08:34 AM, Peter Krempa wrote: From: Luyao Huang lhu...@redhat.com When 'flags' is set to 'libvirt.VIR_CONNECT_GET_ALL_DOMAINS_STATS_ENFORCE_STATS, python will report a error: OverflowError: signed integer is greater than maximum as

Re: [libvirt] [python PATCH 1/3] Fix function name when parsing arguments in libvirt_virNodeAllocPages

2014-10-21 Thread Eric Blake
On 10/21/2014 08:34 AM, Peter Krempa wrote: The override function was copiedpasted from virConnectGetAllDomainStats and the function name after the collon was not changed. Fix the issue as s/collon/colon/ an invalid name would appear in the error message. --- libvirt-override.c | 2 +- 1

Re: [libvirt] [python PATCH 3/3] Fix rest of unsigned integer handling

2014-10-21 Thread Eric Blake
On 10/21/2014 08:34 AM, Peter Krempa wrote: As in the previous patch, fix all places where 'flags' is converted as a signed argument to unsigned including the python code generator. --- generator.py| 2 +- libvirt-lxc-override.c | 2 +- libvirt-override.c | 128

Re: [libvirt] [Qemu-devel] spec, RFC: TLS support for NBDµ

2014-10-21 Thread Wouter Verhelst
Hi Markus, On Tue, Oct 21, 2014 at 10:17:17AM +0200, Markus Armbruster wrote: Wouter Verhelst w...@uter.be writes: On Mon, Oct 20, 2014 at 01:51:43PM +0200, Markus Armbruster wrote: [...] Furthermore, STARTTLS is vulnerable to active attacks: if you can get between the peers, you can make

Re: [libvirt] libvirt build failure on armhf (Re: [Xen-devel] [libvirt bisection] complete build-armhf-libvirt)

2014-10-21 Thread Jim Fehlig
Ian Campbell wrote: Hi, On Fri, 2014-10-17 at 00:42 +0100, xen.org wrote: *** Found and reproduced problem changeset *** Bug is in tree: libvirt git://libvirt.org/libvirt.git Bug introduced: 24c160376275b7d31f71fbde83af8183cbf744a7 Bug not present:

[libvirt] [python PATCH] Fix flags cannot get right value for blockCopy function

2014-10-21 Thread Luyao Huang
When use blockCopy, flags cannot get a right value, because PyArg_ParseTuple want to get 6 parameters and blockCopy only pass 5.Flags will get a unpredictable value, this will make this function cannot be used.And error just like: unsupported flags (0x7f6c) in function qemuDomainBlockCopy