Re: [libvirt] pointless time-consuming test 'virsh-all'

2012-06-07 Thread Jiri Denemark
On Thu, Jun 07, 2012 at 06:22:12 -0600, Eric Blake wrote: On 06/07/2012 02:24 AM, Martin Kletzander wrote: On 06/07/2012 05:32 AM, Eric Blake wrote: The command 'make -C tests check' takes forever, because it is calling this lengthy virsh command and ignoring the failures: $ time

[libvirt] [PATCH] util: Fix deadlock in virLogReset

2012-06-07 Thread Jiri Denemark
When libvirtd forks off a new child, the child then calls virLogReset(), which ends up closing file descriptors used as log outputs. However, we recently started logging closed file descriptors, which means we need to lock logging mutex which was already logged by virLogReset(). We don't really

Re: [libvirt] [PATCH v2] virsh: add keepalive protocol in virsh

2012-06-08 Thread Jiri Denemark
On Thu, Jun 07, 2012 at 12:03:02 -0600, Eric Blake wrote: On 06/05/2012 02:36 AM, Guannan Ren wrote: Bugzilla:https://bugzilla.redhat.com/show_bug.cgi?id=822839 add two general virsh options to support keepalive message protocol -i | --keepalive_interval interval time value (default 5

Re: [libvirt] [PATCH] add xhci support

2012-06-08 Thread Jiri Denemark
On Fri, Jun 08, 2012 at 10:19:37 +0200, Gerd Hoffmann wrote: qemu 1.1 features a xhci controller, this patch adds support for it. Signed-off-by: Gerd Hoffmann kra...@redhat.com --- src/conf/domain_conf.c |3 ++- src/conf/domain_conf.h |1 +

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

2012-06-12 Thread Jiri Denemark
by one line than the current broken version :-) Jiri Denemark (12): client rpc: Improve debug messages in virNetClientIO client rpc: Use event loop for writing client rpc: Don't drop non-blocking calls client rpc: Just queue non-blocking call if another thread has the buck client rpc

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

2012-06-12 Thread Jiri Denemark
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 to process them. If another thread has the buck, we can just push a non-blocking call to the queue and be done with it. --- src/rpc/virnetclient.c | 74

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

2012-06-12 Thread Jiri Denemark
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 sufficient to get a reply from the server doesn't work. I tried to

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

2012-06-12 Thread Jiri Denemark
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 | 61

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

2012-06-12 Thread Jiri Denemark
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(-) diff --git a/src/rpc/virnetclient.c b/src/rpc/virnetclient.c index 14f806f..c62e045 100644

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

2012-06-12 Thread Jiri Denemark
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 +--- 1 file changed, 35

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

2012-06-12 Thread Jiri Denemark
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(-) diff --git a/src/rpc/virnetclient.c b/src/rpc/virnetclient.c index

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

2012-06-12 Thread Jiri Denemark
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 main event loop is blocked with the API. This patch gets rid of

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

2012-06-12 Thread Jiri Denemark
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(-) diff --git a/src/rpc/virnetclient.c b/src/rpc/virnetclient.c index

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

2012-06-12 Thread Jiri Denemark
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 6446a9e20cc65561ce6061742baf35a3a63d5ba1. --- src/libvirt_probes.d |2 +-

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

2012-06-12 Thread Jiri Denemark
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 non-blocking calls. This patch uses event loop to send data if there

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

2012-06-12 Thread Jiri Denemark
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 --- 1 file changed, 12 insertions(+), 27 deletions(-) diff --git

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

2012-06-12 Thread Jiri Denemark
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. --- src/rpc/virnetclient.c | 12 1 file changed, 12

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 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 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

Re: [libvirt] [PATCH 01/15] Add a opaque parameter to the RPC client init callback

2012-07-04 Thread Jiri Denemark
On Tue, Jul 03, 2012 at 16:58:40 +0100, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com The callback that is invoked when a new RPC client is initialized does not have any opaque parameter. Add one so that custom data can be passed into the callback Signed-off-by:

Re: [libvirt] [PATCH 03/15] Avoid build shared source files again for libvirt_lxc

2012-07-04 Thread Jiri Denemark
On Tue, Jul 03, 2012 at 16:58:42 +0100, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com Currently the build of libvirt_lxc will cause recompilation of all sources under src/util, src/conf, src/security and more. Switch the libvirt_lxc process to link against the

Re: [libvirt] [PATCH 04/15] Introduce a virLXCControllerPtr object to hold LXC controller state

