[libvirt] [PATCH 5/5] libvirtd: Fix order of cleanup processing

2017-11-07 Thread John Ferlan
Current cleanup processing is ad-hoc at best - it's led to a couple of strange and hard to diagnose timing problems and crashes. So rather than perform cleanup in a somewhat random order, let's perform cleanup in the exact opposite order of startup. Signed-off-by: John Ferlan

[libvirt] [PATCH 4/5] libvirtd: Alter refcnt processing for server program objects

2017-11-07 Thread John Ferlan
Instead of holding onto the reference for each program added to a NetServer, let's Unref the program reference as soon as the attempt is made to add to the @srv->programs list. This then allows the virNetServerDispose to handle the final Unref of the object for actual deletion and cleans up the

[libvirt] [PATCH 1/5] libvirtd: Move pid_file_fd setup to before run_dir

2017-11-07 Thread John Ferlan
Once we have forked the daemon successfully, let's claim the pidfile immediately rather than waiting for setup of run_dir. Signed-off-by: John Ferlan --- daemon/libvirtd.c | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/daemon/libvirtd.c

[libvirt] [PATCH 2/5] libvirtd: Alter order of virNetDaemonNew

2017-11-07 Thread John Ferlan
Let's be sure we can get a Daemon object before the server object. This is a more "orderly" way to do things since the svr object would be added to the dmn object afterwards. Signed-off-by: John Ferlan --- daemon/libvirtd.c | 8 ++-- 1 file changed, 6 insertions(+), 2

[libvirt] [PATCH 3/5] libvirtd: Alter refcnt processing for domain server objects

2017-11-07 Thread John Ferlan
Whether the @srv/@srvAdm is added to the dmn->servers list or not, the reference kept for the allocation can be dropped leaving just the reference for being on the dmn->servers list be the sole deciding factor when to really free the associated memory. The @dmn dispose function

[libvirt] [PATCH 0/5] libvirtd: Adjustments to startup and cleanup processing

2017-11-07 Thread John Ferlan
Essentially a followup from the review of: daemon: fix termination/reload issues https://www.redhat.com/archives/libvir-list/2017-October/msg01347.html and in particular patch 3/3, a review which has exteneded into Nov.: https://www.redhat.com/archives/libvir-list/2017-November/msg00066.html

Re: [libvirt] [PATCH v3 4/5] qemu: Use predictable file names for memory-backend-file

2017-11-07 Thread John Ferlan
On 11/07/2017 10:51 AM, Michal Privoznik wrote: > In some cases management application needs to allocate memory for > qemu upfront and then just let qemu use that. Since we don't want > to expose path for memory-backend-file anywhere in the domain > XML, we can generate predictable paths. In

Re: [libvirt] [PATCH 4/4] tests: Add caps for QEMU 2.10.0 on ppc64

2017-11-07 Thread John Ferlan
On 11/06/2017 08:26 AM, Andrea Bolognani wrote: > Signed-off-by: Andrea Bolognani > --- > .../qemucapabilitiesdata/caps_2.10.0.ppc64.replies | 20572 > +++ > tests/qemucapabilitiesdata/caps_2.10.0.ppc64.xml | 1072 + > tests/qemucapabilitiestest.c

Re: [libvirt] [PATCH 3/4] tests: Rename ppc64le caps to ppc64

2017-11-07 Thread John Ferlan
On 11/06/2017 08:26 AM, Andrea Bolognani wrote: > The architecture itself is called ppc64, and it can run both in big > endian and little endian mode - the latter is known as ppc64le. > >>From the (virtual) hardware point of view, ppc64 is a more accurate > name so it should be used here. > >

[libvirt] [PATCH 3/2] news: Update for vbox 5.2 support

2017-11-07 Thread Dawid Zamirski
--- docs/news.xml | 5 + 1 file changed, 5 insertions(+) diff --git a/docs/news.xml b/docs/news.xml index 9361a9165..630784a0a 100644 --- a/docs/news.xml +++ b/docs/news.xml @@ -37,6 +37,11 @@ + + + vbox: Add VirtualBox 5.2 support + +

Re: [libvirt] Libvirt config converter can't handle file not ending with new line

2017-11-07 Thread Jim Fehlig
On 11/07/2017 08:54 AM, Wim ten Have wrote: On Tue, 7 Nov 2017 12:20:05 + Wei Liu wrote: On Mon, Nov 06, 2017 at 09:41:01PM -0700, Jim Fehlig wrote: On 10/30/2017 06:17 AM, Wei Liu wrote: Hi Jim I discover a problem when using xen_xl converter. When the file in

[libvirt] [PATCH 1/2] vbox: Add vbox 5.2 CAPI header file.

2017-11-07 Thread Dawid Zamirski
Extracted from 5.2 SDK and reindented with cppi 0001-vbox-Add-vbox-5.2-CAPI-header-file.tar.xz Description: application/xz-compressed-tar -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list

[libvirt] [PATCH] virconf: properly set the end of content

2017-11-07 Thread Jim Fehlig
There was a recent report of the xen-xl converter not handling config files missing an ending newline https://www.redhat.com/archives/libvir-list/2017-October/msg01353.html Commit 3cc2a9e0 fixed a similar problem when parsing content of a file but missed parsing in-memory content. But AFAICT,

