[libvirt] [PATCH] qemu: fix crash when mixing sync and async monitor jobs

2011-07-28 Thread Eric Blake
Currently, we attempt to run sync job and async job at the same time. It means that the monitor commands for two jobs can be run in any order. In the function qemuDomainObjEnterMonitorInternal(): if (priv->job.active == QEMU_JOB_NONE && priv->job.asyncJob) { if (qemuDomainObjBeginNeste

Re: [libvirt] [virt-tools-list] ANNOUNCE: virt-manager 0.9.0 and virtinst 0.600.0 released

2011-07-28 Thread Jason Helfman
On Thu, Jul 28, 2011 at 12:31:10PM -0400, Cole Robinson thus spake: I'm happy to announce two new releases: virt-manager 0.9.0: virt-manager is a desktop application for managing KVM and Xen virtual machines via libvirt. virtinst 0.600.0: virtinst is a collection of command line tools for provi

Re: [libvirt] [virt-tools-list] virt-manager/libvirt backwards compatibility problem?

2011-07-28 Thread Guido Günther
Hi Eric, On Wed, Jul 27, 2011 at 02:52:46PM -0600, Eric Blake wrote: [..snip..] > Pasting from that URL gave awkward results below; can you address my > comments below, then post a v2 as a proper patch against > libvirt.git? Thanks for the review! New version attached. [..snip..] > I don't li

Re: [libvirt] [PATCHv3 2/3] save: let qemu driver manipulate save files

2011-07-28 Thread Eric Blake
On 07/28/2011 12:47 PM, Laine Stump wrote: On 07/22/2011 12:21 AM, Eric Blake wrote: The goal here is that save-image-dumpxml fed back to save image-define without changing the save file; anywhere that this is not the case is probably a bug in domain_conf.c. I'll do a v4 of patch 3/3 to plug t

Re: [libvirt] [PATCHv3 1/3] save: support qemu modifying xml on domain save/restore

2011-07-28 Thread Eric Blake
On 07/28/2011 12:00 PM, Laine Stump wrote: --- v3: change virDomainSave to always output minimal information, but with fixed padding added, so that save file modification will always be more likely to succeed, "always be more likely". Heh. I guess dropping "always" would make that sentence m

Re: [libvirt] [PATCHv2 1/2] maint: add missing copyright notices

2011-07-28 Thread Eric Blake
On 07/28/2011 02:24 PM, Laine Stump wrote: On 07/28/2011 03:32 PM, Eric Blake wrote: I went with the shorter license notice used by src/libvirt.c, rather than spelling out the full LGPLv2+ clause into each of these files. * configure.ac: Declare copyright. * all Makefile.am: Likewise. ACK.

Re: [libvirt] [PATCH 4/4] xen: drop unused callbacks

2011-07-28 Thread Eric Blake
On 07/28/2011 02:03 PM, Laine Stump wrote: On 07/21/2011 05:39 PM, Eric Blake wrote: Found by: for f in $(sed -n 's/.*Drv[^ ]* \([^;]*\);.*/\1/p' src/xen/xen_driver.h) do git grep "\(\.\|->\)$f\b" src/xen done | cat and looking through the resulting list to see which callback struct members ar

Re: [libvirt] [PATCH 3/4] xen: make direct call when there is only one subdriver

2011-07-28 Thread Laine Stump
On 07/28/2011 04:34 PM, Eric Blake wrote: On 07/28/2011 02:00 PM, Laine Stump wrote: Conditional ACK, based on satisfactory answers to these questions... I hope that was satisfactory, because I'm pushing as soon as I also answer your comments to patch 4 :) Yep. I'm happy. -- libvir-lis

Re: [libvirt] [PATCH 3/4] xen: make direct call when there is only one subdriver

2011-07-28 Thread Eric Blake
On 07/28/2011 02:00 PM, Laine Stump wrote: On 07/21/2011 05:39 PM, Eric Blake wrote: No need to use a for loop if we know there is exactly one client. VIR_DEBUG("Failed to activate a mandatory sub-driver"); for (i = 0 ; i< XEN_UNIFIED_NR_DRIVERS ; i++) - if (priv->opened[i]) drivers[i]->xenClos

Re: [libvirt] [PATCHv2 1/2] maint: add missing copyright notices

2011-07-28 Thread Laine Stump
On 07/28/2011 03:32 PM, Eric Blake wrote: I went with the shorter license notice used by src/libvirt.c, rather than spelling out the full LGPLv2+ clause into each of these files. * configure.ac: Declare copyright. * all Makefile.am: Likewise. ACK. -- libvir-list mailing list libvir-list@redha

Re: [libvirt] [PATCH] support qemuMonitorSend() to be called at the same time

2011-07-28 Thread Eric Blake
On 07/28/2011 03:13 AM, Wen Congyang wrote: Current, we support run sync job and async job at the same time. It means that the monitor commands for two jobs can be run in any order. In the function qemuDomainObjEnterMonitorInternal(): if (priv->job.active == QEMU_JOB_NONE&& priv->job.asyn

Re: [libvirt] [PATCH 4/4] xen: drop unused callbacks

2011-07-28 Thread Laine Stump
On 07/21/2011 05:39 PM, Eric Blake wrote: Found by: for f in $(sed -n 's/.*Drv[^ ]* \([^;]*\);.*/\1/p' src/xen/xen_driver.h) do git grep "\(\.\|->\)$f\b" src/xen done | cat and looking through the resulting list to see which callback struct members are still necessary. Sure. Why not? Simpl

Re: [libvirt] [PATCH 3/4] xen: make direct call when there is only one subdriver

2011-07-28 Thread Laine Stump
On 07/21/2011 05:39 PM, Eric Blake wrote: No need to use a for loop if we know there is exactly one client. * src/xen/xen_driver.c (xenUnifiedClose): Call close unconditionally, to match xenUnifiedOpen. (xenUnifiedNodeGetInfo, xenUnifiedDomainCreateXML) (xenUnifiedDomainSave, xenUnifiedDomainRes

Re: [libvirt] libvirt-0.9.3 and qemu-0.14.1

2011-07-28 Thread Zdenek Styblik
On 07/28/11 21:24, Zdenek Styblik wrote: > Hello, > > I'm not sure if this has been reported or fixed, but ... > > ~~~ SNIP ~~~ > 21:02:59.981: 13171: info : libvirt version: 0.9.3 > 21:02:59.981: 13171: error : virCommandWait:1957 : internal error Child > process (LC_ALL=C > PATH=/usr/local/sbin

Re: [libvirt] [PATCH 2/4] xen: reduce callback special cases

2011-07-28 Thread Laine Stump
On 07/21/2011 05:39 PM, Eric Blake wrote: The callback struct is great when iterating through several possibilities, but when calling a known callback, it's just overhead. We can make the direct call in those cases. * src/xen/xen_driver.c (xenUnifiedOpen, xenUnifiedDomainSuspend) (xenUnifiedDom

Re: [libvirt] [PATCH 1/4] xen: cleanup callback struct

2011-07-28 Thread Laine Stump
On 07/21/2011 05:39 PM, Eric Blake wrote: Using C99 initializers and xen-specific prefixes will make it so that future patches are less likely to add callback members to the xenUnifiedDriver struct, since the goal is to get rid of the callback struct in the first place. * src/xen/xen_driver.h (x

Re: [libvirt] [PATCH] freebsd: Fix build problem due to picking up the wrong libvirt.h

2011-07-28 Thread Eric Blake
On 07/28/2011 07:51 AM, Eric Blake wrote: > Is there any option in gnulib that would allow to inject > GETTEXT_CPPFLAGS into the gnulib makefiles, or any other possibility > to fix this? Fortunately, I know how to fix that - it involves changing our gnulib-tool to spit out gnulib.mk to be inc

[libvirt] [PATCHv2 2/2] freebsd: Fix build problem due to picking up the wrong libvirt.h

2011-07-28 Thread Eric Blake
From: Matthias Bolte Gettext annoyingly modifies CPPFLAGS in-place, putting -I/usr/local/include into the search patch if libintl headers must be used from that location. But since we must support automake 1.9.6 which lacks AM_CPPFLAGS, and since CPPFLAGS is used prior to INCLUDES, this means th

[libvirt] [PATCHv2 1/2] maint: add missing copyright notices

2011-07-28 Thread Eric Blake
I went with the shorter license notice used by src/libvirt.c, rather than spelling out the full LGPLv2+ clause into each of these files. * configure.ac: Declare copyright. * all Makefile.am: Likewise. --- Noticed while reviewing Matthias' patch. Almost trivial enough to push in isolation, but I'

[libvirt] libvirt-0.9.3 and qemu-0.14.1

2011-07-28 Thread Zdenek Styblik
Hello, I'm not sure if this has been reported or fixed, but ... ~~~ SNIP ~~~ 21:02:59.981: 13171: info : libvirt version: 0.9.3 21:02:59.981: 13171: error : virCommandWait:1957 : internal error Child process (LC_ALL=C PATH=/usr/local/sbin:/usr/local/bin:/sbin:/usr/sbin:/bin:/usr/bin HOME=/root US

Re: [libvirt] [PATCH] libxl: fix build failure due to change in virDomainGraphicsDef

2011-07-28 Thread Laine Stump
On 07/28/2011 02:49 PM, Eric Blake wrote: On 07/28/2011 12:41 PM, Laine Stump wrote: This failure was introduced by commit dacee3d, which removed listenAddr from the unions in virDomainGraphicsDef in favor of putting it in the address attribute of virDomainGraphicsListenDef. --- src/libxl/libx

Re: [libvirt] [RFC: PATCHv3 3/3] save: generate idempotent inactive xml for running domain

2011-07-28 Thread Laine Stump
On 07/22/2011 12:21 AM, Eric Blake wrote: Noticed by comparing the xml generated by virDomainSave with the xml produced by reparsing and redumping that xml. * src/conf/domain_conf.c (virDomainDeviceInfoIsSet): Add parameter, and update all callers. Make static. (virDomainNetDefFormat): Skip gen

Re: [libvirt] [PATCH] libxl: fix build failure due to change in virDomainGraphicsDef

2011-07-28 Thread Eric Blake
On 07/28/2011 12:41 PM, Laine Stump wrote: This failure was introduced by commit dacee3d, which removed listenAddr from the unions in virDomainGraphicsDef in favor of putting it in the address attribute of virDomainGraphicsListenDef. --- src/libxl/libxl_conf.c |7 --- 1 files changed,

Re: [libvirt] [PATCHv3 2/3] save: let qemu driver manipulate save files

2011-07-28 Thread Laine Stump
On 07/22/2011 12:21 AM, Eric Blake wrote: The goal here is that save-image-dumpxml fed back to save image-define without changing the save file; anywhere that this is not the case is probably a bug in domain_conf.c. * src/qemu/qemu_driver.c (qemuDomainSaveImageGetXMLDesc) (qemuDomainSaveImageDef

[libvirt] [PATCH] libxl: fix build failure due to change in virDomainGraphicsDef

2011-07-28 Thread Laine Stump
This failure was introduced by commit dacee3d, which removed listenAddr from the unions in virDomainGraphicsDef in favor of putting it in the address attribute of virDomainGraphicsListenDef. --- src/libxl/libxl_conf.c |7 --- 1 files changed, 4 insertions(+), 3 deletions(-) diff --git a/s

Re: [libvirt] virNetClientPtr leak in remote driver

2011-07-28 Thread Matthias Bolte
2011/7/27 Matthias Bolte : > doRemoteClose doesn't free the virNetClientPtr and this creates a > 260kb leak per remote connection. This happens because > virNetClientFree doesn't remove the last ref, because virNetClientNew > creates the virNetClientPtr with a refcount of 2. > > static virNetClient

Re: [libvirt] [PATCHv3 1/3] save: support qemu modifying xml on domain save/restore

2011-07-28 Thread Laine Stump
On 07/22/2011 12:21 AM, Eric Blake wrote: With this, it is possible to update the path to a disk backing image on either the save or restore action, without having to binary edit the XML embedded in the state file. This also modifies virDomainSave to output a smaller xml (only the inactive xml,

Re: [libvirt] [PATCHv4 2/2] qemu: support type=network in domain graphics

2011-07-28 Thread Laine Stump
On 07/28/2011 01:21 PM, Eric Blake wrote: On 07/28/2011 12:11 AM, Laine Stump wrote: The domain XML now understands the subelement of its element (including when listen type='network'), and the network driver has an internal API that will turn a network name into an IP address, so the final l

Re: [libvirt] [PATCHv4 1/2] conf: add subelement to domain element

2011-07-28 Thread Laine Stump
On 07/28/2011 01:09 PM, Eric Blake wrote: On 07/28/2011 12:11 AM, Laine Stump wrote: Once it's plugged in, the element will be an optional replacement for the "listen" attribute that graphics elements already have. If the element is type='address', it will have an attribute called 'address' wh

Re: [libvirt] [PATCHv4 2/2] qemu: support type=network in domain graphics

2011-07-28 Thread Eric Blake
On 07/28/2011 12:11 AM, Laine Stump wrote: The domain XML now understands the subelement of its element (including when listen type='network'), and the network driver has an internal API that will turn a network name into an IP address, so the final logical step is to put the glue into the qem

Re: [libvirt] [PATCH] freebsd: Avoid /bin/true in commandtest

2011-07-28 Thread Eric Blake
On 07/28/2011 09:52 AM, Matthias Bolte wrote: Rely on PATH and use just true, because on FreeBSD it's /usr/bin/true. What fun. The autoconf manual has this gem under true, apropos to the current patch: | when asked whether false is more portable than true Alexandre Oliva answered: | |

Re: [libvirt] [PATCH] tests: Unify style of test skipping code

2011-07-28 Thread Eric Blake
On 07/28/2011 09:52 AM, Matthias Bolte wrote: Prefer 'return EXIT_AM_SKIP' over 'exit(EXIT_AM_SKIP)'. Prefer 'int main(void)' over 'int main(int argc, char **argv)'. Fix mymain signature in commandtest and nodeinfotest. --- tests/commandtest.c | 10 +- tests/nodeinfotest.c

Re: [libvirt] [PATCHv4 1/2] conf: add subelement to domain element

2011-07-28 Thread Eric Blake
On 07/28/2011 12:11 AM, Laine Stump wrote: Once it's plugged in, the element will be an optional replacement for the "listen" attribute that graphics elements already have. If the element is type='address', it will have an attribute called 'address' which will contain an IP address or dns name

[libvirt] ANNOUNCE: virt-manager 0.9.0 and virtinst 0.600.0 released

2011-07-28 Thread Cole Robinson
I'm happy to announce two new releases: virt-manager 0.9.0: virt-manager is a desktop application for managing KVM and Xen virtual machines via libvirt. virtinst 0.600.0: virtinst is a collection of command line tools for provisioning libvirt virtual machines, including virt-install and virt-clon

[libvirt] [PATCH] freebsd: Avoid /bin/true in commandtest

2011-07-28 Thread Matthias Bolte
Rely on PATH and use just true, because on FreeBSD it's /usr/bin/true. --- tests/commanddata/test16.log |2 +- tests/commandtest.c |6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/tests/commanddata/test16.log b/tests/commanddata/test16.log index 2433a4d..7

[libvirt] [PATCH] tests: Unify style of test skipping code

2011-07-28 Thread Matthias Bolte
Prefer 'return EXIT_AM_SKIP' over 'exit(EXIT_AM_SKIP)'. Prefer 'int main(void)' over 'int main(int argc, char **argv)'. Fix mymain signature in commandtest and nodeinfotest. --- tests/commandtest.c | 10 +- tests/nodeinfotest.c | 10 +- tests/qemuargv2xmltest

Re: [libvirt] [PATCH v4] virsh: avoid missing zero value judgement in cmdBlkiotune

2011-07-28 Thread ajia
On 07/28/2011 10:31 PM, Eric Blake wrote: On 07/28/2011 08:25 AM, ajia wrote: - _("Unable to parse integer parameter")); + _("Unable to parse non-integer parameter")); Why this change? when I give a non-integer to weight value such as virsh blkiotune $domain --weight demo, vshError will be hit

Re: [libvirt] [PATCH v4] virsh: avoid missing zero value judgement in cmdBlkiotune

2011-07-28 Thread Eric Blake
On 07/28/2011 08:25 AM, ajia wrote: - _("Unable to parse integer parameter")); + _("Unable to parse non-integer parameter")); Why this change? when I give a non-integer to weight value such as virsh blkiotune $domain --weight demo, vshError will be hit and raise "Unable to parse integer paramet

Re: [libvirt] [PATCH v4] virsh: avoid missing zero value judgement in cmdBlkiotune

2011-07-28 Thread ajia
On 07/28/2011 07:20 PM, Michal Privoznik wrote: On 28.07.2011 13:13, Alex Jia wrote: * tools/virsh.c: fix missing zero value judgement in cmdBlkiotune and correct vshError information. when weight is equal to 0, the cmdBlkiotune will not raise any error information when judge weight

Re: [libvirt] [PATCH] qemu: fix nested job with driver lock held

2011-07-28 Thread Eric Blake
On 07/27/2011 09:58 PM, Laine Stump wrote: On 07/27/2011 10:04 PM, Eric Blake wrote: qemuMigrationUpdateJobStatus (called in a loop by migration and save tasks) uses qemuDomainObjEnterMonitorWithDriver; however, that function ended up starting a nested job without releasing the driver. Since no

Re: [libvirt] [PATCH] build: avoid type-punning compiler warning

2011-07-28 Thread Eric Blake
On 07/28/2011 04:11 AM, Matthias Bolte wrote: 2011/7/27 Eric Blake: On RHEL 5, with gcc 4.1.2: rpc/virnetsaslcontext.c: In function 'virNetSASLSessionUpdateBufSize': rpc/virnetsaslcontext.c:396: warning: dereferncing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing] * s

Re: [libvirt] [PATCH RFC] virsh: Add option to undefine storage with domains

2011-07-28 Thread Dave Allan
On Thu, Jul 28, 2011 at 03:41:01PM +0200, Peter Krempa wrote: > Adds an option to virsh undefine command to undefine managed > storage volumes along with (inactive) domains. Storage volumes > are enumerated and the user may interactivly choose volumes > to delete. > > Unmanaged volumes are listed

Re: [libvirt] [PATCH] qemu: Fix memory leak on metadata fetching

2011-07-28 Thread Michal Privoznik
On 28.07.2011 16:00, Eric Blake wrote: On 07/28/2011 07:56 AM, Michal Privoznik wrote: As written in virStorageFileGetMetadataFromFD decription, caller must free metadata after use. Qemu driver miss this and therefore leak metadata which can grow to huge mem leak if somebody query for blockInfo

Re: [libvirt] [PATCH] qemu: Fix memory leak on metadata fetching

2011-07-28 Thread Eric Blake
On 07/28/2011 07:56 AM, Michal Privoznik wrote: As written in virStorageFileGetMetadataFromFD decription, caller must free metadata after use. Qemu driver miss this and therefore leak metadata which can grow to huge mem leak if somebody query for blockInfo a lot. --- src/qemu/qemu_driver.c |

Re: [libvirt] PCI devices passthough to LXC containers using libvirt

2011-07-28 Thread Serge Hallyn
Quoting Devendra K. Modium (dmod...@isi.edu): > Hi > > Thanks for the reply. > > I think the links that you provided show > how to deal with pci devices in case the hypervisor is kvm. > Please correct me if I am wrong. > > But I am using LXC containers.I have skimmed through > the libvirt lxc d

[libvirt] [PATCH] qemu: Fix memory leak on metadata fetching

2011-07-28 Thread Michal Privoznik
As written in virStorageFileGetMetadataFromFD decription, caller must free metadata after use. Qemu driver miss this and therefore leak metadata which can grow to huge mem leak if somebody query for blockInfo a lot. --- src/qemu/qemu_driver.c | 14 ++ 1 files changed, 10 insertions(+

Re: [libvirt] [PATCH] freebsd: Add gnulib environ module for the commandtest

2011-07-28 Thread Eric Blake
On 07/28/2011 07:52 AM, Matthias Bolte wrote: At least all tests compile on FreeBSD again. But most of the SSH cases in virnetmessagetest are failing and I don't understand why yet. Could it be a PATH vs. exec() issue, where BSD ends up doing a slightly different PATH search and not executing

Re: [libvirt] [PATCH] freebsd: Add gnulib environ module for the commandtest

2011-07-28 Thread Matthias Bolte
2011/7/28 Eric Blake : > On 07/28/2011 05:08 AM, Matthias Bolte wrote: >> >> --- >>  bootstrap.conf |    1 + >>  1 files changed, 1 insertions(+), 0 deletions(-) >> >> diff --git a/bootstrap.conf b/bootstrap.conf >> index f006a47..3b105b1 100644 >> --- a/bootstrap.conf >> +++ b/bootstrap.conf >> @@

Re: [libvirt] [PATCH] freebsd: Fix build problem due to picking up the wrong libvirt.h

2011-07-28 Thread Eric Blake
On 07/28/2011 06:55 AM, Matthias Bolte wrote: Okay, this works for libvirt itself, but it fails for make check as the global CPPFLAGS also affect gnulib, but with this patch it doesn't contain the gettext related parts anymore and the gnulib tests fail to find libintl.h because of this. > Is th

Re: [libvirt] [PATCH] freebsd: Add gnulib environ module for the commandtest

2011-07-28 Thread Eric Blake
On 07/28/2011 05:08 AM, Matthias Bolte wrote: --- bootstrap.conf |1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/bootstrap.conf b/bootstrap.conf index f006a47..3b105b1 100644 --- a/bootstrap.conf +++ b/bootstrap.conf @@ -36,6 +36,7 @@ configmake count-one-bits cryp

[libvirt] [PATCH RFC] virsh: Add option to undefine storage with domains

2011-07-28 Thread Peter Krempa
Adds an option to virsh undefine command to undefine managed storage volumes along with (inactive) domains. Storage volumes are enumerated and the user may interactivly choose volumes to delete. Unmanaged volumes are listed and the user shall delete them manualy. --- I marked this as a RFC because

Re: [libvirt] PCI devices passthough to LXC containers using libvirt

2011-07-28 Thread Devendra K. Modium
Hi Thanks for the reply. I think the links that you provided show how to deal with pci devices in case the hypervisor is kvm. Please correct me if I am wrong. But I am using LXC containers.I have skimmed through the libvirt lxc driver code and found no functionality of allowing specified device

Re: [libvirt] [PATCH] freebsd: Fix build problem due to picking up the wrong libvirt.h

2011-07-28 Thread Matthias Bolte
2011/7/26 Eric Blake : > On 07/26/2011 02:45 PM, Matthias Bolte wrote: +++ b/configure.ac @@ -2011,8 +2011,16 @@ dnl Enable building libvirtd?  AM_CONDITIONAL([WITH_LIBVIRTD],[test "x$with_libvirtd" = "xyes"])  dnl Check for gettext - don't go any newer than what RHEL

Re: [libvirt] libvirt-0.9.1 to 0.9.3-r1: managedsave/save won't start/restore at saved state

2011-07-28 Thread Nicolas Sebrecht
The 27/07/11, Nicolas Sebrecht wrote: > I'm seeing strange behaviour, here. Any guests saved using both > managedsave and save commands from virsh won't restore at saved state. A > new full boot sequence happen. > > - Tested against libvirt v0.9.1, v0.9.2, v0.9.3-r1 (Gentoo) > - Confirmed on thre

Re: [libvirt] [PATCH v4] virsh: avoid missing zero value judgement in cmdBlkiotune

2011-07-28 Thread Michal Privoznik
On 28.07.2011 13:13, Alex Jia wrote: * tools/virsh.c: fix missing zero value judgement in cmdBlkiotune and correct vshError information. when weight is equal to 0, the cmdBlkiotune will not raise any error information when judge weight value first time, and execute else branch to judge

[libvirt] [PATCH] freebsd: Add gnulib environ module for the commandtest

2011-07-28 Thread Matthias Bolte
--- bootstrap.conf |1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/bootstrap.conf b/bootstrap.conf index f006a47..3b105b1 100644 --- a/bootstrap.conf +++ b/bootstrap.conf @@ -36,6 +36,7 @@ configmake count-one-bits crypto/md5 dirname-lgpl +environ fclose fcntl-h ffs

[libvirt] [PATCH v4] virsh: avoid missing zero value judgement in cmdBlkiotune

2011-07-28 Thread ajia
* tools/virsh.c: fix missing zero value judgement in cmdBlkiotune and correct vshError information. when weight is equal to 0, the cmdBlkiotune will not raise any error information when judge weight value first time, and execute else branch to judge weight value again, strncpy(temp->field

Re: [libvirt] [PATCH v3] virsh: avoid missing zero value judgement in cmdBlkiotune

2011-07-28 Thread Michal Privoznik
On 28.07.2011 12:38, Alex Jia wrote: On 07/28/2011 05:50 PM, Wen Congyang wrote: At 07/28/2011 05:52 PM, Alex Jia Write: * tools/virsh.c: avoid missing zero value judgement in cmdBlkiotune, when weight is equal to 0, the cmdBlkiotune will not raise any error information when judge weight value

Re: [libvirt] [PATCH v3] virsh: avoid missing zero value judgement in cmdBlkiotune

2011-07-28 Thread Alex Jia
On 07/28/2011 05:50 PM, Wen Congyang wrote: At 07/28/2011 05:52 PM, Alex Jia Write: * tools/virsh.c: avoid missing zero value judgement in cmdBlkiotune, when weight is equal to 0, the cmdBlkiotune will not raise any error information when judge weight value first time, and execute else bra

Re: [libvirt] [PATCH v2] virsh: avoid missing zero value judgement in cmdBlkiotune

2011-07-28 Thread Michal Privoznik
On 28.07.2011 11:04, Alex Jia wrote: * tools/virsh.c: avoid missing zero value judgement in cmdBlkiotune, when weight is equal to 0, the cmdBlkiotune will not raise any error information when judge weight value first time, and execute else branch to judge weight value again, strncpy(temp

Re: [libvirt] [PATCH v2] virsh: avoid missing zero value judgement in cmdBlkiotune

2011-07-28 Thread Alex Jia
On 07/28/2011 05:55 PM, Michal Privoznik wrote: On 28.07.2011 11:26, Alex Jia wrote: On 07/28/2011 05:04 PM, Alex Jia wrote: * tools/virsh.c: avoid missing zero value judgement in cmdBlkiotune, when weight is equal to 0, the cmdBlkiotune will not raise any error information when judge weight v

[libvirt] [PATCH] support qemuMonitorSend() to be called at the same time

2011-07-28 Thread Wen Congyang
Current, we support run sync job and async job at the same time. It means that the monitor commands for two jobs can be run in any order. In the function qemuDomainObjEnterMonitorInternal(): if (priv->job.active == QEMU_JOB_NONE && priv->job.asyncJob) { if (qemuDomainObjBeginNestedJob

Re: [libvirt] [PATCH] build: avoid type-punning compiler warning

2011-07-28 Thread Matthias Bolte
2011/7/27 Eric Blake : > On RHEL 5, with gcc 4.1.2: > > rpc/virnetsaslcontext.c: In function 'virNetSASLSessionUpdateBufSize': > rpc/virnetsaslcontext.c:396: warning: dereferncing type-punned pointer will > break strict-aliasing rules [-Wstrict-aliasing] > > * src/rpc/virnetsaslcontext.c (virNetSA

Re: [libvirt] [PATCH v2] virsh: avoid missing zero value judgement in cmdBlkiotune

2011-07-28 Thread Michal Privoznik
On 28.07.2011 11:26, Alex Jia wrote: On 07/28/2011 05:04 PM, Alex Jia wrote: * tools/virsh.c: avoid missing zero value judgement in cmdBlkiotune, when weight is equal to 0, the cmdBlkiotune will not raise any error information when judge weight value first time, and execute else branch to judge

Re: [libvirt] [PATCH v3] virsh: avoid missing zero value judgement in cmdBlkiotune

2011-07-28 Thread Wen Congyang
At 07/28/2011 05:52 PM, Alex Jia Write: > * tools/virsh.c: avoid missing zero value judgement in cmdBlkiotune, when > weight is equal to 0, the cmdBlkiotune will not raise any error information > when judge weight value first time, and execute else branch to judge weight > value again, strncp

[libvirt] [PATCH v3] virsh: avoid missing zero value judgement in cmdBlkiotune

2011-07-28 Thread ajia
* tools/virsh.c: avoid missing zero value judgement in cmdBlkiotune, when weight is equal to 0, the cmdBlkiotune will not raise any error information when judge weight value first time, and execute else branch to judge weight value again, strncpy(temp->field, VIR_DOMAIN_BLKIO_WEIGHT, sizeof(

[libvirt] Re: libvirt-0.9.1 to 0.9.3-r1: managedsave/save won't start/restore at saved state

2011-07-28 Thread Nicolas Sebrecht
The 27/07/11, Eric Blake wrote: > On 07/27/2011 02:37 AM, Nicolas Sebrecht wrote: > >I'm seeing strange behaviour, here. Any guests saved using both > >managedsave and save commands from virsh won't restore at saved state. A > >new full boot sequence happen. > > > >- Tested against libvirt v0.9.1,

Re: [libvirt] [PATCH v2] virsh: avoid missing zero value judgement in cmdBlkiotune

2011-07-28 Thread Alex Jia
On 07/28/2011 05:16 PM, Michal Privoznik wrote: On 28.07.2011 11:04, Alex Jia wrote: * tools/virsh.c: avoid missing zero value judgement in cmdBlkiotune, when weight is equal to 0, the cmdBlkiotune will not raise any error information when judge weight value first time, and execute else b

Re: [libvirt] [PATCH v2] virsh: avoid missing zero value judgement in cmdBlkiotune

2011-07-28 Thread Alex Jia
On 07/28/2011 05:04 PM, Alex Jia wrote: * tools/virsh.c: avoid missing zero value judgement in cmdBlkiotune, when weight is equal to 0, the cmdBlkiotune will not raise any error information when judge weight value first time, and execute else branch to judge weight value again, strncpy(t

[libvirt] Re: libvirt-0.9.1 to 0.9.3-r1: managedsave/save won't start/restore at saved state

2011-07-28 Thread Nicolas Sebrecht
The 27/07/11, Laine Stump wrote: > If you pause ("virsh suspend") the guest before the save, can you > then successfully start the domain (it should "start" in a paused > state, and when the virsh commandline returns to the prompt, you can > resume it with "virsh resume".) If this is the case, it

Re: [libvirt] RFC: API additions for enhanced snapshot support

2011-07-28 Thread Stefan Hajnoczi
On Wed, Jul 27, 2011 at 3:17 PM, Eric Blake wrote: > On 07/27/2011 04:04 AM, Stefan Hajnoczi wrote: >> >> On Thu, Jun 16, 2011 at 6:41 AM, Eric Blake  wrote: >>> >>> Right now, libvirt has a snapshot API via virDomainSnapshotCreateXML, >>> but for qemu domains, it only works if all the guest disk

[libvirt] [PATCH v2] virsh: avoid missing zero value judgement in cmdBlkiotune

2011-07-28 Thread ajia
* tools/virsh.c: avoid missing zero value judgement in cmdBlkiotune, when weight is equal to 0, the cmdBlkiotune will not raise any error information when judge weight value first time, and execute else branch to judge weight value again, strncpy(temp->field, VIR_DOMAIN_BLKIO_WEIGHT, sizeof(

[libvirt] [PATCH] virsh: avoid missing zero value judgement in cmdBlkiotune

2011-07-28 Thread ajia
* tools/virsh.c: avoid missing zero value judgement in cmdBlkiotune, when weight is equal to 0, the cmdBlkiotune will not raise any error information when judge weight value first time, and execute else branch to judge weight value again, strncpy(temp->field, VIR_DOMAIN_BLKIO_WEIGHT, sizeof

Re: [libvirt] [PATCH 4/4] python: add python binding for virDomainSetMemoryParameters

2011-07-28 Thread Michal Privoznik
On 27.07.2011 04:13, Hu Tao wrote: --- python/libvirt-override-api.xml |1 + python/libvirt-override.c | 94 +- 2 files changed, 92 insertions(+), 3 deletions(-) ACK. I pushed the whole set and update of flags description for virDomainSetBlki

Re: [libvirt] [PATCH 00/19] Rollback migration when libvirtd restarts

2011-07-28 Thread Wen Congyang
At 07/28/2011 03:26 PM, Wen Congyang Write: > At 07/28/2011 05:41 AM, Eric Blake Write: >> On 07/07/2011 05:34 PM, Jiri Denemark wrote: >>> This series is also available at >>> https://gitorious.org/~jirka/libvirt/jirka-staging/commits/migration-recovery >>> >>> >>> The series does several things:

Re: [libvirt] [PATCH 2/4] python: add python binding for virDomainSetBlkioParameters

2011-07-28 Thread Michal Privoznik
On 27.07.2011 04:13, Hu Tao wrote: --- python/libvirt-override-api.xml |1 + python/libvirt-override.c | 94 +- 2 files changed, 92 insertions(+), 3 deletions(-) ACK, but again, we need update of virDomainSetBlkioParameters description. I'll c

Re: [libvirt] [PATCH 3/4] python: add python binding for virDomainGetMemoryParameters

2011-07-28 Thread Michal Privoznik
On 27.07.2011 04:13, Hu Tao wrote: --- python/libvirt-override-api.xml |6 +- python/libvirt-override.c | 79 +- 2 files changed, 79 insertions(+), 6 deletions(-) ACK Michal -- libvir-list mailing list libvir-list@redhat.com https://www.redh

Re: [libvirt] [PATCH 2/4] python: add python binding for virDomainSetBlkioParameters

2011-07-28 Thread Hu Tao
On Thu, Jul 28, 2011 at 10:15:21AM +0200, Michal Privoznik wrote: > On 27.07.2011 04:13, Hu Tao wrote: > >--- > > python/libvirt-override-api.xml |1 + > > python/libvirt-override.c | 94 > > +- > > 2 files changed, 92 insertions(+), 3 deletions(-)

Re: [libvirt] [PATCH 1/4] python: add python binding for virDomainGetBlkioParameters

2011-07-28 Thread Michal Privoznik
On 27.07.2011 04:13, Hu Tao wrote: --- python/libvirt-override-api.xml |6 +- python/libvirt-override.c | 79 +- 2 files changed, 79 insertions(+), 6 deletions(-) ACK It actually exposed we need this update: diff --git a/src/libvirt.c b/src/

Re: [libvirt] [PATCH 00/19] Rollback migration when libvirtd restarts

2011-07-28 Thread Wen Congyang
At 07/28/2011 05:41 AM, Eric Blake Write: > On 07/07/2011 05:34 PM, Jiri Denemark wrote: >> This series is also available at >> https://gitorious.org/~jirka/libvirt/jirka-staging/commits/migration-recovery >> >> >> The series does several things: >> - persists current job and its phase in status xm