2012-07-04 Thread Jiri Denemark
On Tue, Jul 03, 2012 at 16:58:43 +0100, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com The LXC controller code is having to pass around an ever increasing number of parameters between methods. To make the code more managable introduce a virLXCControllerPtr to hold all

Re: [libvirt] [PATCH 02/15] Allow RPC server to run single threaded

2012-07-04 Thread Jiri Denemark
On Tue, Jul 03, 2012 at 16:58:41 +0100, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com Refactor the RPC server dispatcher code so that if 'max_workers==0' the entire server will run single threaded. This is useful for use cases where there will only ever be 1 client

Re: [libvirt] [PATCH 05/15] Move veth device management into virLXCControllerPtr object

2012-07-04 Thread Jiri Denemark
On Tue, Jul 03, 2012 at 16:58:44 +0100, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com Move the veth device name state into the virLXCControllerPtr object and stop passing it around. Also use size_t instead of unsigned int for the array length parameters.

Re: [libvirt] [PATCH 06/15] Store the init PID in the virLXCController object

2012-07-04 Thread Jiri Denemark
On Tue, Jul 03, 2012 at 16:58:45 +0100, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com Keep a record of the init PID in the virLXCController object and create a virLXCControllerStopInit method for killing this process Signed-off-by: Daniel P. Berrange

Re: [libvirt] [PATCH] virsh: Fix ordering of arguments when calling vshCalloc.

2012-07-04 Thread Jiri Denemark
On Wed, Jul 04, 2012 at 13:30:52 +0200, Peter Krempa wrote: On 07/04/12 12:23, Peter Krempa wrote: In vshSnapshotListCollect() vshCalloc was called with swapped nmemb and size argument. This caused division by zero in xalloc_oversized as the macro doesn't expect size to be zero. ---

Re: [libvirt] [PATCH 07/15] Make console handling part of virLXCControllerPtr

2012-07-04 Thread Jiri Denemark
On Tue, Jul 03, 2012 at 16:58:46 +0100, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com Turn 'struct lxc_console' into virLXCControllerConsolePtr and make it a part of virLXCControllerPtr Signed-off-by: Daniel P. Berrange berra...@redhat.com ---

Re: [libvirt] [PATCH 08/15] Move daemon handshake FD into virLXCControllerPtr

2012-07-04 Thread Jiri Denemark
On Tue, Jul 03, 2012 at 16:58:47 +0100, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com Keep the FD uses to handshake with the libvirtd daemon in the s/uses/used/ virLXCControllerPtr object. Signed-off-by: Daniel P. Berrange berra...@redhat.com ---

Re: [libvirt] [PATCH 09/15] Move loop device FDs into virLXCControllerPtr object

2012-07-04 Thread Jiri Denemark
On Tue, Jul 03, 2012 at 16:58:48 +0100, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com Move the list of loop device FDs into the virLXCControllerPtr object and make sure that virLXCControllerStopInit will close them all Signed-off-by: Daniel P. Berrange

Re: [libvirt] [PATCH 10/15] Move security manager into virLXCControllerPtr object

2012-07-04 Thread Jiri Denemark
On Tue, Jul 03, 2012 at 16:58:49 +0100, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com Move the security manager object into the virLXCControllerPtr object. Also simplify the code creating it in the first place Signed-off-by: Daniel P. Berrange berra...@redhat.com

Re: [libvirt] [PATCH 11/15] Move /dev/pts setup out of virLXCControllerRun

2012-07-04 Thread Jiri Denemark
On Tue, Jul 03, 2012 at 16:58:50 +0100, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com The virLXCControllerRun method is getting a little too large, and about 50% of its code is related to setting up a /dev/pts mount. Move the latter out into a dedicated method

Re: [libvirt] [PATCH 12/15] Move monitor into virLXCControllerPtr

2012-07-04 Thread Jiri Denemark
On Tue, Jul 03, 2012 at 16:58:51 +0100, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com Move the monitor FDs into the virLXCControllerPtr object removing the need for the 'struct lxcMonitor' object Signed-off-by: Daniel P. Berrange berra...@redhat.com ---

Re: [libvirt] [PATCH 14/15] Move loop device setup code into virfile.{c, h}

2012-07-04 Thread Jiri Denemark
On Tue, Jul 03, 2012 at 16:58:53 +0100, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com While it is not currently used elsewhere in libvirt, the code for finding a free loop device associating a file with it is not LXC specific. Move it into the viffile.{c,h} file

Re: [libvirt] [PATCH 13/15] Move cgroup objects into virLXCControllerPtr

2012-07-04 Thread Jiri Denemark
On Tue, Jul 03, 2012 at 16:58:52 +0100, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com Move the cgroup object into virLXCControllerPtr and rename all the setup methods to include 'Cgroup' in their name if appropriate Signed-off-by: Daniel P. Berrange