[libvirt] [PATCH 2/2] vbox: Add support for 5.2.x

2017-11-07 Thread Dawid Zamirski
Simply add the 5.2 SDK header to the existing unified framework. No other special handling is needed as there's no API break between exising 5.1 and the just added 5.2. --- src/Makefile.am | 1 + src/vbox/vbox_V5_2.c | 13 + src/vbox/vbox_common.h| 2

[libvirt] [PATCH 0/2] vbox: Add support for 5.2.x

2017-11-07 Thread Dawid Zamirski
With each minor VBOX release a new SDK header needs to be added and wired up to the driver. This is basically the same as last time [1]. The first patch will be sent as a compressed attachment because it's a large header file taken from the SDK that would not pass the mailing list size

Re: [libvirt] [PATCH 2/4] tests: Add caps for QEMU 2.10.0 on aarch64 (GICv3)

2017-11-07 Thread John Ferlan
On 11/06/2017 08:26 AM, Andrea Bolognani wrote: > Signed-off-by: Andrea Bolognani > --- > .../caps_2.10.0-gicv3.aarch64.replies | 16535 > +++ > .../caps_2.10.0-gicv3.aarch64.xml | 303 + > tests/qemucapabilitiestest.c

Re: [libvirt] [PATCH 1/4] tests: Add caps for QEMU 2.10.0 on aarch64 (GICv2)

2017-11-07 Thread John Ferlan
On 11/06/2017 08:26 AM, Andrea Bolognani wrote: > Signed-off-by: Andrea Bolognani > --- > .../caps_2.10.0-gicv2.aarch64.replies | 16535 > +++ > .../caps_2.10.0-gicv2.aarch64.xml | 303 + > tests/qemucapabilitiestest.c

Re: [libvirt] [PATCH 0/3] cputest: Add more CPU data files

2017-11-07 Thread John Ferlan
On 11/02/2017 03:57 PM, Jiri Denemark wrote: > Jiri Denemark (3): > cputest: Do not drop v[0-9] from CPU names > cputest: Add data for Intel(R) Xeon(R) CPU E5-2650 v4 > cputest: Add data for Intel(R) Core(TM) i7-7700 CPU > Looks reasonable to me... Passes build, syntax-check

Re: [libvirt] [PATCH 1/2] docs: Update vbox driver documentation.

2017-11-07 Thread Dawid Zamirski
On Tue, 2017-11-07 at 17:05 -0500, John Ferlan wrote: > > On 11/07/2017 04:36 PM, Dawid Zamirski wrote: > > * libvirt no longer supports vbox <= 3.x > > * update XML definition sample to show how to attach disks to > > VBOX's SAS > > controller and how to change IDE controller model. > > *

Re: [libvirt] [PATCH 0/2] Update documentation for latest vbox changes.

2017-11-07 Thread John Ferlan
On 11/07/2017 04:36 PM, Dawid Zamirski wrote: > * update docs/drvvbox.html.in to show support for > * update docs/fomatdomain.html.in to describe autoport behavior in the > vbox driver > > Dawid Zamirski (2): > docs: Update vbox driver documentation. > docs: Document autoport behavior in

Re: [libvirt] [PATCH 1/2] docs: Update vbox driver documentation.

2017-11-07 Thread John Ferlan
On 11/07/2017 04:36 PM, Dawid Zamirski wrote: > * libvirt no longer supports vbox <= 3.x > * update XML definition sample to show how to attach disks to VBOX's SAS > controller and how to change IDE controller model. > * update XML to show how to create RDP display with autoport. > --- >

Re: [libvirt] [PATCH v3 0/5] Predictable file names for memory-backend-file

2017-11-07 Thread John Ferlan
On 11/07/2017 10:50 AM, Michal Privoznik wrote: > v3 of: > > https://www.redhat.com/archives/libvir-list/2017-October/msg01091.html > > diff to v2: > - Pushed 1/4 and 2/4 from the original series > - Split 3/4 into smaller patches > > Michal Privoznik (5): > qemu: Set alias for memory cell

Re: [libvirt] [PATCH v3 5/5] news: Document predictable file names for memory-backend-file

2017-11-07 Thread John Ferlan
On 11/07/2017 10:51 AM, Michal Privoznik wrote: > Signed-off-by: Michal Privoznik > --- > docs/news.xml | 11 +++ > 1 file changed, 11 insertions(+) > > diff --git a/docs/news.xml b/docs/news.xml > index ef855d895..fb0ded97c 100644 > --- a/docs/news.xml > +++

[libvirt] [PATCH 2/2] docs: Document autoport behavior in the vbox driver

2017-11-07 Thread Dawid Zamirski
--- docs/formatdomain.html.in | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/docs/formatdomain.html.in b/docs/formatdomain.html.in index 92e14a919..d3cabac44 100644 --- a/docs/formatdomain.html.in +++ b/docs/formatdomain.html.in @@ -6100,7 +6100,10 @@ qemu-kvm -net

[libvirt] [PATCH 0/2] Update documentation for latest vbox changes.

