[libvirt] [PATCH 5/5] domain: fix the main function name to be consistent with file name

2012-06-13 Thread Wanlong Gao
The main function name should be consistent with the file's basename. Signed-off-by: Wanlong Gao gaowanl...@cn.fujitsu.com --- repos/domain/domain_blkinfo.py | 2 +- repos/domain/domain_id.py | 2 +- repos/domain/domain_name.py| 2 +- repos/domain/domain_uuid.py| 2 +- 4 files

[libvirt] [PATCH 3/5] domain_uuid: fix the wrong import module

2012-06-13 Thread Wanlong Gao
sharemod should be sharedmod from src. Signed-off-by: Wanlong Gao gaowanl...@cn.fujitsu.com --- repos/domain/domain_uuid.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/repos/domain/domain_uuid.py b/repos/domain/domain_uuid.py index d08952d..1c4ed77 100644 ---

[libvirt] [PATCH 4/5] domain: remove the dup case

2012-06-13 Thread Wanlong Gao
remove the domblkinfo which duped with domain_blkinfo. Signed-off-by: Wanlong Gao gaowanl...@cn.fujitsu.com --- repos/domain/domblkinfo.py | 116 - 1 file changed, 116 deletions(-) delete mode 100644 repos/domain/domblkinfo.py diff --git

Re: [libvirt] [PATCH 1/2] drop the removed module check

2012-06-13 Thread Osier Yang
On 2012年06月13日 12:22, Wanlong Gao wrote: check.py has been dropped and functions moved into utils.py. Signed-off-by: Wanlong Gaogaowanl...@cn.fujitsu.com --- repos/domain/balloon_memory.py | 1 - 1 file changed, 1 deletion(-) diff --git a/repos/domain/balloon_memory.py

Re: [libvirt] [PATCH 3/5] domain_uuid: fix the wrong import module

2012-06-13 Thread Osier Yang
On 2012年06月13日 14:53, Wanlong Gao wrote: sharemod should be sharedmod from src. Signed-off-by: Wanlong Gaogaowanl...@cn.fujitsu.com --- repos/domain/domain_uuid.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/repos/domain/domain_uuid.py

Re: [libvirt] [PATCH 2/2] domain: fix the wrong param

2012-06-13 Thread Osier Yang
On 2012年06月13日 12:22, Wanlong Gao wrote: Add the missed comma typo. Signed-off-by: Wanlong Gaogaowanl...@cn.fujitsu.com --- repos/domain/create.py | 2 +- repos/domain/define.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/repos/domain/create.py

Re: [libvirt] [PATCH 5/5] domain: fix the main function name to be consistent with file name

2012-06-13 Thread Osier Yang
On 2012年06月13日 14:53, Wanlong Gao wrote: The main function name should be consistent with the file's basename. Signed-off-by: Wanlong Gaogaowanl...@cn.fujitsu.com --- repos/domain/domain_blkinfo.py | 2 +- repos/domain/domain_id.py | 2 +- repos/domain/domain_name.py| 2 +-

Re: [libvirt] [PATCH 4/5] domain: remove the dup case

2012-06-13 Thread Osier Yang
On 2012年06月13日 14:53, Wanlong Gao wrote: remove the domblkinfo which duped with domain_blkinfo. Signed-off-by: Wanlong Gaogaowanl...@cn.fujitsu.com --- repos/domain/domblkinfo.py | 116 - 1 file changed, 116 deletions(-) delete mode 100644

Re: [libvirt] [PATCH 1/2] drop the removed module check

2012-06-13 Thread Osier Yang
On 2012年06月13日 12:22, Wanlong Gao wrote: check.py has been dropped and functions moved into utils.py. Signed-off-by: Wanlong Gaogaowanl...@cn.fujitsu.com --- repos/domain/balloon_memory.py | 1 - 1 file changed, 1 deletion(-) diff --git a/repos/domain/balloon_memory.py