Re: [libvirt] [PATCH 15/15] Switch to using virNetServer APIs for monitor socket

2012-07-04 Thread Jiri Denemark
On Tue, Jul 03, 2012 at 16:58:54 +0100, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com In preparation for introducing a full RPC protocol for libvirt_lxc, switch over to using the virNetServer APIs for the monitor connection Signed-off-by: Daniel P. Berrange

Re: [libvirt] [PATCH RESEND] add xhci support

2012-07-09 Thread Jiri Denemark
On Mon, Jul 09, 2012 at 14:18:58 +0200, Gerd Hoffmann wrote: qemu 1.1 features a xhci controller, this patch adds support for it. Signed-off-by: Gerd Hoffmann kra...@redhat.com --- docs/formatdomain.html.in |4 ++-- docs/schemas/domaincommon.rng |1 + src/conf/domain_conf.c

Re: [libvirt] [PATCH] docs: added description of the vendor_id attribute

2012-07-10 Thread Jiri Denemark
I know I'm late in this vendor_id stuff but it hasn't been released yet so I'm not too late. I assume the reason for introducing it is to be able to lie to a guest. Please, correct me, if this is not the case. diff --git a/docs/formatdomain.html.in b/docs/formatdomain.html.in index

Re: [libvirt] [PATCH] docs: added description of the vendor_id attribute

2012-07-11 Thread Jiri Denemark
On Wed, Jul 11, 2012 at 09:00:05 +0200, Hendrik Schwartke wrote: On 10.07.2012 21:57, Jiri Denemark wrote: I know I'm late in this vendor_id stuff but it hasn't been released yet so I'm not too late. I assume the reason for introducing it is to be able to lie to a guest. Please

[libvirt] [PATCH] qemu: Do not fail virConnectCompareCPU if host CPU is not known

2012-07-12 Thread Jiri Denemark
When host CPU could not be properly detected, virConnectCompareCPU will just report that any CPU is incompatible with host CPU instead of failing. --- src/qemu/qemu_driver.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/qemu/qemu_driver.c b/src/qemu/qemu_driver.c

[libvirt] [PATCH] Clarify direct migration

2012-07-12 Thread Jiri Denemark
When --direct is used when migrating a domain running on a hypervisor that does not support direct migration (such as QEMU), the caller would get the following error message: this function is not supported by the connection driver: virDomainMigrateToURI2 which is a complete nonsense

Re: [libvirt] [PATCH] ARMHF: CPU Support for armhf.

2012-07-12 Thread Jiri Denemark
On Thu, Jul 12, 2012 at 10:58:12 -0400, Chuck Short wrote: Adding CPU encoder/decoder for armhf to avoid runtime error messages. Can you be more specific about the error messages you are trying to fix with this patch? Signed-off-by: Chuck Short chuck.sh...@canonical.com --- src/Makefile.am

Re: [libvirt] [PATCH] ARMHF: CPU Support for armhf.

2012-07-13 Thread Jiri Denemark
On Thu, Jul 12, 2012 at 13:39:02 -0500, Chuck Short wrote: Adding CPU encoder/decoder for armhf to avoid runtime error messages. I would still be interested in the exact error messages you get when you try to start a domain on an arm machine without this patch :-) Jirka -- libvir-list mailing

Re: [libvirt] [PATCH] Clarify direct migration

2012-07-13 Thread Jiri Denemark
On Thu, Jul 12, 2012 at 13:43:26 -0600, Eric Blake wrote: On 07/12/2012 08:23 AM, Jiri Denemark wrote: When --direct is used when migrating a domain running on a hypervisor that does not support direct migration (such as QEMU), the caller would get the following error message

[libvirt] [PATCH] qemu: Fix probing for guest capabilities

2012-07-13 Thread Jiri Denemark
Even though qemu-kvm binaries can be used in TCG mode, libvirt would only detect them if /dev/kvm was available. Thus, one would need to make a /usr/bin/qemu symlink to be able to use TCG mode with qemu-kvm in an environment without KVM support. And even though QEMU is able to make use of KVM,

Re: [libvirt] [PATCH] qemu: Fix probing for guest capabilities

2012-07-16 Thread Jiri Denemark
On Fri, Jul 13, 2012 at 09:19:42 -0600, Eric Blake wrote: On 07/13/2012 09:00 AM, Jiri Denemark wrote: Even though qemu-kvm binaries can be used in TCG mode, libvirt would only detect them if /dev/kvm was available. Thus, one would need to make a /usr/bin/qemu symlink to be able to use TCG