2017-11-07 Thread Dawid Zamirski
* update docs/drvvbox.html.in to show support for * update docs/fomatdomain.html.in to describe autoport behavior in the vbox driver Dawid Zamirski (2): docs: Update vbox driver documentation. docs: Document autoport behavior in the vbox driver docs/drvvbox.html.in | 28

[libvirt] [PATCH 1/2] docs: Update vbox driver documentation.

2017-11-07 Thread Dawid Zamirski
* libvirt no longer supports vbox <= 3.x * update XML definition sample to show how to attach disks to VBOX's SAS controller and how to change IDE controller model. * update XML to show how to create RDP display with autoport. --- docs/drvvbox.html.in | 28 +++- 1 file

Re: [libvirt] [PATCH v3 3/5] qemu: Destroy whole memory tree

2017-11-07 Thread John Ferlan
On 11/07/2017 10:51 AM, Michal Privoznik wrote: > When removing path where huge pages are call virFileDeleteTree > instead of plain rmdir(). The reason is that in the near future > there's going to be more in the path than just files - some > subdirs. Therefore plain rmdir() is not going to be

Re: [libvirt] [PATCH v3 2/5] qemu: Rename qemuProcessBuildDestroyHugepagesPath

2017-11-07 Thread John Ferlan
On 11/07/2017 10:51 AM, Michal Privoznik wrote: > At the same time, move its internals into a separate function so > that they can be reused. > > Signed-off-by: Michal Privoznik > --- > src/qemu/qemu_hotplug.c | 2 +- > src/qemu/qemu_process.c | 76 >

Re: [libvirt] [PATCH v3 13/13] docs: Update news.xml with vbox changes.

2017-11-07 Thread John Ferlan
On 11/07/2017 01:49 PM, Dawid Zamirski wrote: > --- > docs/news.xml | 74 > +++ > 1 file changed, 74 insertions(+) > Perhaps more verbose than some would like, but I'm perfectly fine with it! There's a couple of syntax things... Which

Re: [libvirt] [PATCH v3 00/13] vbox: Improve handling of storage devices

2017-11-07 Thread John Ferlan
On 11/07/2017 01:49 PM, Dawid Zamirski wrote: > v2: > https://www.redhat.com/archives/libvir-list/2017-October/msg01108.html > > Changes since v2: > * Rebase on master > * Do not segfault in 'Cleanup partially-defined VM on failure' when >code jumps to cleanup and machine is NULL > *

Re: [libvirt] [PATCH v3 08/13] vbox: Correctly generate drive name in dumpxml

2017-11-07 Thread John Ferlan
On 11/07/2017 01:49 PM, Dawid Zamirski wrote: > If a VBOX VM has e.g. a SATA and SCSI disk attached, the XML generated > by dumpxml used to produce "sda" for both of those disks. This is an > invalid domain XML as libvirt does not allow duplicate device names. To > address this, keep the running

Re: [libvirt] [PATCH] numa: avoid failure in nodememstats on non-NUMA systems

2017-11-07 Thread John Ferlan
On 09/22/2017 10:12 AM, Viktor Mihajlovski wrote: > libvirt reports a fake NUMA topology in virConnectGetCapabilities > even if built without numactl support. The fake NUMA topology consists > of a single cell representing the host's cpu and memory resources. > Currently this is the case for ARM

[libvirt] [PATCH go-xml] Add support for host paravirt bootloader, used by Xen and bhyve.