Re: [libvirt] [PATCHv2 variant 2] snapshot: implement new APIs for esx and vbox

2012-06-13 Thread Osier Yang
On 2012年06月12日 06:08, Eric Blake wrote: The two new APIs are rather trivial; based on bits and pieces of other existing APIs. I chose to blindly return 0 for HasMetadata, since we already do that for other APIs like domainIsPersistent. * src/esx/esx_driver.c (esxDomainSnapshotIsCurrent)

Re: [libvirt] [PATCH 01/12] client rpc: Improve debug messages in virNetClientIO

2012-06-13 Thread Daniel P. Berrange
On Wed, Jun 13, 2012 at 01:29:19AM +0200, Jiri Denemark wrote: When analyzing our debug log, I'm always confused about what each of the pointers mean. Let's be explicit. --- src/rpc/virnetclient.c | 12 1 file changed, 8 insertions(+), 4 deletions(-) ACK Daniel -- |:

Re: [libvirt] [PATCH 02/12] client rpc: Use event loop for writing

2012-06-13 Thread Daniel P. Berrange
On Wed, Jun 13, 2012 at 01:29:20AM +0200, Jiri Denemark wrote: Normally, when every call has a thread associated with it, the thread may get the buck and be in charge of sending all calls until its own call is done. When we introduced non-blocking calls, we had to add special handling of new

Re: [libvirt] [PATCH 02/12] client rpc: Use event loop for writing

2012-06-13 Thread Jiri Denemark
On Wed, Jun 13, 2012 at 09:30:30 +0100, Daniel P. Berrange wrote: On Wed, Jun 13, 2012 at 01:29:20AM +0200, Jiri Denemark wrote: Normally, when every call has a thread associated with it, the thread may get the buck and be in charge of sending all calls until its own call is done. When we

Re: [libvirt] [PATCH 02/12] client rpc: Use event loop for writing

2012-06-13 Thread Daniel P. Berrange
On Wed, Jun 13, 2012 at 10:40:48AM +0200, Jiri Denemark wrote: On Wed, Jun 13, 2012 at 09:30:30 +0100, Daniel P. Berrange wrote: On Wed, Jun 13, 2012 at 01:29:20AM +0200, Jiri Denemark wrote: Normally, when every call has a thread associated with it, the thread may get the buck and be in

Re: [libvirt] [PATCH 02/12] client rpc: Use event loop for writing

2012-06-13 Thread Jiri Denemark
On Wed, Jun 13, 2012 at 09:43:54 +0100, Daniel P. Berrange wrote: On Wed, Jun 13, 2012 at 10:40:48AM +0200, Jiri Denemark wrote: On Wed, Jun 13, 2012 at 09:30:30 +0100, Daniel P. Berrange wrote: On Wed, Jun 13, 2012 at 01:29:20AM +0200, Jiri Denemark wrote: Normally, when every call has

Re: [libvirt] [PATCH 02/12] client rpc: Use event loop for writing

2012-06-13 Thread Daniel P. Berrange
On Wed, Jun 13, 2012 at 10:50:09AM +0200, Jiri Denemark wrote: On Wed, Jun 13, 2012 at 09:43:54 +0100, Daniel P. Berrange wrote: On Wed, Jun 13, 2012 at 10:40:48AM +0200, Jiri Denemark wrote: On Wed, Jun 13, 2012 at 09:30:30 +0100, Daniel P. Berrange wrote: On Wed, Jun 13, 2012 at

Re: [libvirt] [PATCH 11/12] server rpc: Remove APIs for manipulating filters on locked client

2012-06-13 Thread Daniel P. Berrange
On Wed, Jun 13, 2012 at 01:29:29AM +0200, Jiri Denemark wrote: We don't need to add or remove filters when client object is already locked anymore. There's no reason to keep the *Locked variants of those APIs. --- src/rpc/virnetserverclient.c | 39 ---

Re: [libvirt] [PATCH 10/12] rpc: Remove unused parameter in virKeepAliveStopInternal

