Re: [libvirt] Compiling libvirt RPC client library for QNX

2014-02-24 Thread Roman Bogorodskiy
Panday Ritesh Sharma (rpanday) wrote: Thanks Roman for your response. Few questions which are not answered in that link. As I mentioned, my intent is to get only libvirt client library on QNX side not the whole libvirt. The libvirt daemon will still be running on linux box. The QNX

[libvirt] [PATCH] bhyve: implement node information reporting

2014-02-24 Thread Roman Bogorodskiy
- Implement nodeGetCPUStats using nodeGetCPUStats() - Implement nodeGetMemoryStats using nodeGetMemoryStats() --- src/bhyve/bhyve_driver.c | 29 + 1 file changed, 29 insertions(+) diff --git a/src/bhyve/bhyve_driver.c b/src/bhyve/bhyve_driver.c index 7c6500f..35171d2

Re: [libvirt] Entering freeze for libvirt-1.2.2

2014-02-24 Thread Stephan Sachse
what about this patch: [PATCH] lxc: Add virCgroupSetOwner() http://thread.gmane.org/gmane.comp.emulators.libvirt/92811 without this patch lxc + user namespace does not works with systemd /stephan -- Software is like sex, it's better when it's free! -- libvir-list mailing list

Re: [libvirt] [PATCH] Fix memory leak when lookup pool list with invalid type option

2014-02-24 Thread Martin Kletzander
On Mon, Feb 24, 2014 at 02:12:34PM +0800, shyu wrote: There will be memory leak when lookup pool list with invalid type option https://bugzilla.redhat.com/show_bug.cgi?id=1069068 ==23060== Memcheck, a memory error detector ==23060== Copyright (C) 2002-2012, and GNU GPL'd, by Julian Seward et

[libvirt] [PATCH] Document the keyboard as a valid input type

2014-02-24 Thread Ján Tomko
Commit bc18373 added a new input type, but didn't change the documentation. --- docs/formatdomain.html.in | 7 --- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/docs/formatdomain.html.in b/docs/formatdomain.html.in index ea1a97b..400de07 100644 --- a/docs/formatdomain.html.in

Re: [libvirt] Entering freeze for libvirt-1.2.2

2014-02-24 Thread Daniel Veillard
On Mon, Feb 24, 2014 at 09:46:55AM +0100, Stephan Sachse wrote: what about this patch: [PATCH] lxc: Add virCgroupSetOwner() http://thread.gmane.org/gmane.comp.emulators.libvirt/92811 without this patch lxc + user namespace does not works with systemd /stephan That's small enough and

Re: [libvirt] [PATCH 2/3] libvirt-guests: Wait for libirtd to initialize

2014-02-24 Thread Michal Privoznik
On 21.02.2014 18:28, Eric Blake wrote: On 02/21/2014 05:32 AM, Michal Privoznik wrote: s/libirtd/libvirtd/ in subject I've noticed that in some cases systemd was quick enough and even if libvirt-guests.service is marked to be started after the libvirtd.service my guests were not resumed as

Re: [libvirt] [PATCH v1 1/2] make qemu dump memory in kdump-compressed format

2014-02-24 Thread Daniel P. Berrange
On Thu, Feb 20, 2014 at 10:30:31AM +0800, Qiao Nuohan wrote: --memory-only option is introduced without compression supported. Therefore, this is a freature regression of virsh dump. Now qemu has support dumping memory in kdump-compressed format. This patch is used to add --compress and

Re: [libvirt] [PATCH] bhyve: implement node information reporting

2014-02-24 Thread Daniel P. Berrange
On Mon, Feb 24, 2014 at 12:30:38PM +0400, Roman Bogorodskiy wrote: - Implement nodeGetCPUStats using nodeGetCPUStats() - Implement nodeGetMemoryStats using nodeGetMemoryStats() --- src/bhyve/bhyve_driver.c | 29 + 1 file changed, 29 insertions(+) ACK Regards,

Re: [libvirt] [PATCH glib] Disable test suite unless glib = 2.38

2014-02-24 Thread Christophe Fergeau
On Thu, Feb 20, 2014 at 04:24:52PM +, Daniel P. Berrange wrote: diff --git a/tests/Makefile.am b/tests/Makefile.am index 56887ce..8cb98e5 100644 --- a/tests/Makefile.am +++ b/tests/Makefile.am @@ -1,3 +1,11 @@ +EXTRA_DIST = \ + xml/gconfig-domain.xml \ +

[libvirt] [libvirt-glib 0/2] Fix make distcheck

2014-02-24 Thread Christophe Fergeau
Hey, After the introduction of the GTest unit tests, make distcheck still has a few issues, with this series, make distcheck passes on my box (using glib 2.38). Christophe -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list

[libvirt] [libvirt-glib 2/2] tests: Fix make distcheck

2014-02-24 Thread Christophe Fergeau
Some files are missing from EXTRA_DIST, causing make distcheck to fail when tests are enabled. --- Makefile.am | 2 ++ tests/Makefile.am | 10 ++ 2 files changed, 12 insertions(+) diff --git a/Makefile.am b/Makefile.am index 0eba6e2..ae8b06d 100644 --- a/Makefile.am +++

[libvirt] [libvirt-glib 1/2] tests: Move EXTRA_DIST back into ENABLE_TESTS conditional