2017-11-07 Thread Brandon Bergren
--- domain.go | 2 ++ domain_test.go | 16 2 files changed, 18 insertions(+) diff --git a/domain.go b/domain.go index aea54a5..debc5b2 100644 --- a/domain.go +++ b/domain.go @@ -797,6 +797,8 @@ type Domain struct { VCPU*DomainVCPU `xml:"vcpu"`

Re: [libvirt] [PATCH v2 12/15] vbox: Correctly generate drive name in dumpxml

2017-11-07 Thread Dawid Zamirski
On Fri, 2017-11-03 at 09:52 -0400, John Ferlan wrote: > > On 10/24/2017 03:35 PM, Dawid Zamirski wrote: > > If a VBOX VM has e.g. a SATA and SCSI disk attached, the XML > > generated > > by dumpxml used to produce "sda" for both of those disks. This is > > an > > invalid domain XML as libvirt

[libvirt] [PATCH v3 02/13] vbox: Process element in domain XML

2017-11-07 Thread Dawid Zamirski
With this patch, the vbox driver will no longer attach all supported storage controllers by default even if no disk devices are associated with them. Instead, it will attach only those that are implicitly added by virDomainDefAddImplicitController based on element or if explicitly specified via

[libvirt] [PATCH v3 13/13] docs: Update news.xml with vbox changes.

2017-11-07 Thread Dawid Zamirski
--- docs/news.xml | 74 +++ 1 file changed, 74 insertions(+) diff --git a/docs/news.xml b/docs/news.xml index ef855d895..454c63d8b 100644 --- a/docs/news.xml +++ b/docs/news.xml @@ -37,8 +37,82 @@ + + +

[libvirt] [PATCH v3 04/13] vbox: Rename vboxDumpIDEHDDs to vboxDumpDisks

2017-11-07 Thread Dawid Zamirski
Because it deals with other disk types as well not just IDE. Also this function now returns -1 on error --- src/vbox/vbox_common.c | 57 ++ 1 file changed, 25 insertions(+), 32 deletions(-) diff --git a/src/vbox/vbox_common.c

[libvirt] [PATCH v3 08/13] vbox: Correctly generate drive name in dumpxml

2017-11-07 Thread Dawid Zamirski
If a VBOX VM has e.g. a SATA and SCSI disk attached, the XML generated by dumpxml used to produce "sda" for both of those disks. This is an invalid domain XML as libvirt does not allow duplicate device names. To address this, keep the running total of disks that will use "sd" prefix for device

[libvirt] [PATCH v3 05/13] vbox: Cleanup/prepare snasphot dumpxml functions

2017-11-07 Thread Dawid Zamirski
This patch prepares the vboxSnapshotGetReadOnlyDisks and vboxSnapshotGetReadWriteDisks functions for further changes so that the code movement does not obstruct the gist of those future changes. This is done primarily because we'll need to know the type of vbox storage controller as early as

[libvirt] [PATCH v3 11/13] vbox: Generate disk address element in dumpxml

2017-11-07 Thread Dawid Zamirski
This patch adds element to each device since device names alone won't adequately reflect the storage device layout in the VM. With this patch, the ouput produced by dumpxml will faithfully reproduce the storage layout of the VM if used with define. --- src/vbox/vbox_common.c | 51

[libvirt] [PATCH v3 03/13] vbox: Add vboxDumpStorageControllers

2017-11-07 Thread Dawid Zamirski
--- src/vbox/vbox_common.c | 109 + 1 file changed, 109 insertions(+) diff --git a/src/vbox/vbox_common.c b/src/vbox/vbox_common.c index 49df52c12..4d596075c 100644 --- a/src/vbox/vbox_common.c +++ b/src/vbox/vbox_common.c @@ -3147,6 +3147,113 @@

[libvirt] [PATCH v3 06/13] vbox: Do not free disk definitions on cleanup

2017-11-07 Thread Dawid Zamirski
Both vboxSnapshotGetReadWriteDisks and vboxSnapshotGetReadWriteDisks do not need to free the def->disks on cleanup because it's being done by the caller via virDomainSnaphotDefFree --- src/vbox/vbox_common.c | 14 ++ 1 file changed, 2 insertions(+), 12 deletions(-) diff --git

[libvirt] [PATCH v3 09/13] vbox: Cleanup vboxDumpDisks implementation

2017-11-07 Thread Dawid Zamirski
Primer the code for further changes: * move variable declarations to the top of the function * group together free/release statements * error check and report VBOX API calls used --- src/vbox/vbox_common.c | 190 +++-- 1 file changed, 122

[libvirt] [PATCH v3 10/13] vbox: Process empty removable disks in dumpxml

2017-11-07 Thread Dawid Zamirski
Previously any removable storage device without media attached was omitted from domain XML dump. They're still (rightfully) omitted in snapshot XMl dump but need to be accounted properly to for the device names to stay in 'sync' between domain and snapshot XML dumps. --- src/vbox/vbox_common.c |

[libvirt] [PATCH v3 12/13] vbox: Add SAS controller support

2017-11-07 Thread Dawid Zamirski
In VirtualBox SAS and SCSI are separate controller types whereas libvirt does not make such distinction. This patch adds support for attaching the VBOX SAS controllers by mapping the 'lsisas1068' controller model in libvirt XML to VBOX SAS controller type. If VBOX VM has disks attached to both

[libvirt] [PATCH v3 07/13] vbox: Swap vboxSnapshotGetReadOnlyDisks arguments

2017-11-07 Thread Dawid Zamirski
So that the function signature matches vboxSnapshotGetReadWriteDisks --- src/vbox/vbox_common.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/vbox/vbox_common.c b/src/vbox/vbox_common.c index 79030e36e..4d39beb1e 100644 --- a/src/vbox/vbox_common.c +++

[libvirt] [PATCH v3 00/13] vbox: Improve handling of storage devices

2017-11-07 Thread Dawid Zamirski
v2: https://www.redhat.com/archives/libvir-list/2017-October/msg01108.html Changes since v2: * Rebase on master * Do not segfault in 'Cleanup partially-defined VM on failure' when code jumps to cleanup and machine is NULL * Take out SAS controller handling code into a separate patch *

Re: [libvirt] [PATCH v3 4/5] qemu: Use predictable file names for memory-backend-file

2017-11-07 Thread Martin Kletzander
On Tue, Nov 07, 2017 at 03:57:45PM +, Daniel P. Berrange wrote: On Tue, Nov 07, 2017 at 04:51:03PM +0100, Michal Privoznik wrote: In some cases management application needs to allocate memory for qemu upfront and then just let qemu use that. Since we don't want to expose path for

Re: [libvirt] [PATCH v5 3/3] libvirtd: fix crash on termination

2017-11-07 Thread Erik Skultety
On Tue, Nov 07, 2017 at 10:28:10AM -0500, John Ferlan wrote: > > > On 11/07/2017 04:46 AM, Martin Kletzander wrote: > > On Mon, Nov 06, 2017 at 03:20:13PM -0500, John Ferlan wrote: > >> > >> > >> On 11/03/2017 05:20 AM, Nikolay Shirokovskiy wrote: > >>> > >>> > >>> On 03.11.2017 11:42, Martin

Re: [libvirt] [PATCH 0/2] Misc apparmor fixes

2017-11-07 Thread Michal Privoznik
On 11/03/2017 09:46 AM, Christian Ehrhardt wrote: > Hi, > here a few more apparmor fixes for your review. > > One is for an Ubuntu bug [1] which is non fatal, but denies a qemu fix to > fully work. > The other one I was carried in Ubuntu for some time and is related to ipv6 > only setups where

Re: [libvirt] [PATCH v3 4/5] qemu: Use predictable file names for memory-backend-file

2017-11-07 Thread Michal Privoznik
On 11/07/2017 04:57 PM, Daniel P. Berrange wrote: > On Tue, Nov 07, 2017 at 04:51:03PM +0100, Michal Privoznik wrote: >> In some cases management application needs to allocate memory for >> qemu upfront and then just let qemu use that. Since we don't want >> to expose path for memory-backend-file

Re: [libvirt] [PATCH v3 4/5] qemu: Use predictable file names for memory-backend-file

2017-11-07 Thread Daniel P. Berrange
On Tue, Nov 07, 2017 at 04:51:03PM +0100, Michal Privoznik wrote: > In some cases management application needs to allocate memory for > qemu upfront and then just let qemu use that. Since we don't want > to expose path for memory-backend-file anywhere in the domain > XML, we can generate

Re: [libvirt] Libvirt config converter can't handle file not ending with new line

2017-11-07 Thread Wim ten Have
On Tue, 7 Nov 2017 12:20:05 + Wei Liu wrote: > On Mon, Nov 06, 2017 at 09:41:01PM -0700, Jim Fehlig wrote: > > On 10/30/2017 06:17 AM, Wei Liu wrote: > > > Hi Jim > > > > > > I discover a problem when using xen_xl converter. When the file in > > > question doesn't end

[libvirt] [PATCH v3 1/5] qemu: Set alias for memory cell in qemuBuildMemoryCellBackendStr

2017-11-07 Thread Michal Privoznik
Very soon qemuBuildMemoryBackendStr() is going to use memory cell aliases. Therefore set one. At the same time, move it a bit further - if virAsprintf() fails, there's no point in setting rest of the members. Signed-off-by: Michal Privoznik --- src/qemu/qemu_command.c | 7

[libvirt] [PATCH v3 3/5] qemu: Destroy whole memory tree

2017-11-07 Thread Michal Privoznik
When removing path where huge pages are call virFileDeleteTree instead of plain rmdir(). The reason is that in the near future there's going to be more in the path than just files - some subdirs. Therefore plain rmdir() is not going to be enough. Signed-off-by: Michal Privoznik

Re: [libvirt] Should we switch to a different JSON library?

2017-11-07 Thread Neal Gompa
On Tue, Nov 7, 2017 at 9:34 AM, Martin Kletzander wrote: > On Tue, Nov 07, 2017 at 01:38:51PM +, Richard W.M. Jones wrote: >> >> On Tue, Nov 07, 2017 at 01:28:00PM +, Daniel P. Berrange wrote: >>> >>> On Tue, Nov 07, 2017 at 02:05:25PM +0100, Martin Kletzander wrote:

[libvirt] [PATCH v3 5/5] news: Document predictable file names for memory-backend-file

2017-11-07 Thread Michal Privoznik
Signed-off-by: Michal Privoznik --- docs/news.xml | 11 +++ 1 file changed, 11 insertions(+) diff --git a/docs/news.xml b/docs/news.xml index ef855d895..fb0ded97c 100644 --- a/docs/news.xml +++ b/docs/news.xml @@ -37,6 +37,17 @@ + + +

[libvirt] [PATCH v3 2/5] qemu: Rename qemuProcessBuildDestroyHugepagesPath

2017-11-07 Thread Michal Privoznik
At the same time, move its internals into a separate function so that they can be reused. Signed-off-by: Michal Privoznik --- src/qemu/qemu_hotplug.c | 2 +- src/qemu/qemu_process.c | 76 + src/qemu/qemu_process.h | 8 +++---

[libvirt] [PATCH v3 4/5] qemu: Use predictable file names for memory-backend-file

2017-11-07 Thread Michal Privoznik
In some cases management application needs to allocate memory for qemu upfront and then just let qemu use that. Since we don't want to expose path for memory-backend-file anywhere in the domain XML, we can generate predictable paths. In this case:

[libvirt] [PATCH v3 0/5] Predictable file names for memory-backend-file

2017-11-07 Thread Michal Privoznik
v3 of: https://www.redhat.com/archives/libvir-list/2017-October/msg01091.html diff to v2: - Pushed 1/4 and 2/4 from the original series - Split 3/4 into smaller patches Michal Privoznik (5): qemu: Set alias for memory cell in qemuBuildMemoryCellBackendStr qemu: Rename

Re: [libvirt] [PATCH 06/12] qemu: block: Add JSON props generator for iSCSI protocol

2017-11-07 Thread Ján Tomko
On Tue, Nov 07, 2017 at 04:04:02PM +0100, Peter Krempa wrote: On Sun, Nov 05, 2017 at 16:03:25 +0100, Ján Tomko wrote: On Fri, Nov 03, 2017 at 03:29:23PM +0100, Peter Krempa wrote: > From: John Ferlan > > --- > +static virJSONValuePtr >

Re: [libvirt] [PATCH v5 3/3] libvirtd: fix crash on termination

2017-11-07 Thread John Ferlan
On 11/07/2017 04:46 AM, Martin Kletzander wrote: > On Mon, Nov 06, 2017 at 03:20:13PM -0500, John Ferlan wrote: >> >> >> On 11/03/2017 05:20 AM, Nikolay Shirokovskiy wrote: >>> >>> >>> On 03.11.2017 11:42, Martin Kletzander wrote: On Fri, Nov 03, 2017 at 11:07:36AM +0300, Nikolay

[libvirt] [PATCH] util: storage: Fix parsing of IPv6 portal address for iSCSI

2017-11-07 Thread Peter Krempa
Split on the last colon and avoid parsing port if the split remainder contains the closing square bracket, so that IPv6 addresses are interpreted correctly. --- src/util/virstoragefile.c | 3 ++- tests/virstoragetest.c| 20 2 files changed, 22 insertions(+), 1

Re: [libvirt] [PATCH 1/2] storage: Resolve storage driver crash

2017-11-07 Thread Cedric Bosdonnat
On Tue, 2017-11-07 at 08:43 -0500, John Ferlan wrote: > > On 11/07/2017 04:18 AM, Cedric Bosdonnat wrote: > > On Mon, 2017-11-06 at 15:53 -0500, John Ferlan wrote: > > > Resolve a storage driver crash as a result of a long running > > > storageVolCreateXML when the virStorageVolPoolRefreshThread

Re: [libvirt] [PATCH v3 REBASE v2 0/2] qemu: report block job errors from qemu to the user

2017-11-07 Thread Nikolay Shirokovskiy
ping On 27.10.2017 15:37, Nikolay Shirokovskiy wrote: > So that you can see nice report on migration: > > "error: operation failed: migration of disk sda failed: No space left on > device" > > diff from v2: > > 1. split into 2 patches > 2. change formal documentation where it is

Re: [libvirt] [PATCH 06/12] qemu: block: Add JSON props generator for iSCSI protocol

2017-11-07 Thread Peter Krempa
On Sun, Nov 05, 2017 at 16:03:25 +0100, Ján Tomko wrote: > On Fri, Nov 03, 2017 at 03:29:23PM +0100, Peter Krempa wrote: > > From: John Ferlan > > > > --- > > +static virJSONValuePtr > > +qemuBlockStorageSourceGetISCSIProps(virStorageSourcePtr src) > > +{ > > [...] > > > +

Re: [libvirt] Should we switch to a different JSON library?

2017-11-07 Thread Martin Kletzander
On Tue, Nov 07, 2017 at 01:28:00PM +, Daniel P. Berrange wrote: On Tue, Nov 07, 2017 at 02:05:25PM +0100, Martin Kletzander wrote: Hi everyone, so we are using yajl for parsing JSON. However there are some reasons why we might consider switching to another one: 1) It is basically dead

Re: [libvirt] Should we switch to a different JSON library?

2017-11-07 Thread Martin Kletzander
On Tue, Nov 07, 2017 at 01:38:51PM +, Richard W.M. Jones wrote: On Tue, Nov 07, 2017 at 01:28:00PM +, Daniel P. Berrange wrote: On Tue, Nov 07, 2017 at 02:05:25PM +0100, Martin Kletzander wrote: > 4) The are workarounds for it in the code I don't recall what these are now ? I