Re: [libvirt] [PATCH] qemu: Do not fail virConnectCompareCPU if host CPU is not known

2012-07-16 Thread Jiri Denemark
On Sat, Jul 14, 2012 at 23:31:52 +0300, Dan Kenigsberg wrote: On Thu, Jul 12, 2012 at 01:06:08PM +0200, Jiri Denemark wrote: When host CPU could not be properly detected, virConnectCompareCPU will just report that any CPU is incompatible with host CPU instead of failing. --- src/qemu

Re: [libvirt] [PATCH] ARMHF: CPU Support for armhf.

2012-07-16 Thread Jiri Denemark
On Fri, Jul 13, 2012 at 11:58:23 -0400, Chuck Short wrote: On Fri, 13 Jul 2012 09:14:47 +0200 Jiri Denemark jdene...@redhat.com wrote: On Thu, Jul 12, 2012 at 13:39:02 -0500, Chuck Short wrote: Adding CPU encoder/decoder for armhf to avoid runtime error messages. I would still

[libvirt] [PATCH] xenapi: Convert to virMacAddr

2012-07-17 Thread Jiri Denemark
--- Can't we just get rid of this horrific and mostly unmaintained xenapi code completely? :-) src/xenapi/xenapi_driver.c | 3 ++- src/xenapi/xenapi_utils.c | 36 ++-- 2 files changed, 16 insertions(+), 23 deletions(-) diff --git a/src/xenapi/xenapi_driver.c

Re: [libvirt] [PATCH] xenapi: Convert to virMacAddr

2012-07-17 Thread Jiri Denemark
On Tue, Jul 17, 2012 at 09:47:13 -0600, Eric Blake wrote: On 07/17/2012 09:24 AM, Jiri Denemark wrote: --- Can't we just get rid of this horrific and mostly unmaintained xenapi code completely? :-) Wouldn't it be nice? That may be a question worth asking on the announce list, to see

[libvirt] [PATCH] remote: Fix locking in stream APIs

2012-07-17 Thread Jiri Denemark
Remote driver needs to make sure the driver lock is released before entering client IO loop as that may block indefinitely in poll(). As a direct consequence of not following this in stream APIs, tunneled migration to a destination host which becomes non-responding may block qemu driver. Luckily,

Re: [libvirt] [PATCH] remote: Fix locking in stream APIs

2012-07-18 Thread Jiri Denemark
On Wed, Jul 18, 2012 at 09:46:12 +0200, Michal Privoznik wrote: On 17.07.2012 19:30, Jiri Denemark wrote: Remote driver needs to make sure the driver lock is released before entering client IO loop as that may block indefinitely in poll(). As a direct consequence of not following

Re: [libvirt] [PATCH 03/16] Add callback to virNetClient to be invoked on EOF

2012-07-19 Thread Jiri Denemark
On Wed, Jul 18, 2012 at 17:32:24 +0100, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com Allow detection of EOF in virNetClient via an callback function, triggered from the socket event handler EOF callback is nice but since we have keepalive, sockets can also be closed

Re: [libvirt] [PATCH 05/23] Replace use of virCPUReportError with virReportError

2012-07-19 Thread Jiri Denemark
On Wed, Jul 18, 2012 at 19:40:41 +0100, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com Update the CPU helper APIs to use virReportError instead of the virCPUReportError custom macor Signed-off-by: Daniel P. Berrange berra...@redhat.com --- cfg.mk|

Re: [libvirt] [PATCH 07/23] Replace use of XENXS_ERROR with virReportError

2012-07-19 Thread Jiri Denemark
On Wed, Jul 18, 2012 at 19:40:43 +0100, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com Update the XenXS shared code to use virReportError instead of the XENXS_ERROR custom macro Signed-off-by: Daniel P. Berrange berra...@redhat.com --- cfg.mk|

Re: [libvirt] [PATCH 09/23] Replace use of libxlError with virReportError

2012-07-20 Thread Jiri Denemark
On Wed, Jul 18, 2012 at 19:40:45 +0100, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com Update the libxl driver to use virReportError instead of the libxlError custom macro Signed-off-by: Daniel P. Berrange berra...@redhat.com --- cfg.mk |1 -

Re: [libvirt] [PATCH 11/23] Replace use of virLockError with virReportError

2012-07-20 Thread Jiri Denemark
On Wed, Jul 18, 2012 at 19:40:47 +0100, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com Update the lock manager drivers to use virReportError instead of the virLockError custom macro Signed-off-by: Daniel P. Berrange berra...@redhat.com ---