2014-02-24 Thread Christophe Fergeau
When deciding which files to put into the make dist tarball, automake is clever enough to ignore conditional blocks, and to pick all files which are needed for all values of the conditional. Having EXTRA_DIST=xxx at the beginning of tests/Makefile.am causes warnings from automake when

[libvirt] [PATCH v3] Add helper program to create custom leases

2014-02-24 Thread Nehal J Wani
Introduce helper program to catch events from dnsmasq and maintain a custom lease file per network. It supports dhcpv4 and dhcpv6. The file is saved as interface-name.status. Each lease contains the following info: expiry-time (epoch time) mac iaid ip-address hostname clientid Example of custom

[libvirt] Error while running event-test.c in Libvirt package

2014-02-24 Thread Avanti Ajay
Hello, I am trying to run event-test.c code available in libvirt-0.10.2 package under the folder /examples/domain-events/events-c. I am getting the following error /usr/bin/ld: cannot find -lvirt collect2: ld returned 1 exit status Please help me to solve this issue. -- libvir-list mailing

Re: [libvirt] [libvirt-glib 1/2] tests: Move EXTRA_DIST back into ENABLE_TESTS conditional

2014-02-24 Thread Daniel P. Berrange
On Mon, Feb 24, 2014 at 12:56:21PM +0100, Christophe Fergeau wrote: When deciding which files to put into the make dist tarball, automake is clever enough to ignore conditional blocks, and to pick all files which are needed for all values of the conditional. Having EXTRA_DIST=xxx at the

Re: [libvirt] [libvirt-glib 2/2] tests: Fix make distcheck

2014-02-24 Thread Daniel P. Berrange
On Mon, Feb 24, 2014 at 12:56:22PM +0100, Christophe Fergeau wrote: Some files are missing from EXTRA_DIST, causing make distcheck to fail when tests are enabled. --- Makefile.am | 2 ++ tests/Makefile.am | 10 ++ 2 files changed, 12 insertions(+) ACK Regards, Daniel --

Re: [libvirt] [PATCH v2] lxc: Add virCgroupSetOwner()