Re: [libvirt] [PATCH 1/2] storage: Resolve storage driver crash

2017-11-07 Thread John Ferlan
On 11/07/2017 04:18 AM, Cedric Bosdonnat wrote: > On Mon, 2017-11-06 at 15:53 -0500, John Ferlan wrote: >> Resolve a storage driver crash as a result of a long running >> storageVolCreateXML when the virStorageVolPoolRefreshThread is >> run as a result of a storageVolUpload complete and ran the

Re: [libvirt] [PATCH 1/2] storage: Resolve storage driver crash

2017-11-07 Thread John Ferlan
On 11/07/2017 04:36 AM, Ján Tomko wrote: > On Mon, Nov 06, 2017 at 03:53:08PM -0500, John Ferlan wrote: >> Resolve a storage driver crash as a result of a long running >> storageVolCreateXML when the virStorageVolPoolRefreshThread is >> run as a result of a storageVolUpload complete and ran the

Re: [libvirt] Should we switch to a different JSON library?

2017-11-07 Thread Richard W.M. Jones
On Tue, Nov 07, 2017 at 01:28:00PM +, Daniel P. Berrange wrote: > On Tue, Nov 07, 2017 at 02:05:25PM +0100, Martin Kletzander wrote: > > 4) The are workarounds for it in the code > > I don't recall what these are now ? libguestfs needs to disable some warnings around yajl code: /* GCC