Re: [libvirt] [PATCH 02/50] list: Expose pool type via virStoragePoolGetInfo

2012-07-20 Thread Jiri Denemark
On Fri, Jul 20, 2012 at 00:40:33 +0800, Osier Yang wrote: Mainly for later patches' use, to filter the pools by pool type. include/libvirt/libvirt.h.in: Add enum virStoragePoolType; Add pool type to virStoragePoolInfo. src/conf/storage_conf.h: Remove enum virStoragePoolType.

Re: [libvirt] [PATCH 02/50] list: Expose pool type via virStoragePoolGetInfo

2012-07-20 Thread Jiri Denemark
On Fri, Jul 20, 2012 at 21:10:57 +0800, Osier Yang wrote: On 2012年07月20日 21:01, Daniel P. Berrange wrote: On Fri, Jul 20, 2012 at 09:00:21PM +0800, Osier Yang wrote: On 2012年07月20日 20:44, Daniel P. Berrange wrote: Fortunately no other part of this patch series appears to rely on this

Re: [libvirt] Preferred CPU model not allowed by hypervisor

2012-07-23 Thread Jiri Denemark
Hi, On Sat, Jul 21, 2012 at 04:46:18 -0500, Jared wrote: I'm having a weird problem where libvirt/qemu/kvm won't let me use the model processor I have defined in my domain's config file. Instead, I get the error message in libvirtd.log that: warning : x86Decode:1346 : Preferred CPU model

Re: [libvirt] Mutt patch colour highlighting

2012-07-23 Thread Jiri Denemark
On Fri, Jul 20, 2012 at 16:55:22 +0100, Daniel P. Berrange wrote: On Fri, Jul 20, 2012 at 09:46:42AM -0600, Eric Blake wrote: One remark up there, but no biggie. I had to hunt for that remark among 70k of verbatim patch. Not only is it okay to trim portions of the patch that you are

[libvirt] [PATCH] tests: More unit tests for internal hash APIs

2011-04-19 Thread Jiri Denemark
This adds several tests for remaining hash APIs (custom hasher/comparator functions are not covered yet, though). All tests pass both before and after the Simplify hash implementation. --- src/util/hash.c | 18 +++ src/util/hash.h |1 + tests/hashdata.h | 237

[libvirt] [PATCH] Remove artificial minimum limit for guest memory

2011-04-21 Thread Jiri Denemark
Remove the artificial minimum of 4096 KB for guest memory. It's drivers' job to set the limit if needed. --- src/libvirt.c |6 +++--- 1 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/libvirt.c b/src/libvirt.c index 9e6784b..10c3cdf 100644 --- a/src/libvirt.c +++

Re: [libvirt] [PATCH] Remove artificial minimum limit for guest memory

2011-04-21 Thread Jiri Denemark
On Thu, Apr 21, 2011 at 06:40:58 -0600, Eric Blake wrote: On 04/21/2011 06:21 AM, Jiri Denemark wrote: Remove the artificial minimum of 4096 KB for guest memory. It's drivers' job to set the limit if needed. --- src/libvirt.c |6 +++--- 1 files changed, 3 insertions(+), 3 deletions

Re: [libvirt] [PATCH] Fix disability to run on systems with no PCI bus

2011-04-22 Thread Jiri Denemark
On Fri, Apr 22, 2011 at 09:58:38 +0200, Michal Privoznik wrote: The patch which moved libpciaccess initialization to one place caused regression - we were not able to run on system with no PCI bus, like s390(x). This patch fix it. --- src/node_device/node_device_udev.c |6 ++ 1

Re: [libvirt] [PATCH] Make the options --crash and --live of virsh dump mutually exclusive

2011-04-22 Thread Jiri Denemark
This patch makes the options --crash and --live of virsh dump mutually exclusive diff --git a/tools/virsh.c b/tools/virsh.c index 2e35021..ef77d7f 100644 --- a/tools/virsh.c +++ b/tools/virsh.c @@ -1869,14 +1869,19 @@ cmdDump(vshControl *ctl, const vshCmd *cmd) flags |=

Re: [libvirt] [PATCH] qemu: Add flags checking in DomainCoreDump

2011-04-26 Thread Jiri Denemark
On Fri, Apr 22, 2011 at 09:54:03 -0600, Eric Blake wrote: On 04/22/2011 04:03 AM, Jiri Denemark wrote: --- src/qemu/qemu_driver.c |5 - 1 files changed, 4 insertions(+), 1 deletions(-) diff --git a/src/qemu/qemu_driver.c b/src/qemu/qemu_driver.c index f6e503a..f35616d 100644