2012-06-13 Thread Daniel P. Berrange
On Wed, Jun 13, 2012 at 01:29:28AM +0200, Jiri Denemark wrote: The previous commit removed the only usage of ``all'' parameter in virKeepAliveStopInternal, which was actually the only reason for having virKeepAliveStopInternal. This effectively reverts most of commit

Re: [libvirt] [PATCH 12/12] client rpc: Send keepalive requests from IO event loop

2012-06-13 Thread Daniel P. Berrange
On Wed, Jun 13, 2012 at 01:29:30AM +0200, Jiri Denemark wrote: In addition to keepalive responses, we also need to send keepalive requests from client IO loop to properly detect dead connection in case a libvirt API call is called from the main loop, which prevents any timers to be called.

Re: [libvirt] [PATCHv3 02/12] virsh: add support for virConnectListAllDomains and clean up cmdList

2012-06-13 Thread Peter Krempa
On 06/11/12 22:16, Eric Blake wrote: On 06/11/2012 04:33 AM, Peter Krempa wrote: This patch makes use of the newly added api virConnectListAllDomains() to list domains in virsh. Virsh now represents lists of domains using an internal structure vshDomainList. This structure contains the

Re: [libvirt] [PATCH 05/12] client rpc: Drop unused return value of virNetClientSendNonBlock

2012-06-13 Thread Daniel P. Berrange
On Wed, Jun 13, 2012 at 01:29:23AM +0200, Jiri Denemark wrote: As we never drop non-blocking calls, the return value that used to indicate a call was dropped is no longer needed. --- src/rpc/virnetclient.c | 19 ++- 1 file changed, 10 insertions(+), 9 deletions(-) ACK

Re: [libvirt] [PATCH 04/12] client rpc: Just queue non-blocking call if another thread has the buck

2012-06-13 Thread Daniel P. Berrange
On Wed, Jun 13, 2012 at 01:29:22AM +0200, Jiri Denemark wrote: As non-blocking calls are no longer dropped, we don't really need to care that much about their faith and wait for the thread with the buck ITYM to s/faith/fate/ ? to process them. If another thread has the buck, we can just push

Re: [libvirt] [PATCH 03/12] client rpc: Don't drop non-blocking calls

2012-06-13 Thread Daniel P. Berrange
On Wed, Jun 13, 2012 at 01:29:21AM +0200, Jiri Denemark wrote: So far, we were dropping non-blocking calls whenever sending them would block. In case a client is sending lots of stream calls (which are not supposed to generate any reply), the assumption that having other calls in a queue is

Re: [libvirt] [PATCH] build: silence gettext warning