Re: [libvirt] Should we switch to a different JSON library?

2017-11-07 Thread Daniel P. Berrange
On Tue, Nov 07, 2017 at 02:05:25PM +0100, Martin Kletzander wrote: > Hi everyone, > > so we are using yajl for parsing JSON. However there are some reasons > why we might consider switching to another one: > > 1) It is basically dead upstream One could say that it is simply "feature complete"

[libvirt] Should we switch to a different JSON library?

2017-11-07 Thread Martin Kletzander
Hi everyone, so we are using yajl for parsing JSON. However there are some reasons why we might consider switching to another one: 1) It is basically dead upstream 2) We're just using the lexer part of it 3) We only use it for parsing 4) The are workarounds for it in the code So I looked

[libvirt] [PATCH 08/11] tools: Provide bash autompletion file

2017-11-07 Thread Michal Privoznik
Signed-off-by: Michal Privoznik --- configure.ac | 3 ++ libvirt.spec.in| 2 ++ m4/virt-bash-completion.m4 | 74 ++ tools/Makefile.am | 22 -- tools/bash-completion/vsh | 73

[libvirt] [PATCH 11/11] virt-admin: Introduce vshAdmServerCompleter

2017-11-07 Thread Michal Privoznik
Signed-off-by: Michal Privoznik --- tools/Makefile.am| 9 ++ tools/virt-admin-completer.c | 76 tools/virt-admin-completer.h | 33 +++ tools/virt-admin.c | 8 + 4 files changed, 126