Re: [libvirt] [PATCH] Make the options --crash and --live of virsh dump mutually exclusive

2011-04-26 Thread Jiri Denemark
On Fri, Apr 22, 2011 at 09:57:46 -0600, Eric Blake wrote: @@ -2379,6 +2379,12 @@ virDomainCoreDump(virDomainPtr domain, const char *to, int flags) goto error; } +if ((flags VIR_DUMP_CRASH) (flags VIR_DUMP_LIVE)) { +

[libvirt] [PATCH] build: Ignore old audit library

2011-04-27 Thread Jiri Denemark
Check for audit_encode_nv_string in libaudit so that ancient audit library is ignored rather than trying to compile with libaudit support and failing. --- configure.ac |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/configure.ac b/configure.ac index 190bf40..25cc15b

[libvirt] [PATCH] build: Use pkg-config for libssh2 check

2011-04-27 Thread Jiri Denemark
Currently the build fails if /usr/local/include does not exist since its use is hardcoded in configure.ac --- configure.ac | 86 ++--- 1 files changed, 21 insertions(+), 65 deletions(-) diff --git a/configure.ac b/configure.ac index

Re: [libvirt] [PATCH] tests: More unit tests for internal hash APIs

2011-04-27 Thread Jiri Denemark
On Tue, Apr 26, 2011 at 10:11:27 -0600, Eric Blake wrote: On 04/19/2011 07:22 AM, Jiri Denemark wrote: This adds several tests for remaining hash APIs (custom hasher/comparator functions are not covered yet, though). All tests pass both before and after the Simplify hash implementation

Re: [libvirt] [PATCH v2] util: Simplify hash implementation

2011-04-27 Thread Jiri Denemark
On Tue, Apr 12, 2011 at 13:10:15 -0600, Eric Blake wrote: On 04/12/2011 11:25 AM, Jiri Denemark wrote: So far first entries for each hash key are stored directly in the hash table while other entries mapped to the same key are linked through pointers. As a result of that, the code

Re: [libvirt] [PATCH] build: Ignore old audit library

2011-04-28 Thread Jiri Denemark
On Wed, Apr 27, 2011 at 20:58:40 -0600, Eric Blake wrote: On 04/27/2011 03:25 AM, Jiri Denemark wrote: Check for audit_encode_nv_string in libaudit so that ancient audit library is ignored rather than trying to compile with libaudit support and failing. --- configure.ac |2 +- 1

Re: [libvirt] [PATCH] build: Use pkg-config for libssh2 check

2011-04-28 Thread Jiri Denemark
On Wed, Apr 27, 2011 at 20:57:52 -0600, Eric Blake wrote: On 04/27/2011 04:34 AM, Jiri Denemark wrote: Currently the build fails if /usr/local/include does not exist since its use is hardcoded in configure.ac --- configure.ac | 86

Re: [libvirt] [PATCH 1/4] Fix error messages codes when TypeFromString fails

2011-04-29 Thread Jiri Denemark
On Wed, Apr 27, 2011 at 16:57:43 +0200, Michal Privoznik wrote: --- src/conf/cpu_conf.c|4 +- src/conf/domain_conf.c | 100 ++- src/conf/interface_conf.c |2 +- src/conf/network_conf.c|2 +-

[libvirt] [PATCH 2/8] Internal driver API for virDomainGetState

2011-05-04 Thread Jiri Denemark
--- src/driver.h |5 + src/esx/esx_driver.c |1 + src/libxl/libxl_driver.c |1 + src/lxc/lxc_driver.c |1 + src/openvz/openvz_driver.c |1 + src/phyp/phyp_driver.c |1 + src/qemu/qemu_driver.c |1 + src/remote/remote_driver.c |

[libvirt] [PATCH 3/8] virDomainGetState public API implementation

2011-05-04 Thread Jiri Denemark
--- src/libvirt.c | 47 +++ 1 files changed, 47 insertions(+), 0 deletions(-) diff --git a/src/libvirt.c b/src/libvirt.c index e74e977..5cd20ce 100644 --- a/src/libvirt.c +++ b/src/libvirt.c @@ -3173,6 +3173,53 @@ error: } /** + *

[libvirt] [PATCH 0/8] Introduce virDomainGetState API

2011-05-04 Thread Jiri Denemark
the reply. In case of qemu driver, this translates to the driver being stuck in comunication with qemu monitor. I'm not sure if we should somehow integrate this into virDomainGetState API. Probably not. Jiri Denemark (8): virDomainGetState public API Internal driver API for virDomainGetState

[libvirt] [PATCH 1/8] virDomainGetState public API

2011-05-04 Thread Jiri Denemark
This API is supposed to replace virDomainGetInfo when the only purpose of calling it is getting current domain status. --- include/libvirt/libvirt.h.in| 55 +++ python/generator.py |1 + python/libvirt-override-api.xml |5 +++

[libvirt] [PATCH 5/8] virsh: Prefer virDomainGetState over virDomainGetInfo

2011-05-04 Thread Jiri Denemark
--- tools/virsh.c | 195 +++-- 1 files changed, 162 insertions(+), 33 deletions(-) diff --git a/tools/virsh.c b/tools/virsh.c index 5d8b025..6dae9fa 100644 --- a/tools/virsh.c +++ b/tools/virsh.c @@ -223,6 +223,8 @@ typedef struct __vshControl

[libvirt] [PATCH 4/8] Wire protocol format and dispatcher for virDomainGetState

2011-05-04 Thread Jiri Denemark
--- daemon/remote.c | 33 + daemon/remote_dispatch_prototypes.h |8 daemon/remote_dispatch_table.h |5 + src/remote/remote_protocol.c| 20 src/remote/remote_protocol.h| 16

[libvirt] [PATCH 6/8] remote: Implement virDomainGetState

2011-05-04 Thread Jiri Denemark
--- src/remote/remote_driver.c | 31 ++- 1 files changed, 30 insertions(+), 1 deletions(-) diff --git a/src/remote/remote_driver.c b/src/remote/remote_driver.c index 9796bb5..3baedf0 100644 --- a/src/remote/remote_driver.c +++ b/src/remote/remote_driver.c @@ -2861,6

[libvirt] [PATCH 7/8] Implement basic virDomainGetState in all drivers

2011-05-04 Thread Jiri Denemark
Reason is currently always set to 0 (i.e., *_UNKNOWN). --- src/esx/esx_driver.c | 54 - src/libxl/libxl_driver.c | 31 +- src/lxc/lxc_driver.c | 33 ++- src/openvz/openvz_driver.c | 32 ++- src/phyp/phyp_driver.c

[libvirt] [PATCH] json: Fix *GetBoolean functions

2011-05-05 Thread Jiri Denemark
They were not used anywhere so far so nobody noticed they are broken. --- src/util/json.c | 11 ++- src/util/json.h |4 ++-- 2 files changed, 8 insertions(+), 7 deletions(-) diff --git a/src/util/json.c b/src/util/json.c index 0daeae9..df4771d 100644 --- a/src/util/json.c +++

Re: [libvirt] [PATCH 1/8] virDomainGetState public API

2011-05-05 Thread Jiri Denemark
On Wed, May 04, 2011 at 10:45:33 -0600, Eric Blake wrote: On 05/04/2011 08:45 AM, Jiri Denemark wrote: This API is supposed to replace virDomainGetInfo when the only purpose of calling it is getting current domain status. @@ -674,6 +726,9 @@ int virDomainCoreDump

Re: [libvirt] [PATCH 0/8] Introduce virDomainGetState API

2011-05-05 Thread Jiri Denemark
On Wed, May 04, 2011 at 10:40:38 -0600, Eric Blake wrote: On 05/04/2011 08:45 AM, Jiri Denemark wrote: This new API solves several problems: - calling virDomainGetInfo for just getting domain status is an overkill since it may result in sending requests to guest OS - since

[libvirt] Magic error introduced by commit f09accc

2011-05-06 Thread Jiri Denemark
Hi all, After commit f09accc (buf: add virBufferVasprintf) libvirt no longer compiles with -Werror because of the following error: CC libvirt_util_la-macvtap.lo cc1: warnings being treated as errors /usr/include/netlink/object.h:58: error: inline function 'nl_object_priv' declared but

Re: [libvirt] [PATCH 5/8] virsh: Prefer virDomainGetState over virDomainGetInfo

2011-05-06 Thread Jiri Denemark
On Wed, May 04, 2011 at 17:35:42 -0600, Eric Blake wrote: +bool noGetState;/* virDomainGetState is not supported in + * current connection */ Nice - remembering the failure once, so you don't have to repeat it. However, I don't like double