2014-02-24 Thread Daniel P. Berrange
On Fri, Feb 14, 2014 at 02:25:55PM +0100, Richard Weinberger wrote: diff --git a/src/util/vircgroup.c b/src/util/vircgroup.c index a6d60c5..4bef0db 100644 --- a/src/util/vircgroup.c +++ b/src/util/vircgroup.c @@ -3253,6 +3253,66 @@ cleanup: } +int virCgroupSetOwner(virCgroupPtr

Re: [libvirt] [PATCH v2] lxc: Add virCgroupSetOwner()

2014-02-24 Thread Richard Weinberger
Am 24.02.2014 13:20, schrieb Daniel P. Berrange: On Fri, Feb 14, 2014 at 02:25:55PM +0100, Richard Weinberger wrote: diff --git a/src/util/vircgroup.c b/src/util/vircgroup.c index a6d60c5..4bef0db 100644 --- a/src/util/vircgroup.c +++ b/src/util/vircgroup.c @@ -3253,6 +3253,66 @@ cleanup:

[libvirt] [PATCH v3] Ensure systemd cgroup ownership is delegated to container with userns

2014-02-24 Thread Daniel P. Berrange
From: Richard Weinberger rich...@nod.at This function is needed for user namespaces, where we need to chmod() the cgroup to the initial uid/gid such that systemd is allowed to use the cgroup. Signed-off-by: Richard Weinberger rich...@nod.at Signed-off-by: Daniel P. Berrange berra...@redhat.com

Re: [libvirt] Error while running event-test.c in Libvirt package

2014-02-24 Thread Martin Kletzander
On Mon, Feb 24, 2014 at 05:33:31PM +0530, Avanti Ajay wrote: Hello, I am trying to run event-test.c code available in libvirt-0.10.2 package under the folder /examples/domain-events/events-c. I am getting the following error /usr/bin/ld: cannot find -lvirt collect2: ld returned 1 exit

Re: [libvirt] [PATCH v2] lxc: Add virCgroupSetOwner()

2014-02-24 Thread Daniel P. Berrange
On Mon, Feb 24, 2014 at 01:25:04PM +0100, Richard Weinberger wrote: Am 24.02.2014 13:20, schrieb Daniel P. Berrange: On Fri, Feb 14, 2014 at 02:25:55PM +0100, Richard Weinberger wrote: diff --git a/src/util/vircgroup.c b/src/util/vircgroup.c index a6d60c5..4bef0db 100644 ---

Re: [libvirt] Entering freeze for libvirt-1.2.2

2014-02-24 Thread Daniel P. Berrange
On Mon, Feb 24, 2014 at 06:03:58PM +0800, Daniel Veillard wrote: On Mon, Feb 24, 2014 at 09:46:55AM +0100, Stephan Sachse wrote: what about this patch: [PATCH] lxc: Add virCgroupSetOwner() http://thread.gmane.org/gmane.comp.emulators.libvirt/92811 without this patch lxc + user

Re: [libvirt] Compiling libvirt RPC client library for QNX

2014-02-24 Thread Panday Ritesh Sharma (rpanday)
Hi Roman, Before I jump to the compilation of libvirt for QNX, I thought of compiling it on linux with my required options. So that I will be knowing what all files are of my use (from compilation log). For that I ran ./configure with below option and then tried 'make'. But 'make' complains there

Re: [libvirt] [PATCH v3] Ensure systemd cgroup ownership is delegated to container with userns

2014-02-24 Thread Martin Kletzander
On Mon, Feb 24, 2014 at 12:25:28PM +, Daniel P. Berrange wrote: From: Richard Weinberger rich...@nod.at This function is needed for user namespaces, where we need to chmod() the cgroup to the initial uid/gid such that systemd is allowed to use the cgroup. Signed-off-by: Richard

Re: [libvirt] [PATCH v3] Ensure systemd cgroup ownership is delegated to container with userns

2014-02-24 Thread Stephan Sachse
thanks, works for me. /stephan -- Software is like sex, it's better when it's free! -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list

[libvirt] [PATCH] virsh: Don't leak buffer if GetFDs fails in cmdCreate

2014-02-24 Thread Ján Tomko
Change the logic of the function to return false by default and move the freeing of the buffer to the cleanup section. https://bugzilla.redhat.com/show_bug.cgi?id=1067338 --- tools/virsh-domain.c | 29 - 1 file changed, 16 insertions(+), 13 deletions(-) diff --git

Re: [libvirt] [PATCH 3/4] libxl: add dump dir to libxlDriverConfig object

2014-02-24 Thread Michal Privoznik
On 21.02.2014 00:02, Jim Fehlig wrote: Signed-off-by: Jim Fehlig jfeh...@suse.com --- Without a libxl config file, I suppose the only thing needed here is the #define in libxl_conf.h. But I have a dusty series adding lockd support to the libxl driver, which I'll be cleaning off soon. That

Re: [libvirt] [PATCH 1/4] libxl: honor domain lifecycle event configuration

2014-02-24 Thread Michal Privoznik
On 21.02.2014 00:02, Jim Fehlig wrote: The libxl driver was ignoring the on_* domain event configuration, causing e.g. a domain to be rebooted even when on_reboot is set to destroy. This patch honors the on_* configuration in the shutdown event handler. Signed-off-by: Jim Fehlig

Re: [libvirt] [PATCH 4/4] libxl: handle on_crash coredump actions

2014-02-24 Thread Michal Privoznik
On 21.02.2014 00:02, Jim Fehlig wrote: Add support for coredump-{destroy,restart} actions of on_crash event. Signed-off-by: Jim Fehlig jfeh...@suse.com --- src/libxl/libxl_driver.c | 50 1 file changed, 50 insertions(+) diff --git

Re: [libvirt] [PATCH 2/4] libxl: queue domain event earlier in shutdown handler

2014-02-24 Thread Michal Privoznik
On 21.02.2014 00:02, Jim Fehlig wrote: The shutdown handler may restart a domain when handling a reboot event or when on_* is set to 'restart'. Restarting consists of calling libxlVmCleanup followed by libxlVmStart. libxlVmStart will emit a VIR_DOMAIN_EVENT_STARTED event, but the SHUTDOWN

Re: [libvirt] [PATCH 1/3] virSystemdCreateMachine: Set dependencies for slices

2014-02-24 Thread Cole Robinson
On 02/21/2014 07:32 AM, Michal Privoznik wrote: https://bugzilla.redhat.com/show_bug.cgi?id=1031696 When creating a new domain, we let systemd know about it by calling CreateMachine() function via dbus. Systemd then creates a scope and places domain into it. However, later when the host is

Re: [libvirt] Question about building libvirt.so

2014-02-24 Thread Christophe Fergeau
Hey, On Fri, Feb 21, 2014 at 07:30:08AM -0800, Vikhyath Reddy wrote: Thanks for the reply Cedric, wrappers is a dir that I made similar to examples which wraps the libvirt c code. The reason why I am doing this is to simplify the usage of virConnectOpenAuth - it's arguments and callbacks

Re: [libvirt] [PATCH] make virDomainGetMaxVcpus work on inactive domains

2014-02-24 Thread Michal Privoznik
On 19.02.2014 13:03, Claudio Bley wrote: Signed-off-by: Claudio Bley cb...@av-test.de --- OK, how about this patch? While at it, should I convert the VIR_DOMAIN_VCPU_* instances to VIR_DOMAIN_AFFECT_* instances for consistency? src/esx/esx_driver.c |2 +-

Re: [libvirt] [PATCH 1/4] libxl: honor domain lifecycle event configuration

2014-02-24 Thread Jim Fehlig
Michal Privoznik wrote: On 21.02.2014 00:02, Jim Fehlig wrote: The libxl driver was ignoring the on_* domain event configuration, causing e.g. a domain to be rebooted even when on_reboot is set to destroy. This patch honors the on_* configuration in the shutdown event handler.

Re: [libvirt] [PATCH] Fix memory leak when lookup pool list with invalid type option

2014-02-24 Thread shyu
- Original Message - | From: Martin Kletzander mklet...@redhat.com | To: shyu s...@redhat.com | Cc: libvir-list@redhat.com | Sent: Monday, February 24, 2014 4:48:01 PM | Subject: Re: [libvirt] [PATCH] Fix memory leak when lookup pool list with invalid type option | | On Mon, Feb 24,

Re: [libvirt] [PATCH] bhyve: implement node information reporting

2014-02-24 Thread Roman Bogorodskiy
Daniel P. Berrange wrote: On Mon, Feb 24, 2014 at 12:30:38PM +0400, Roman Bogorodskiy wrote: - Implement nodeGetCPUStats using nodeGetCPUStats() - Implement nodeGetMemoryStats using nodeGetMemoryStats() --- src/bhyve/bhyve_driver.c | 29 + 1 file changed,

Re: [libvirt] [PATCH 1/4] libxl: honor domain lifecycle event configuration

2014-02-24 Thread Michal Privoznik
On 24.02.2014 15:56, Jim Fehlig wrote: Michal Privoznik wrote: On 21.02.2014 00:02, Jim Fehlig wrote: The libxl driver was ignoring the on_* domain event configuration, causing e.g. a domain to be rebooted even when on_reboot is set to destroy. This patch honors the on_* configuration in the

[libvirt] [PATCH 3/3] gluster: Fix key attribute for gluster volumes

2014-02-24 Thread Peter Krempa
According to our documentation the key value has the following meaning: Providing an identifier for the volume which is globally unique. This cannot be set when creating a volume: it is always generated. The currently used keys for gluster volumes consist of the gluster volume name and file path.

[libvirt] [PATCH 0/3] Multiple fixes related to lookup of gluster volumes

2014-02-24 Thread Peter Krempa
Peter Krempa (3): storage: Don't lie about path used to look up in error message util: file: Don't sanitize URI protocol separator in virFileSanitizePath gluster: Fix key attribute for gluster volumes src/storage/storage_backend_gluster.c | 10 -- src/storage/storage_driver.c

[libvirt] [PATCH 2/3] util: file: Don't sanitize URI protocol separator in virFileSanitizePath

2014-02-24 Thread Peter Krempa
The function removes multiple following slashes from paths. This is okay unless you try to sanitize a URI this way. Skip the protocol definition until :// and sanitize just the path part. The sanitization function is used in virStorageVolLookupByPath as the first step before passing the path to

[libvirt] [PATCH 1/3] storage: Don't lie about path used to look up in error message

2014-02-24 Thread Peter Krempa
In storageVolLookupByPath the provided path is sanitized at first. This removes some extra slashes and stuff. When the lookup of the volume fails the original path is used which makes it hard to trace errors in some cases. Improve the error message to print the sanitized path along with the user

Re: [libvirt] [PATCH 1/4] libxl: honor domain lifecycle event configuration

2014-02-24 Thread Daniel P. Berrange
On Mon, Feb 24, 2014 at 04:17:52PM +0100, Michal Privoznik wrote: On 24.02.2014 15:56, Jim Fehlig wrote: Michal Privoznik wrote: On 21.02.2014 00:02, Jim Fehlig wrote: The libxl driver was ignoring the on_* domain event configuration, causing e.g. a domain to be rebooted even when on_reboot

Re: [libvirt] [PATCH 2/3] util: file: Don't sanitize URI protocol separator in virFileSanitizePath

2014-02-24 Thread Daniel P. Berrange
On Mon, Feb 24, 2014 at 04:21:47PM +0100, Peter Krempa wrote: The function removes multiple following slashes from paths. This is okay unless you try to sanitize a URI this way. Skip the protocol definition until :// and sanitize just the path part. The sanitization function is used in

Re: [libvirt] block pull/commit for non-local storage

2014-02-24 Thread Peter Krempa
On 02/20/14 15:37, Daniel P. Berrange wrote: On Thu, Feb 20, 2014 at 02:46:03PM +0100, Peter Krempa wrote: As you can see in the prototypes of these functions (and from the docs for them which I'm not going to copy here) the user can provide the disk specification in two possible options: 1)

Re: [libvirt] [PATCH 2/4] libxl: queue domain event earlier in shutdown handler

2014-02-24 Thread Jim Fehlig
Michal Privoznik wrote: On 21.02.2014 00:02, Jim Fehlig wrote: The shutdown handler may restart a domain when handling a reboot event or when on_* is set to 'restart'. Restarting consists of calling libxlVmCleanup followed by libxlVmStart. libxlVmStart will emit a VIR_DOMAIN_EVENT_STARTED

Re: [libvirt] [PATCH] cpu: break out when a right cpuCandidate found

2014-02-24 Thread Jiri Denemark
On Thu, Feb 13, 2014 at 07:44:20 +, Wangyufei (James) wrote: From 8123c5d64f940fa0fb0de32fc5e68035980b6b01 Mon Sep 17 00:00:00 2001 From: WangYufei james.wangyu...@huawei.com Date: Thu, 13 Feb 2014 07:17:11 + Subject: [PATCH] cpu: break out when a right cpuCandidate found In

[libvirt] RFE: Make saveDir/cacheDir/snapshotDir/dumpDir configurable and allow per-domain paths

2014-02-24 Thread Till Maas
Hi, I would like to separate all data of libvirt domains so that each domain can easily be deleted securely. However libvirt by default uses static directories to store data from domains such as snapshots, current states and dumps. Also a cache dir is used for reasons unknown to me. To separate

Re: [libvirt] [PATCH] Document the keyboard as a valid input type

2014-02-24 Thread Eric Blake
On 02/24/2014 02:55 AM, Ján Tomko wrote: Commit bc18373 added a new input type, but didn't change the documentation. --- docs/formatdomain.html.in | 7 --- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/docs/formatdomain.html.in b/docs/formatdomain.html.in index

Re: [libvirt] [PATCHv2 5/7] conf: new function virDomainActualNetDefContentsFormat

2014-02-24 Thread Michal Privoznik
On 21.02.2014 17:37, Laine Stump wrote: This function is currently only called from one place, but in a subsequent patch will be called from a 2nd place. The new function exactly replicates the original behavior of the part of virDomainActualNetDefFormat() that it replaces, but takes a

Re: [libvirt] [PATCH 7/7] network: include plugged interface XML in plugged network hook

2014-02-24 Thread Michal Privoznik
On 21.02.2014 14:58, Laine Stump wrote: The network hook script gets called whenever an interface is plugged into or unplugged from a network, but even though the full XML of both the network and the domain is included, there is no reasonable way to determine what exact resources the plugged

Re: [libvirt] [PATCH 3/7] conf: make virDomainNetDefFormat a public function

2014-02-24 Thread Michal Privoznik
On 21.02.2014 14:58, Laine Stump wrote: We will need to call virDomainNetDefFormat() from the network hook (in the network driver). --- src/conf/domain_conf.c | 2 +- src/conf/domain_conf.h | 4 src/libvirt_private.syms | 1 + 3 files changed, 6 insertions(+), 1 deletion(-) diff

Re: [libvirt] Compiling libvirt RPC client library for QNX

2014-02-24 Thread Eric Blake
On 02/24/2014 05:58 AM, Panday Ritesh Sharma (rpanday) wrote: [please don't top-post on technical lists] Hi Roman, Before I jump to the compilation of libvirt for QNX, I thought of compiling it on linux with my required options. So that I will be knowing what all files are of my use (from

Re: [libvirt] [PATCH 2/7] conf: handle null pointer in virNetDevVlanFormat

2014-02-24 Thread Michal Privoznik
On 21.02.2014 14:58, Laine Stump wrote: Other *Format() functions (e.g. virNetDevBandwidthFormat()) return with no action when called with a NULL *Def pointer. This makes virNetDevVlanFormat() consistent with that behavior. --- src/conf/netdev_vlan_conf.c | 4 ++-- 1 file changed, 2

Re: [libvirt] [PATCHv2 6/7] conf: output actual netdev status in interface XML

2014-02-24 Thread Michal Privoznik
On 21.02.2014 17:41, Laine Stump wrote: Until now, the live XML status of an interface type='network' device would always show the network information, rather than the exact hardware device that was used. It would also show the name any portgroup the interface belonged to, rather than providing

Re: [libvirt] [PATCH 4/7] conf: re-situate bandwidth element in interface

2014-02-24 Thread Michal Privoznik
On 21.02.2014 14:58, Laine Stump wrote: This moves the call to virNetDevBandwidthFormat() in virDomainNetDefFormat() to be called right after the call to virNetDevVPortProfileFormat(), so that a single chunk of that function can be placed inside an if that conditionally calls

Re: [libvirt] [PATCH 1/7] conf: clarify what is returned for actual bandwidth and vlan

2014-02-24 Thread Michal Privoznik
On 21.02.2014 14:58, Laine Stump wrote: In practice, if a virDomainNetDef has a virDomainActualNetDef allocated, the ActualNetDef will *always* contain the bandwidth and vlan data from the NetDef (unless there was also a portgroup involved - see networkAllocateActualDevice()). However,

Re: [libvirt] Compiling libvirt RPC client library for QNX

2014-02-24 Thread Eric Blake
On 02/22/2014 12:47 PM, Panday Ritesh Sharma (rpanday) wrote: HI Team, I have downloaded the libvirt source code from libvirt_0.9.8.orig.tar.gzhttps://launchpad.net/ubuntu/+archive/primary/+files/libvirt_0.9.8.orig.tar.gz . I just wanted libvirt RPC client library to be compiled for QNX.

[libvirt] [PATCH v2 0/8] Improve logging when QEMU caps fails

2014-02-24 Thread Daniel P. Berrange
A followup to https://www.redhat.com/archives/libvir-list/2014-February/msg01395.html In v2: - Added several docs improvements - Fixed typos - Add missing translation Daniel P. Berrange (8): Send virLogMetadata fields onto the journal Fix journald PRIORITY values Fix heading level

[libvirt] [PATCH v2 1/8] Send virLogMetadata fields onto the journal

2014-02-24 Thread Daniel P. Berrange
The systemd journal accepts arbitrary user specified log fields. These can be passed into virLogMessage via the virLogMetadata structure. Allow up to 5 custom fields to be reported by libvirt callers. Signed-off-by: Daniel P. Berrange berra...@redhat.com --- src/util/virlog.c | 18

[libvirt] [PATCH v2 2/8] Fix journald PRIORITY values

2014-02-24 Thread Daniel P. Berrange
The systemd journal expects log record PRIORITY values to be encoded using the syslog compatible numbering scheme, not libvirt's own native numbering scheme. We must therefore apply a conversion. Signed-off-by: Daniel P. Berrange berra...@redhat.com --- src/util/virlog.c | 22

[libvirt] [PATCH v2 8/8] Generate a unique journald log for QEMU capabilities failure

2014-02-24 Thread Daniel P. Berrange
When probing QEMU capabilities fails for a binary generate a log message with MESSAGE_ID==8ae2f3fb-2dbe-498e-8fbd-012d40afa361. This can be directly queried from journald based on the UUID instead of needing string grep. This lets tools like libguestfs' bug reporting tool trivially do automated

[libvirt] [PATCH v2 6/8] Include error domain and code in log messages from errors

2014-02-24 Thread Daniel P. Berrange
When a virError is raised, pass the error domain and code onto the systemd journald using metadata fields. This allows error messages to be queried by code eg $ journalctl LIBVIRT_CODE=43 Signed-off-by: Daniel P. Berrange berra...@redhat.com --- docs/logging.html.in | 4

[libvirt] [PATCH v2 4/8] Auto-generate the table of contents in logging doc

2014-02-24 Thread Daniel P. Berrange
The logging doc had a hand-written table of contents instead of using the automatic XSL generated one. Signed-off-by: Daniel P. Berrange berra...@redhat.com --- docs/logging.html.in | 21 - 1 file changed, 4 insertions(+), 17 deletions(-) diff --git a/docs/logging.html.in

[libvirt] [PATCH v2 5/8] Add docs about use of systemd journal for logging

2014-02-24 Thread Daniel P. Berrange
Document the various fields that libvirt will emit for journal log records. Signed-off-by: Daniel P. Berrange berra...@redhat.com --- docs/logging.html.in | 35 --- 1 file changed, 32 insertions(+), 3 deletions(-) diff --git a/docs/logging.html.in

[libvirt] [PATCH v2 3/8] Fix heading level in logging docs

2014-02-24 Thread Daniel P. Berrange
The logging docs went straight from h1 to h3 header level, skipping out h2. Signed-off-by: Daniel P. Berrange berra...@redhat.com --- docs/logging.html.in | 20 ++-- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/docs/logging.html.in b/docs/logging.html.in index

Re: [libvirt] [PATCH] virsh: Don't leak buffer if GetFDs fails in cmdCreate

2014-02-24 Thread Eric Blake
On 02/24/2014 06:29 AM, Ján Tomko wrote: Change the logic of the function to return false by default and move the freeing of the buffer to the cleanup section. https://bugzilla.redhat.com/show_bug.cgi?id=1067338 --- tools/virsh-domain.c | 29 - 1 file changed,

[libvirt] [PATCH v2 7/8] Add comments describing the different log sources

2014-02-24 Thread Daniel P. Berrange
Signed-off-by: Daniel P. Berrange berra...@redhat.com --- src/util/virlog.h | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/util/virlog.h b/src/util/virlog.h index f400824..6ba2daa 100644 --- a/src/util/virlog.h +++ b/src/util/virlog.h @@ -45,11 +45,11 @@

Re: [libvirt] block pull/commit for non-local storage

2014-02-24 Thread Eric Blake
On 02/24/2014 08:48 AM, Peter Krempa wrote: One further thing we should discuss is the block copy job, where we need to specify a new path that is not part of the backing chain of the disk where the disk gets copied (and efectively becomes the new single element of the backing chain). The for

Re: [libvirt] block pull/commit for non-local storage

2014-02-24 Thread Eric Blake
On 02/24/2014 09:53 AM, Eric Blake wrote: On 02/24/2014 08:48 AM, Peter Krempa wrote: One further thing we should discuss is the block copy job, where we need to specify a new path that is not part of the backing chain of the disk where the disk gets copied (and efectively becomes the new

Re: [libvirt] block pull/commit for non-local storage

2014-02-24 Thread Daniel P. Berrange
On Mon, Feb 24, 2014 at 09:53:59AM -0700, Eric Blake wrote: On 02/24/2014 08:48 AM, Peter Krempa wrote: One further thing we should discuss is the block copy job, where we need to specify a new path that is not part of the backing chain of the disk where the disk gets copied (and

Re: [libvirt] [PATCH] make virDomainGetMaxVcpus work on inactive domains

2014-02-24 Thread Eric Blake
On 02/19/2014 05:03 AM, Claudio Bley wrote: Signed-off-by: Claudio Bley cb...@av-test.de --- OK, how about this patch? While at it, should I convert the VIR_DOMAIN_VCPU_* instances to VIR_DOMAIN_AFFECT_* instances for consistency? Yes, making that conversion as a separate patch for

Re: [libvirt] [PATCH 2/2] virsh: kill over-engineered asprintf failure recovery

2014-02-24 Thread Michal Privoznik
On 21.02.2014 23:59, Eric Blake wrote: I noticed this while shortning switch statements via VIR_ENUM. Basically, the only ways virAsprintf can fail are if we pass a bogus format string (but we're not THAT bad) or if we run out of memory (but it already warns on our behalf in that case). Throw

Re: [libvirt] [PATCH 1/2] virsh: use more compact VIR_ENUM_IMPL

2014-02-24 Thread Michal Privoznik
On 21.02.2014 23:59, Eric Blake wrote: Dan Berrange suggested that using VIR_ENUM_IMPL is more compact than open-coding switch statements, and still just as forceful at making us remember to update lists if we add enum values in the future. Make this change throughout virsh. Sure enough, doing

Re: [libvirt] [PATCH 1/2] virsh: use more compact VIR_ENUM_IMPL

2014-02-24 Thread Eric Blake
On 02/24/2014 10:42 AM, Michal Privoznik wrote: +VIR_ENUM_DECL(vshDomainIOError) +VIR_ENUM_IMPL(vshDomainIOError, + VIR_DOMAIN_DISK_ERROR_LAST, + N_(no error), + N_(unspecified error), + N_(no space)) + -return _(unknown error); +

Re: [libvirt] [PATCH 1/2] virsh: use more compact VIR_ENUM_IMPL

2014-02-24 Thread Michal Privoznik
On 24.02.2014 18:49, Eric Blake wrote: On 02/24/2014 10:42 AM, Michal Privoznik wrote: +VIR_ENUM_DECL(vshDomainIOError) +VIR_ENUM_IMPL(vshDomainIOError, + VIR_DOMAIN_DISK_ERROR_LAST, + N_(no error), + N_(unspecified error), + N_(no space)) +

Re: [libvirt] [PATCH] Fix memory leak when lookup pool list with invalid type option

2014-02-24 Thread Eric Blake
On 02/24/2014 08:04 AM, shyu wrote: | And judging by the code, this is not upstream at all, right? I guess | this is not applicable upstream for half a year already, at least. | Please submit patches that apply on top of current master when cloning | from git://libvirt.org/libvirt.git . |

Re: [libvirt] [PATCH 1/3] storage: Don't lie about path used to look up in error message

2014-02-24 Thread Eric Blake
On 02/24/2014 08:21 AM, Peter Krempa wrote: In storageVolLookupByPath the provided path is sanitized at first. This removes some extra slashes and stuff. When the lookup of the volume fails the original path is used which makes it hard to trace errors in some cases. Improve the error

Re: [libvirt] [PATCH 2/3] util: file: Don't sanitize URI protocol separator in virFileSanitizePath

2014-02-24 Thread Eric Blake
On 02/24/2014 08:26 AM, Daniel P. Berrange wrote: On Mon, Feb 24, 2014 at 04:21:47PM +0100, Peter Krempa wrote: The function removes multiple following slashes from paths. This is okay unless you try to sanitize a URI this way. Skip the protocol definition until :// and sanitize just the path

Re: [libvirt] [PATCH] virsh: Don't leak buffer if GetFDs fails in cmdCreate

2014-02-24 Thread Ján Tomko
On 02/24/2014 05:49 PM, Eric Blake wrote: On 02/24/2014 06:29 AM, Ján Tomko wrote: Change the logic of the function to return false by default and move the freeing of the buffer to the cleanup section. https://bugzilla.redhat.com/show_bug.cgi?id=1067338 --- tools/virsh-domain.c | 29

Re: [libvirt] [PATCH] Document the keyboard as a valid input type

2014-02-24 Thread Ján Tomko
On 02/24/2014 05:39 PM, Eric Blake wrote: On 02/24/2014 02:55 AM, Ján Tomko wrote: Commit bc18373 added a new input type, but didn't change the documentation. --- docs/formatdomain.html.in | 7 --- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/docs/formatdomain.html.in

[libvirt] [PATCH V2] libxl: queue domain event earlier in shutdown handler

2014-02-24 Thread Jim Fehlig
The shutdown handler may restart a domain when handling a reboot event or when on_* is set to 'restart'. Restarting consists of calling libxlVmCleanup followed by libxlVmStart. libxlVmStart will emit a VIR_DOMAIN_EVENT_STARTED event, but the SHUTDOWN event is not emitted until exiting the

Re: [libvirt] [PATCH 0/3] Multiple fixes related to lookup of gluster volumes

2014-02-24 Thread Eric Blake
On 02/24/2014 08:21 AM, Peter Krempa wrote: Peter Krempa (3): storage: Don't lie about path used to look up in error message util: file: Don't sanitize URI protocol separator in virFileSanitizePath gluster: Fix key attribute for gluster volumes I haven't seen this one in my inbox

[libvirt] [PATCH] virsh: mark CPU usage field names as translatable

2014-02-24 Thread Ján Tomko
My commit ac75801 removed the translation markers when moving the field names into an array. --- tools/virsh-host.c | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/tools/virsh-host.c b/tools/virsh-host.c index 502203b..6a04f9d 100644 --- a/tools/virsh-host.c +++

Re: [libvirt] [PATCH 1/4] libxl: honor domain lifecycle event configuration

2014-02-24 Thread Jim Fehlig
Michal Privoznik wrote: On 24.02.2014 15:56, Jim Fehlig wrote: Can this series be pushed for 1.2.2? If so, I'll squash in your changes and push later today. Thanks for the review! Regards, Jim I think these patches are bugfix. Which allows us to push them even in freeze. Also note

Re: [libvirt] [PATCH] virsh: mark CPU usage field names as translatable

2014-02-24 Thread Eric Blake
On 02/24/2014 11:11 AM, Ján Tomko wrote: My commit ac75801 removed the translation markers when moving the field names into an array. --- tools/virsh-host.c | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions(-) ACK. -- Eric Blake eblake redhat com+1-919-301-3266

Re: [libvirt] [PATCH 2/2] virsh: kill over-engineered asprintf failure recovery

2014-02-24 Thread Eric Blake
On 02/24/2014 10:42 AM, Michal Privoznik wrote: On 21.02.2014 23:59, Eric Blake wrote: I noticed this while shortning switch statements via VIR_ENUM. Basically, the only ways virAsprintf can fail are if we pass a bogus format string (but we're not THAT bad) or if we run out of memory (but it

[libvirt] [PATCH] qemu: cleanup tap devices on FreeBSD

2014-02-24 Thread Roman Bogorodskiy
We have to explicitly destroy TAP devices on FreeBSD because they're not freed after being closed, otherwise we end up with orphaned TAP devices after destroying a domain. --- src/qemu/qemu_process.c | 7 +++ 1 file changed, 7 insertions(+) diff --git a/src/qemu/qemu_process.c

Re: [libvirt] [PATCH 7/7] network: include plugged interface XML in plugged network hook

2014-02-24 Thread Laine Stump
On 02/24/2014 06:45 PM, Michal Privoznik wrote: On 21.02.2014 14:58, Laine Stump wrote: The network hook script gets called whenever an interface is plugged into or unplugged from a network, but even though the full XML of both the network and the domain is included, there is no reasonable way

Re: [libvirt] [PATCH 7/7] network: include plugged interface XML in plugged network hook

2014-02-24 Thread Eric Blake
On 02/24/2014 12:27 PM, Laine Stump wrote: ACK although the indentation of XML we're passing to the hook script seems off: Right. That's what the last paragraph of the commit log message is about - fixing that indentation would require a much more invasive change that would touch all the

[libvirt] QEMU accepted for Google Summer of Code 2014

2014-02-24 Thread Stefan Hajnoczi
Great news: the organizations for Google Summer of Code 2014 have been announced and QEMU is participating again this year! If you are a student who is interested in a 12-week full-time project working on QEMU, KVM, or libvirt this summer, head over to our project ideas page:

Re: [libvirt] [PATCH 3/3] gluster: Fix key attribute for gluster volumes

2014-02-24 Thread Eric Blake
On 02/24/2014 08:21 AM, Peter Krempa wrote: According to our documentation the key value has the following meaning: Providing an identifier for the volume which is globally unique. This cannot be set when creating a volume: it is always generated. The currently used keys for gluster volumes

[libvirt] [PATCH] virsh: support remaining domain events

2014-02-24 Thread Eric Blake
Earlier, I added 'virsh event' for lifecycle events, to get the concept approved; this patch finishes the support for all other events, although the user still has to register for one event type at a time. A future patch may add an --all parameter to make it possible to register for all events

[libvirt] [PATCH 2/1] virsh: add --all flag to 'event' command

2014-02-24 Thread Eric Blake
Similar to our event-test demo program, it's nice to be able to have a mode where we can sniff all events at once, rather than having to spawn multiple virsh in parallel with one for each event type. (Can I just say our RegisterAny design is lousy? The fact that the majority of our callback

Re: [libvirt] Question about building libvirt.so

2014-02-24 Thread vikhyath reddy
Thanks for the replies guys, libvirt-glib sure sounds interesting. On the other hand I was able to leave libvirt.so alone and write my own wrapper (based on libvirt/examples) for easy calls from NodeJS. I can get to list VMs, their config etc. from node but not able to list the operating system

Re: [libvirt] [PATCH] make virDomainGetMaxVcpus work on inactive domains

2014-02-24 Thread Jim Fehlig
Claudio Bley wrote: At Thu, 20 Feb 2014 12:19:35 -0700, Jim Fehlig wrote: Claudio Bley wrote: Signed-off-by: Claudio Bley cb...@av-test.de --- OK, how about this patch? While at it, should I convert the VIR_DOMAIN_VCPU_* instances to VIR_DOMAIN_AFFECT_* instances for

Re: [libvirt] [PATCH v1 1/2] make qemu dump memory in kdump-compressed format

2014-02-24 Thread Qiao Nuohan
On 02/24/2014 06:30 PM, Daniel P. Berrange wrote: On Thu, Feb 20, 2014 at 10:30:31AM +0800, Qiao Nuohan wrote: --memory-only option is introduced without compression supported. Therefore, this is a freature regression of virsh dump. Now qemu has support dumping memory in kdump-compressed

Re: [libvirt] Question about building libvirt.so

2014-02-24 Thread Eric Blake
On 02/24/2014 05:09 PM, vikhyath reddy wrote: [Please don't top-post on technical lists] Thanks for the replies guys, libvirt-glib sure sounds interesting. On the other hand I was able to leave libvirt.so alone and write my own wrapper (based on libvirt/examples) for easy calls from NodeJS. I

Re: [libvirt] [PATCH v2] libvirt support to force convergence of live guest migration

2014-02-24 Thread Jim Fehlig
Chegu Vinod wrote: Hello, 'am sending this updated patch as an attachment (as I was having some issues with my smtp server and git send-email setup). Thanks, Vinod Subject: [PATCH v2] libvirt support to force convergence of live guest migration Changes since RFC (i.e. v1) patch : -

[libvirt] [PATCH] virsh: initialize str to NULL for solving a build issue

2014-02-24 Thread Chen Hanxiao
Fix a -Werror=maybe-uninitialized issue. Signed-off-by: Chen Hanxiao chenhanx...@cn.fujitsu.com --- tools/virsh-domain-monitor.c | 2 +- tools/virsh-domain.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/virsh-domain-monitor.c b/tools/virsh-domain-monitor.c

  1   2   >