[libvirt] [PATCH 03/11] vsh: Add @silent to vshConnectionHook

2017-11-07 Thread Michal Privoznik
In near future we will want to not report error when connecting fails. In order to achieve that we have to pass a boolean that suppresses error messages. Signed-off-by: Michal Privoznik --- tools/virsh-domain.c | 2 +- tools/virsh.c| 67

[libvirt] [PATCH 02/11] vshCommandOpt: Relax check for valid options

2017-11-07 Thread Michal Privoznik
When trying to get an opt for command typed on the command line we first check if command has such option. Because if it doesn't it is a programming error. For instance: vshCommandOptBool(cmd, "config") called from say cmdStart() doesn't make sense since there's no --config for the start command.

[libvirt] [PATCH 10/11] virsh: Introduce virshDomainInterfaceCompleter

2017-11-07 Thread Michal Privoznik
Signed-off-by: Michal Privoznik --- tools/virsh-completer.c | 60 tools/virsh-completer.h | 8 ++ tools/virsh-domain-monitor.c | 3 +++ tools/virsh-domain.c | 4 +++ 4 files changed, 75 insertions(+) diff

[libvirt] [PATCH 00/11] Make auto completion better

2017-11-07 Thread Michal Privoznik
After initial RFC [1] I had some time to work on this and here is the result. What's implemented? === Auto completion for both interactive and non-interactive virsh/virt-admin. Known limitations = Currently, just options completers work. I mean, to bring up list

[libvirt] [PATCH 06/11] vshCompleter: Pass partially parsed command

2017-11-07 Thread Michal Privoznik
The callback we're calling might need to make decisions on already passed arguments. For instance, a completer that is supposed to bring up list of domain's interfaces might want to see what domain user wants to work with. Signed-off-by: Michal Privoznik --- tools/vsh.c | 7

[libvirt] [PATCH 05/11] vsh: Call vshCmdOptDef.completer properly

2017-11-07 Thread Michal Privoznik
The idea is that .completer for vshCmdOptDef would be called if the last token on the input is a cmd opt. For instance: virsh # start --domain However, with current code that's not happening. Signed-off-by: Michal Privoznik --- tools/vsh.c | 45

[libvirt] [PATCH 04/11] vsh: Fix vshCompleter signature

2017-11-07 Thread Michal Privoznik
The first argument passed to this function is vshControl *. There's no need to use void pointer. Signed-off-by: Michal Privoznik --- tools/vsh.c | 2 +- tools/vsh.h | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/tools/vsh.c b/tools/vsh.c index

[libvirt] [PATCH 09/11] virsh: Introduce virshDomainNameCompleter

2017-11-07 Thread Michal Privoznik
Signed-off-by: Michal Privoznik --- tools/Makefile.am| 9 +++ tools/virsh-completer.c | 90 + tools/virsh-completer.h | 33 tools/virsh-domain-monitor.c | 30 +++ tools/virsh-domain.c | 182

[libvirt] [PATCH 01/11] vshCommandStringParse: Allow retrieving partial result

2017-11-07 Thread Michal Privoznik
In the future, this function is going to be called from vshReadlineParse() to provide parsed input for completer callbacks. The idea is to allow the callbacks to provide more specific data. For instance, for the following input: virsh # domifaddr --domain fedora --interface the --interface

[libvirt] [PATCH 07/11] vsh: Introduce complete command

2017-11-07 Thread Michal Privoznik
This command is going to be called from bash completion script in the following form: virsh complete "start --domain" Its only purpose is to return list of possible strings for completion. Note that this is a 'hidden', unlisted command and therefore there's no documentation to it.

Re: [libvirt] Libvirt config converter can't handle file not ending with new line