Re: [libvirt] Magic error introduced by commit f09accc

2011-05-09 Thread Jiri Denemark
On Fri, May 06, 2011 at 16:33:13 -0600, Eric Blake wrote: On 05/06/2011 01:18 PM, Jiri Denemark wrote: We discussed more on IRC. The problem is due to a bug in out-of-the-box libnl headers, and has been patched in most distros to just delete the 'inline' as then you don't have to worry about

Re: [libvirt] [PATCHv2 5/3] build: fix VPATH builds

2011-05-09 Thread Jiri Denemark
On Sat, May 07, 2011 at 14:18:35 +0200, Matthias Bolte wrote: 2011/5/7 Eric Blake ebl...@redhat.com: * src/Makefile.am (REMOTE_DRIVER_GENERATED): Generated files should live in $(srcdir). Update rules to reflect this. --- This still doesn't fix the fact that 'make dist' under

Re: [libvirt] [PATCH] json: Fix *GetBoolean functions

2011-05-09 Thread Jiri Denemark
On Thu, May 05, 2011 at 13:13:13 -0600, Eric Blake wrote: On 05/05/2011 07:10 AM, Jiri Denemark wrote: They were not used anywhere so far so nobody noticed they are broken. --- src/util/json.c | 11 ++- src/util/json.h |4 ++-- 2 files changed, 8 insertions(+), 7