2012-06-13 Thread Michal Privoznik
On 13.06.2012 05:47, Eric Blake wrote: Otherwise, 'make dist' gives multiple warnings like: libvirt.pot:20814: warning: internationalized messages should not contain the `\r' escape sequence * tools/virsh.c (vshAskReedit): Avoid \r in _(). --- Pushing under the trivial rule.

Re: [libvirt] [PATCH 06/12] rpc: Refactor keepalive timer code

2012-06-13 Thread Daniel P. Berrange
On Wed, Jun 13, 2012 at 01:29:24AM +0200, Jiri Denemark wrote: The code that needs to be run every keepalive interval of inactivity was only called from a timer and thus from the main event loop. We will need to call the code directly from another place. --- src/rpc/virkeepalive.c | 57

Re: [libvirt] [PATCH 07/12] rpc: Add APIs for direct triggering of keepalive timer

2012-06-13 Thread Daniel P. Berrange
On Wed, Jun 13, 2012 at 01:29:25AM +0200, Jiri Denemark wrote: Add virKeepAliveTimeout and virKeepAliveTrigger APIs that can be used to set poll timeouts and trigger keepalive timer. virKeepAliveTrigger checks if it is called to early and does nothing in that case. --- src/rpc/virkeepalive.c

Re: [libvirt] [PATCH 08/12] client rpc: Separate call creation from running IO loop

2012-06-13 Thread Daniel P. Berrange
On Wed, Jun 13, 2012 at 01:29:26AM +0200, Jiri Denemark wrote: This makes it possible to create and queue new calls while we are running IO loop. --- src/rpc/virnetclient.c | 85 ++-- 1 file changed, 54 insertions(+), 31 deletions(-) ACK

Re: [libvirt] [PATCH 09/12] rpc: Do not use timer for sending keepalive responses

2012-06-13 Thread Daniel P. Berrange
On Wed, Jun 13, 2012 at 01:29:27AM +0200, Jiri Denemark wrote: When a libvirt API is called from the main event loop (which seems to be common in event-based glib apps), the client IO loop would properly handle keepalive requests sent by a server but will not actually send them because the

Re: [libvirt] [PATCH 00/12] rpc: Fix several issues with keepalive messages

2012-06-13 Thread Daniel P. Berrange
On Wed, Jun 13, 2012 at 01:29:18AM +0200, Jiri Denemark wrote: So far, we were dropping non-blocking calls whenever sending them would block. In case a client is sending lots of stream calls (which are not supposed to generate any reply), the assumption that having other calls in a queue is

[libvirt] [PATCH] virsh: Honor reedit opts printing to a function

2012-06-13 Thread Michal Privoznik
When printing reedit options we make stdin raw. However, this results in stdout being raw as well. Therefore we need to return carriage when doing new line. Unfortunately, '\r' cannot be part of internationalized messages hence we must move them to formatting string which then in turn become huge

[libvirt] [RFC] Filtering SG_IO commands using cgroups

2012-06-13 Thread Paolo Bonzini
While we wait for Al's answer, it seems to me that filtering CDBs with cgroups is a pretty natural extension of filtering devices with cgroups. So here is a possible specification for such a cgroup. [CCing the libvirt mailing list since they could be one of the first clients] Paolo SG_IO

Re: [libvirt] [PATCH 2/8] snapshot: expose new flags in virsh

2012-06-13 Thread Peter Krempa
On 06/10/12 05:37, Eric Blake wrote: Previously, to get the name of all snapshots with children, it was necessary to get the name of all snapshots and then remove the name of leaf snapshots. This is racy, and somewhat inefficient compared to planned API additions. We can emulate --no-metadata

Re: [libvirt] [Qemu-devel] [PATCH v2 0/4] file descriptor passing using passfd

2012-06-13 Thread Kevin Wolf
Am 08.06.2012 17:42, schrieb Corey Bryant: libvirt's sVirt security driver provides SELinux MAC isolation for Qemu guest processes and their corresponding image files. In other words, sVirt uses SELinux to prevent a QEMU process from opening files that do not belong to it. sVirt provides

Re: [libvirt] [Qemu-devel] [PATCH v2 4/4] block: Convert open calls to qemu_open

2012-06-13 Thread Kevin Wolf
Am 08.06.2012 17:42, schrieb Corey Bryant: This patch converts all block layer open calls to qemu_open. This enables all block layer open paths to dup(X) a pre-opened file descriptor if the filename is of the format /dev/fd/X. This is useful if QEMU is restricted from opening certain files.

Re: [libvirt] [PATCH 3/8] list: add virDomainListAllSnapshots API

2012-06-13 Thread Peter Krempa
On 06/10/12 05:37, Eric Blake wrote: There was an inherent race between virDomainSnapshotNum() and virDomainSnapshotListNames(), where an additional snapshot could be created in the meantime, or where a snapshot could be deleted before converting the name back to a virDomainSnapshotPtr. It was

Re: [libvirt] [PATCH] virsh: Honor reedit opts printing to a function

2012-06-13 Thread Eric Blake
On 06/13/2012 03:54 AM, Michal Privoznik wrote: When printing reedit options we make stdin raw. However, this results in stdout being raw as well. Therefore we need to return carriage when doing new line. Unfortunately, '\r' cannot be part of internationalized messages hence we must move them

Re: [libvirt] [PATCH] build: fix 'make dist' on virgin checkout

2012-06-13 Thread Eric Blake
On 06/12/2012 10:39 PM, Eric Blake wrote: 'make dist' was depending on *protocol-structs files, which are stored in git but in turn depended on generated files. We still want to ship the protocol-structs files, but by renaming the tests to something not matching a file name, we separate 'make

Re: [libvirt] [PATCH 3/8] list: add virDomainListAllSnapshots API

2012-06-13 Thread Eric Blake
On 06/13/2012 05:55 AM, Peter Krempa wrote: On 06/10/12 05:37, Eric Blake wrote: There was an inherent race between virDomainSnapshotNum() and virDomainSnapshotListNames(), where an additional snapshot could be created in the meantime, or where a snapshot could be deleted before converting

Re: [libvirt] [PATCH 2/3 v5] qemu: allow the client to choose the vmcore's format

2012-06-13 Thread Martin Kletzander
On 06/12/2012 05:06 AM, Wen Congyang wrote: This patch updates qemu driver to allow the client to choose the vmcore's format: memory only or including device state. --- include/libvirt/libvirt.h.in |1 + src/qemu/qemu_capabilities.c |5 +++ src/qemu/qemu_capabilities.h |1 +

Re: [libvirt] [PATCH 1/3 v5] qemu: implement qemu's dump-guest-memory

2012-06-13 Thread Martin Kletzander
On 06/12/2012 05:04 AM, Wen Congyang wrote: dump-guest-memory is a new dump mechanism, and it can work when the guest uses host devices. This patch adds a API to use this new monitor command. We will always use json mode if qemu's version is = 0.15, so I don't implement the API for text mode.

Re: [libvirt] [PATCH 3/3 v5] virsh: allow the user to specify vmcore's format

2012-06-13 Thread Martin Kletzander
On 06/12/2012 05:07 AM, Wen Congyang wrote: Add a new parameter --memory-only for 'virsh dump' command. So the user can decide the vmcore's format. --- tools/virsh.c |3 +++ tools/virsh.pod |5 - 2 files changed, 7 insertions(+), 1 deletions(-) diff --git a/tools/virsh.c

Re: [libvirt] [PATCH 2/3 v5] qemu: allow the client to choose the vmcore's format

2012-06-13 Thread Martin Kletzander
On 06/13/2012 02:57 PM, Martin Kletzander wrote: On 06/12/2012 05:06 AM, Wen Congyang wrote: This patch updates qemu driver to allow the client to choose the vmcore's format: memory only or including device state. --- include/libvirt/libvirt.h.in |1 + src/qemu/qemu_capabilities.c |

Re: [libvirt] [PATCH 00/12] rpc: Fix several issues with keepalive messages

2012-06-13 Thread Jiri Denemark
On Wed, Jun 13, 2012 at 10:54:02 +0100, Daniel P. Berrange wrote: On Wed, Jun 13, 2012 at 01:29:18AM +0200, Jiri Denemark wrote: In case a client is sending lots of stream calls (which are not supposed to generate any reply), the assumption that having other calls in a queue is sufficient

[libvirt] [sandbox]console-rpc: fix segfault on null stdin

2012-06-13 Thread Radu Caragea
If gvir_sandbox_console_attach is called with NULL as the stdin parameter it results in a segfault in the console-rpc module from libvirt-sandbox. Calling with NULL is of course useful when running something noninteractive and you don't want it to grab the stdin or pass any fd whatsoever. commit

Re: [libvirt] [PATCH] storage backend: Add sheepdog support

2012-06-13 Thread Daniel P. Berrange
On Tue, Jun 12, 2012 at 10:31:54AM +0200, Sebastian Wiedenroth wrote: Signed-off-by: Sebastian Wiedenroth wi...@frubar.net Can you fill out the commit message with some descriptive text. At least illustrate the pool XML format and the volume XML format, describe what operations are supported,

[libvirt] libvirtd stopped launching

2012-06-13 Thread Zeeshan Ali (Khattak)
Hi everyone, After I updated my libvirt repo/install from latest git master yesterday, libvirtd won't just launch for me anymore. The error in log was: 2012-06-13 11:59:47.427+: 30501: error : virStateInitialize:781 : Initialization of NWFilter state driver failed 2012-06-13

Re: [libvirt] [Qemu-devel] [PATCH v2 4/4] block: Convert open calls to qemu_open

2012-06-13 Thread Corey Bryant
On 06/13/2012 06:26 AM, Kevin Wolf wrote: Am 08.06.2012 17:42, schrieb Corey Bryant: This patch converts all block layer open calls to qemu_open. This enables all block layer open paths to dup(X) a pre-opened file descriptor if the filename is of the format /dev/fd/X. This is useful if QEMU

Re: [libvirt] [Qemu-devel] [PATCH v2 0/4] file descriptor passing using passfd

2012-06-13 Thread Corey Bryant
On 06/13/2012 06:28 AM, Kevin Wolf wrote: Am 08.06.2012 17:42, schrieb Corey Bryant: libvirt's sVirt security driver provides SELinux MAC isolation for Qemu guest processes and their corresponding image files. In other words, sVirt uses SELinux to prevent a QEMU process from opening files

Re: [libvirt] [sandbox]console-rpc: fix segfault on null stdin

2012-06-13 Thread Daniel P. Berrange
On Wed, Jun 13, 2012 at 04:47:34PM +0300, Radu Caragea wrote: If gvir_sandbox_console_attach is called with NULL as the stdin parameter it results in a segfault in the console-rpc module from libvirt-sandbox. Calling with NULL is of course useful when running something noninteractive and you

[libvirt] [libvirt-glib] build: allow building with newer glibc-headers and -O0

2012-06-13 Thread Christophe Fergeau
Commit log and autoconf snippet written by Eric Blake for libvirt. glibc 2.15 (on Fedora 17) coupled with explicit disabling of optimization during development dies a painful death: In file included from /usr/include/limits.h:27:0, from

Re: [libvirt] [libvirt-glib] build: allow building with newer glibc-headers and -O0

2012-06-13 Thread Daniel P. Berrange
On Wed, Jun 13, 2012 at 05:02:44PM +0200, Christophe Fergeau wrote: Commit log and autoconf snippet written by Eric Blake for libvirt. glibc 2.15 (on Fedora 17) coupled with explicit disabling of optimization during development dies a painful death: In file included from

Re: [libvirt] [PATCH] storage backend: Add sheepdog support

2012-06-13 Thread Sebastian Wiedenroth
Am 13.06.2012 um 15:52 schrieb Daniel P. Berrange: On Tue, Jun 12, 2012 at 10:31:54AM +0200, Sebastian Wiedenroth wrote: + +cmd = virCommandNew(COLLIE); +virCommandAddArgList(cmd, vdi, list, vol-name, -r, NULL); +virStorageBackendSheepdogAddHostArg(cmd, pool); +

[libvirt] [PATCH] build: hoist qemu dependence on yajl to configure

2012-06-13 Thread Eric Blake
Commit 6e769eba made it a runtime error if libvirt was compiled without yajl support but targets a new enough qemu. But enough users are hitting this on self-compiled libvirt that it is worth erroring out at compilation time, rather than an obscure failure when trying to use the built executable.

Re: [libvirt] [PATCH] build: hoist qemu dependence on yajl to configure

2012-06-13 Thread Eric Blake
On 06/13/2012 11:00 AM, Eric Blake wrote: Commit 6e769eba made it a runtime error if libvirt was compiled without yajl support but targets a new enough qemu. But enough users are hitting this on self-compiled libvirt that it is worth erroring out at compilation time, rather than an obscure

Re: [libvirt] Website sidebar not consistent between libvirt.org and wiki.libvirt.org

2012-06-13 Thread Cole Robinson
On 05/29/2012 05:52 PM, Cole Robinson wrote: The sidebar here looks right: http://libvirt.org/ But the sidebar here seems pretty out of date: http://wiki.libvirt.org/ Including missing options, and the FAQ link pointing to the old FAQ.html file which shouldn't exist anymore. Any

Re: [libvirt] [Qemu-devel] [PATCH v2 1/4] qapi: Convert getfd and closefd

2012-06-13 Thread Luiz Capitulino
On Fri, 8 Jun 2012 11:42:56 -0400 Corey Bryant cor...@linux.vnet.ibm.com wrote: v2: - Convert getfd and closefd to QAPI (lcapitul...@redhat.com) - Remove changes that returned fd from getfd (lcapitul...@redhat.com) - Wrap hmp_* functions around qmp_* functions (kw...@redhat.com) - Move

Re: [libvirt] [Qemu-devel] [PATCH v2 1/4] qapi: Convert getfd and closefd

2012-06-13 Thread Luiz Capitulino
On Fri, 8 Jun 2012 11:42:56 -0400 Corey Bryant cor...@linux.vnet.ibm.com wrote: v2: - Convert getfd and closefd to QAPI (lcapitul...@redhat.com) - Remove changes that returned fd from getfd (lcapitul...@redhat.com) - Wrap hmp_* functions around qmp_* functions (kw...@redhat.com) - Move

Re: [libvirt] [Qemu-devel] [PATCH v2 2/4] qapi: Add passfd QMP command

2012-06-13 Thread Luiz Capitulino
On Fri, 8 Jun 2012 11:42:57 -0400 Corey Bryant cor...@linux.vnet.ibm.com wrote: This patch adds the passfd QMP command using the QAPI framework. Like the getfd command, it is used to pass a file descriptor via SCM_RIGHTS. However, the passfd command also returns the received file

Re: [libvirt] [PATCH] network: fully support/use VIR_NETWORK_XML_INACTIVE flag

2012-06-13 Thread Laine Stump
On 06/11/2012 05:06 PM, Eric Blake wrote: On 06/11/2012 02:54 PM, Laine Stump wrote: commit 52d064f42dbc857f4096dc60c0335395ffac73aa added VIR_NETWORK_XML_INACTIVE in order to allow suppressing the auto-generated list of VFs in network definitions, and a --inactive flag to virsh net-dumpxml

Re: [libvirt] [Qemu-devel] [PATCH v2 1/4] qapi: Convert getfd and closefd

2012-06-13 Thread Corey Bryant
On 06/13/2012 03:42 PM, Luiz Capitulino wrote: On Fri, 8 Jun 2012 11:42:56 -0400 Corey Bryant cor...@linux.vnet.ibm.com wrote: v2: - Convert getfd and closefd to QAPI (lcapitul...@redhat.com) - Remove changes that returned fd from getfd (lcapitul...@redhat.com) - Wrap hmp_* functions

Re: [libvirt] [Qemu-devel] [PATCH v2 2/4] qapi: Add passfd QMP command

2012-06-13 Thread Corey Bryant
On 06/13/2012 03:46 PM, Luiz Capitulino wrote: On Fri, 8 Jun 2012 11:42:57 -0400 Corey Bryant cor...@linux.vnet.ibm.com wrote: This patch adds the passfd QMP command using the QAPI framework. Like the getfd command, it is used to pass a file descriptor via SCM_RIGHTS. However, the passfd

Re: [libvirt] [Qemu-devel] [PATCH v2 1/4] qapi: Convert getfd and closefd

2012-06-13 Thread Eric Blake
On 06/13/2012 02:17 PM, Corey Bryant wrote: On 06/13/2012 03:42 PM, Luiz Capitulino wrote: On Fri, 8 Jun 2012 11:42:56 -0400 Corey Bryant cor...@linux.vnet.ibm.com wrote: v2: - Convert getfd and closefd to QAPI (lcapitul...@redhat.com) - Remove changes that returned fd from getfd

Re: [libvirt] [Qemu-devel] [PATCH v2 2/4] qapi: Add passfd QMP command

2012-06-13 Thread Eric Blake
On 06/13/2012 02:25 PM, Corey Bryant wrote: Also, getfd automatically closes a fd if an existing fdname is passed again. I don't think this is a good behavior, I think pass-fd should fail instead (note that we can't fix getfd though). I agree. It makes sense to fail rather than blindly

Re: [libvirt] [Qemu-devel] [PATCH v2 1/4] qapi: Convert getfd and closefd

2012-06-13 Thread Corey Bryant
On 06/13/2012 04:41 PM, Eric Blake wrote: On 06/13/2012 02:17 PM, Corey Bryant wrote: On 06/13/2012 03:42 PM, Luiz Capitulino wrote: On Fri, 8 Jun 2012 11:42:56 -0400 Corey Bryant cor...@linux.vnet.ibm.com wrote: v2: - Convert getfd and closefd to QAPI (lcapitul...@redhat.com) -

Re: [libvirt] [Qemu-devel] [PATCH v2 2/4] qapi: Add passfd QMP command

2012-06-13 Thread Corey Bryant
On 06/13/2012 04:47 PM, Eric Blake wrote: On 06/13/2012 02:25 PM, Corey Bryant wrote: Also, getfd automatically closes a fd if an existing fdname is passed again. I don't think this is a good behavior, I think pass-fd should fail instead (note that we can't fix getfd though). I agree. It

Re: [libvirt] [PATCH 5/6] snapshot: new virsh function factored from snapshot-list

2012-06-13 Thread Eric Blake
On 06/12/2012 06:42 PM, Eric Blake wrote: I really need to list this as a comment. I'll post a v2, adding comments and including your improvements. Here's what I'll squash for my v2: +/* First, determine if we can use the new child listing API. */ +if

Re: [libvirt] [PATCHv3 06/12] conf: Add helper for listing domains on drivers supporting virDomainObj

2012-06-13 Thread Eric Blake
On 06/11/2012 04:34 AM, Peter Krempa wrote: This patch adds common code to list domains in fashion used by virListAllDomains with all currently supported flags. The header file also contains macros that group filters together that are used to shorten filter conditions. --- Diff to v2:

[libvirt] [PATCH 10/8] list: add qemu snapshot list support

2012-06-13 Thread Eric Blake
The two new functions are very similar to the existing functions; just a matter of different arguments and a call to a different helper function. * src/qemu/qemu_driver.c (qemuDomainSnapshotListNames) (qemuDomainSnapshotNum, qemuDomainSnapshotListChildrenNames) (qemuDomainSnapshotNumChildren):

[libvirt] [PATCH 8/8] snapshot: merge domain and snapshot computation

2012-06-13 Thread Eric Blake
Now that domain listing is a thin wrapper around child listing, it's easier to have a common entry point. This restores the hashForEach optimization lost in the previous patch when there are no snapshots being filtered out of the entire list. * src/conf/domain_conf.h

[libvirt] [PATCH 9/8] list: new helper function to collect snapshots

2012-06-13 Thread Eric Blake
Wraps the conversion from 'char *name' to virDomainSnapshotPtr in a reusable manner. * src/conf/virdomainlist.h (virDomainListSnapshots): New declaration. * src/conf/virdomainlist.c (virDomainListSnapshots): Implement it. * src/libvirt_private.syms (virdomainlist.h): Export it. --- Assume's

[libvirt] [PATCH 7/8] snapshot: use metaroot node to simplify management

2012-06-13 Thread Eric Blake
This idea was first suggested by Daniel Veillard here: https://www.redhat.com/archives/libvir-list/2011-October/msg00353.html Now that I am about to add more complexity to snapshot listing, it makes sense to avoid code duplication and special casing for domain listing (all snapshots) vs. snapshot