2017-11-07 Thread Wei Liu
On Mon, Nov 06, 2017 at 09:41:01PM -0700, Jim Fehlig wrote: > On 10/30/2017 06:17 AM, Wei Liu wrote: > > Hi Jim > > > > I discover a problem when using xen_xl converter. When the file in > > question doesn't end with a new line, I get the following error: > > > >error: configuration file

Re: [libvirt] [PATCH REPOST 0/8] Privatize _virStoragePoolObj and _virStorageVolDefList (Batch #3)

2017-11-07 Thread Erik Skultety
On Fri, Oct 06, 2017 at 10:42:54AM -0400, John Ferlan wrote: > Since the original series (19 patches): > > https://www.redhat.com/archives/libvir-list/2017-September/msg00594.html > > didn't garner any attention, I'm going with smaller patch piles to make > forward progress. > > This is the last

Re: [libvirt] [PATCH 0/7] x86: Rework KVM-defaults compat code, enable kvm_pv_unhalt by default

2017-11-07 Thread Paolo Bonzini
On 14/10/2017 01:56, Eduardo Habkost wrote: > Now, I don't know yet what's the best default for a guest that > has CONFIG_PARAVIRT_SPINLOCK when it sees a host that supports > kvm_pv_unhalt. But I'm arguing that it's the guest > responsibility to choose what to do when it detects such a host, >

Re: [libvirt] [PATCH v5 3/3] libvirtd: fix crash on termination

2017-11-07 Thread Martin Kletzander
On Mon, Nov 06, 2017 at 03:20:13PM -0500, John Ferlan wrote: On 11/03/2017 05:20 AM, Nikolay Shirokovskiy wrote: On 03.11.2017 11:42, Martin Kletzander wrote: On Fri, Nov 03, 2017 at 11:07:36AM +0300, Nikolay Shirokovskiy wrote: On 02.11.2017 19:32, Martin Kletzander wrote: This just

Re: [libvirt] [PATCH 1/2] storage: Resolve storage driver crash

2017-11-07 Thread Ján Tomko
On Mon, Nov 06, 2017 at 03:53:08PM -0500, John Ferlan wrote: Resolve a storage driver crash as a result of a long running storageVolCreateXML when the virStorageVolPoolRefreshThread is run as a result of a storageVolUpload complete and ran the virStoragePoolObjClearVols without checking if the

Re: [libvirt] [PATCH v2] vz: allow to start vz driver without host cache info

2017-11-07 Thread Martin Kletzander
On Tue, Nov 07, 2017 at 12:02:05PM +0300, Mikhail Feoktistov wrote: On 11.07.2017 15:55, Martin Kletzander wrote: On Tue, Jul 11, 2017 at 03:20:38PM +0300, Mikhail Feoktistov wrote: On 11.07.2017 12:22, Martin Kletzander wrote: On Tue, Jul 11, 2017 at 04:59:05AM -0400, Mikhail Feoktistov

Re: [libvirt] [PATCH 2/2] scsi: Check for long running create in FCRefreshThread

2017-11-07 Thread Cedric Bosdonnat
On Mon, 2017-11-06 at 15:53 -0500, John Ferlan wrote: > Similar to a recent patch in virStorageVolPoolRefreshThread to ensure > that there were no pool AsyncJobs (e.g. nothing being created at the > time in a long running buildVol job), modify virStoragePoolFCRefreshThread > to check for async

Re: [libvirt] [PATCH 1/2] storage: Resolve storage driver crash

2017-11-07 Thread Cedric Bosdonnat
On Mon, 2017-11-06 at 15:53 -0500, John Ferlan wrote: > Resolve a storage driver crash as a result of a long running > storageVolCreateXML when the virStorageVolPoolRefreshThread is > run as a result of a storageVolUpload complete and ran the > virStoragePoolObjClearVols without checking if the

Re: [libvirt] Interim fix for exposing VMware firmware=bios|efi in libvirt XML

2017-11-07 Thread Daniel P. Berrange
On Tue, Nov 07, 2017 at 09:09:07AM +, Richard W.M. Jones wrote: > https://bugzilla.redhat.com/show_bug.cgi?id=1217444 > > VMware guests can use either BIOS or UEFI firmware. VMware itself > exposes this information in the VMX file and it's available to the ESX > driver in libvirt. virt-v2v

[libvirt] Interim fix for exposing VMware firmware=bios|efi in libvirt XML

2017-11-07 Thread Richard W.M. Jones
https://bugzilla.redhat.com/show_bug.cgi?id=1217444 VMware guests can use either BIOS or UEFI firmware. VMware itself exposes this information in the VMX file and it's available to the ESX driver in libvirt. virt-v2v wants to consume this information. Unfortunately after a few years and

Re: [libvirt] [PATCH v2] vz: allow to start vz driver without host cache info

2017-11-07 Thread Mikhail Feoktistov
On 11.07.2017 15:55, Martin Kletzander wrote: On Tue, Jul 11, 2017 at 03:20:38PM +0300, Mikhail Feoktistov wrote: On 11.07.2017 12:22, Martin Kletzander wrote: On Tue, Jul 11, 2017 at 04:59:05AM -0400, Mikhail Feoktistov wrote: Show warning message instead of fail operation. It happens if