[libvirt] [PATCH] virsh: Correctly initialize libvirt

2011-05-09 Thread Jiri Denemark
virsh didn't call virInitialize(), which (among other things) initializes virLastErr thread local variable. As a result of that, virsh could just segfault in virEventRegisterDefaultImpl() since that is the first call that touches (resets) virLastErr. I have no idea what lucky coincidence made

[libvirt] [PATCH v2 3/9] virDomainGetState public API implementation

2011-05-10 Thread Jiri Denemark
--- Notes: Version 2: - rebased - unsigned int flags src/libvirt.c | 51 +++ 1 files changed, 51 insertions(+), 0 deletions(-) diff --git a/src/libvirt.c b/src/libvirt.c index abacf85..571eb97 100644 --- a/src/libvirt.c +++

[libvirt] [PATCH v2 0/9] Introduce virDomainGetState API

2011-05-10 Thread Jiri Denemark
- simplified implementation in esx driver per Matthias' suggestion - call internal xen drivers directly instead of going through xenUnifiedDriver - fixed || vs typo in domain_conf.c - new patch 9/9: qemu: Update domain state when reconnecting monitor Jiri Denemark (9): virDomainGetState public API

[libvirt] [PATCH v2 4/9] Wire protocol format and dispatcher for virDomainGetState

2011-05-10 Thread Jiri Denemark
--- Notes: Version 2: - rebased - unsigned int flags daemon/remote.c | 33 + daemon/remote_generator.pl |3 ++- src/remote/remote_protocol.x | 13 - src/remote_protocol-structs |8 4 files changed, 55

[libvirt] [PATCH v2 5/9] virsh: Prefer virDomainGetState over virDomainGetInfo

2011-05-10 Thread Jiri Denemark
--- Notes: Version 2: - rebased - unsigned int flags - noGetState renamed as useGetInfo tools/virsh.c | 195 +++-- 1 files changed, 162 insertions(+), 33 deletions(-) diff --git a/tools/virsh.c b/tools/virsh.c index

[libvirt] [PATCH v2 2/9] Internal driver API for virDomainGetState

2011-05-10 Thread Jiri Denemark
--- Notes: Version 2: - rebased - unsigned int flags parameter - avoid changing xenUnifiedDriver internal callback struct src/driver.h |6 ++ src/esx/esx_driver.c |1 + src/libxl/libxl_driver.c |1 + src/lxc/lxc_driver.c |1 +

[libvirt] [PATCH v2 6/9] remote: Implement virDomainGetState

2011-05-10 Thread Jiri Denemark
--- Notes: Version 2: - rebased - unsigned int flags daemon/remote_generator.pl |3 ++- src/remote/remote_driver.c | 35 ++- 2 files changed, 36 insertions(+), 2 deletions(-) diff --git a/daemon/remote_generator.pl b/daemon/remote_generator.pl

[libvirt] [PATCH v2 1/9] virDomainGetState public API

2011-05-10 Thread Jiri Denemark
This API is supposed to replace virDomainGetInfo when the only purpose of calling it is getting current domain status. --- Notes: Version 2: - rebased - unsigned int flags parameter - updated version info in public.syms include/libvirt/libvirt.h.in| 56

[libvirt] [PATCH v2 7/9] Implement basic virDomainGetState in all drivers

2011-05-10 Thread Jiri Denemark
Reason is currently always set to 0 (i.e., *_UNKNOWN). --- Notes: Version 2: - rebased - unsigned int flags - simplified implementation in esx driver per Matthias' suggestion - call internal xen drivers directly instead of going through xenUnifiedDriver src/esx/esx_driver.c

<    4   5   6   7   8   9   10   11   12   13   >