Re: [libvirt] [PATCH 15/16] tests: Add tests for caches into vircaps2xmltest

2017-03-30 Thread Eli Qiao
> Okay, cool, this comes better than my patches and have some differences. I am open with this as long as that it can meet cache allocation requires and everyone will be happy. I am ++ for this. But I am not sure expose all of cache information in the capabilities XML. > > + > + > >

Re: [libvirt] [PATCH 06/16] util: Add virSysfsDirOpen

2017-03-30 Thread Eli Qiao
On Thursday, 30 March 2017 at 10:03 PM, Martin Kletzander wrote: > Signed-off-by: Martin Kletzander (mailto:mklet...@redhat.com)> > --- > src/libvirt_private.syms | 1 + > src/util/virsysfs.c | 17 - > src/util/virsysfs.h | 6 ++ > 3 files changed, 23

Re: [libvirt] [PATCH V2 1/2] util: Add more virsysfs functions for handling resctrl sysfs

2017-03-30 Thread Eli Qiao
> > +# util/virresctrl.h > > +virResCtrlAvailable; > > +virResCtrlInit; > > + > > > > > This has nothing to do in the patch > Okay, this should be involved by mistake while rebasing. > > > # util/virrotatingfile.h > > virRotatingFileReaderConsume; > > virRotatingFileReaderFree; > > @@

Re: [libvirt] [PATCH] news: Make changes understandable for users

2017-03-30 Thread John Ferlan
On 03/30/2017 01:52 PM, Andrea Bolognani wrote: > On Thu, 2017-03-30 at 13:05 -0400, John Ferlan wrote: >>> I guess it's very much a case-by-case situation. For >>> example, we have one entry in the release notes that >>> consists of just: >>> >>>Fix compilation on macOS >>> >>> and

Re: [libvirt] [PATCH 00/11] hyperv: add support for Hyper-V 2012 and newer.

2017-03-30 Thread Matthias Bolte
2017-03-30 18:47 GMT+02:00 Dawid Zamirski : > Hello, > > The following patch series reworks the hyper-v driver structs and the > code generator to provide seamless support for both Hyper-V 2008 and > 2012 or newer. This does not implement any new libvirt APIs, it just > adapts

[libvirt] [PATCH v3 08/11] hyperv: update wmi code generator.

2017-03-30 Thread Dawid Zamirski
This patch updates the code generator that outputs C headers and code for WMI classes. It has been updated to handle multiple versions (or namespaces) of the same class which were introduced with Hyperv 2012+ --- changes in v3: * do not change file mode * restore accidentally deleted copyright

Re: [libvirt] [PATCH v2 8/11] hyperv: update wmi code generator.

2017-03-30 Thread Dawid Zamirski
On Thu, 2017-03-30 at 16:24 -0400, Dawid Zamirski wrote: > On Thu, 2017-03-30 at 16:07 -0400, Neal Gompa wrote: > > On Thu, Mar 30, 2017 at 2:00 PM, Dawid Zamirski > m> > > > > > b/src/hyperv/hyperv_wmi_generator.py > > > old mode 100755 > > > new mode 100644 > > > > Why

Re: [libvirt] [PATCH v2 8/11] hyperv: update wmi code generator.

2017-03-30 Thread Dawid Zamirski
On Thu, 2017-03-30 at 16:07 -0400, Neal Gompa wrote: > On Thu, Mar 30, 2017 at 2:00 PM, Dawid Zamirski > > > b/src/hyperv/hyperv_wmi_generator.py > > old mode 100755 > > new mode 100644 > > Why are you changing the mode of the file? > > > index 8c62882..21934fd > > ---

Re: [libvirt] [PATCH v2 8/11] hyperv: update wmi code generator.

2017-03-30 Thread Neal Gompa
On Thu, Mar 30, 2017 at 2:00 PM, Dawid Zamirski wrote: > This patch updates the code generator that outputs C headers and code > for WMI classes. It has been updated to handle multiple versions (or > namespaces) of the same class which were introduced with Hyperv 2012+ > ---

Re: [libvirt] [PATCH 2/2] news: Allow empty elements

2017-03-30 Thread Martin Kletzander
On Thu, Mar 30, 2017 at 03:45:27PM +0200, Andrea Bolognani wrote: Creating dummy elements was a workaround for the HTML DTD not allowing empty elements, but we can do better by tweaking the the XSLT stylesheet. --- docs/news-html.xsl| 8 +--- docs/news.xml | 9 -

[libvirt] [PATCH v2 8/11] hyperv: update wmi code generator.

2017-03-30 Thread Dawid Zamirski
This patch updates the code generator that outputs C headers and code for WMI classes. It has been updated to handle multiple versions (or namespaces) of the same class which were introduced with Hyperv 2012+ --- changes in v2: * make it pass "make syntax-check"

Re: [libvirt] [PATCH] news: Make changes understandable for users

2017-03-30 Thread Andrea Bolognani
On Thu, 2017-03-30 at 13:05 -0400, John Ferlan wrote: > > I guess it's very much a case-by-case situation. For > > example, we have one entry in the release notes that > > consists of just: > >  > >   Fix compilation on macOS > >  > > and that's okay, because there's nothing else to it: > >

Re: [libvirt] [PATCH] news: Make changes understandable for users

2017-03-30 Thread John Ferlan
On 03/30/2017 11:26 AM, Andrea Bolognani wrote: > On Wed, 2017-03-29 at 06:34 -0400, John Ferlan wrote: >> I find it ironic that I went against my normal practice and tried not to >> be verbose. Just copying the git commit id message for a one liner. And >> now it's turning into a more lengthy

[libvirt] [PATCH 00/11] hyperv: add support for Hyper-V 2012 and newer.

2017-03-30 Thread Dawid Zamirski
Hello, The following patch series reworks the hyper-v driver structs and the code generator to provide seamless support for both Hyper-V 2008 and 2012 or newer. This does not implement any new libvirt APIs, it just adapts existing 2008-only driver to also handle 2012 and newer by sharing as much

[libvirt] [PATCH 05/11] hyperv: add hypervWqlQuery struct.

2017-03-30 Thread Dawid Zamirski
This struct is to be passed to enumerate-and-pull wsman request (to run "Select" queries) and provides the hypervWmiClassInfoListPtr instance from which we can extract the version specific info using the new hypervGetWmiClassInfo function (currently unused) --- src/hyperv/hyperv_wmi.c | 35

Re: [libvirt] [PATCH 00/11] hyperv: add support for Hyper-V 2012 and newer.

2017-03-30 Thread Dawid Zamirski
On Thu, 2017-03-30 at 12:47 -0400, Dawid Zamirski wrote: > Hello, > > The following patch series reworks the hyper-v driver structs and the > code generator to provide seamless support for both Hyper-V 2008 and > 2012 or newer. This does not implement any new libvirt APIs, it just > adapts

[libvirt] [PATCH 11/11] hyperv: add hypervInitConnection.

2017-03-30 Thread Dawid Zamirski
This function detects hyperv version by issuing a simple query using "v2" namespace and falling back to "v1". --- src/hyperv/hyperv_driver.c | 92 -- 1 file changed, 56 insertions(+), 36 deletions(-) diff --git a/src/hyperv/hyperv_driver.c

[libvirt] [PATCH 01/11] hyperv: fixed typo in function name.

2017-03-30 Thread Dawid Zamirski
that is: s/hyperyVerifyresponse/hypervVerifyResponse/ --- src/hyperv/hyperv_wmi.c | 8 src/hyperv/hyperv_wmi.h | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/hyperv/hyperv_wmi.c b/src/hyperv/hyperv_wmi.c index 13acd09..947101f 100644 ---

[libvirt] [PATCH 08/11] hyperv: update wmi code generator.

2017-03-30 Thread Dawid Zamirski
This patch updates the code generator that outputs C headers and code for WMI classes. It has been updated to handle multiple versions (or namespaces) of the same class which were introduced with Hyperv 2012+ --- src/hyperv/hyperv_wmi_generator.py | 409 + 1

[libvirt] [PATCH 09/11] hyperv: add helper for getting WMI class lists.

2017-03-30 Thread Dawid Zamirski
Those used to be auto-generated and are hand-written now intead. The reason being that those are not very useful and better replacements are in order once the driver itself implements more of the API and common patterns start to emerge. --- src/Makefile.am | 2 -

[libvirt] [PATCH 06/11] hyperv: make hypervEnumAndPull use hypervWqlQuery

2017-03-30 Thread Dawid Zamirski
This enables this function to handle "v1" and "v2" WMI requests. Since this commit is where complilation breakage starts: * commits that follow should be squashed into this one * rename hypervObjectUnified -> hypervObject as we've already broken compilation here so there's no point in keeping

[libvirt] [PATCH 03/11] hyperv: introduce hypervWmiClassInfo struct.

2017-03-30 Thread Dawid Zamirski
This struct is to be used to carry all the information necessary to issue wsman requests for given WMI class. Those will be defined by the generator code (as lists) so that they are handy for the driver code to "extract" needed info depending on which hyper-v we're connected to. For example:

[libvirt] [PATCH 07/11] hyperv: update generator input file.

2017-03-30 Thread Dawid Zamirski
Adds defintiions for "v2" WMI class variants that are needed by the driver to handle both hyperv 2008 and 2012+ --- src/hyperv/hyperv_wmi_generator.input | 239 +- 1 file changed, 206 insertions(+), 33 deletions(-) diff --git

[libvirt] [PATCH 10/11] hyperv: port rest of the driver to new stucts.

2017-03-30 Thread Dawid Zamirski
basically s/data->/data.common->/ Because the data member of hypervObject is a union, get the data via the "common" member everywhere - existing driver does not require special handling for v1 vs v2 separately. --- src/hyperv/hyperv_driver.c | 76 +++---

[libvirt] [PATCH 04/11] hyperv: update hypervObject struct.

2017-03-30 Thread Dawid Zamirski
Currently named as hypervObjecUnified to keep code compilable/functional until all bits are in place. This struct is a result of unserializing WMI request response. Therefore, it needs to be able to deal with different "versions" of the same WMI class. To accomplish this, the "data" member was

[libvirt] [PATCH 02/11] hyperv: store WMI version in hypervPrivate.

2017-03-30 Thread Dawid Zamirski
Hyper-V 2012+ uses a new "v2" version of Msvm_* WMI classes so we will store that info in hypervPrivate so that it is easily accessbile in the driver API callbacks and handled accordingly. --- src/hyperv/hyperv_private.h | 8 +++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git

Re: [libvirt] [PATCH 1/2] networkUpdateState: Create virMacMap module more frequently

2017-03-30 Thread Laine Stump
On 03/28/2017 05:08 AM, Michal Privoznik wrote: > On 03/28/2017 02:22 AM, Laine Stump wrote: >> On 03/22/2017 10:43 AM, Michal Privoznik wrote: > >> >>> >>> Signed-off-by: Michal Privoznik >>> --- >>> src/network/bridge_driver.c | 21 + >>> 1 file

Re: [libvirt] [PATCH] network: Drop unused networkRestartRadvd

2017-03-30 Thread Laine Stump
On 03/29/2017 04:02 AM, Michal Privoznik wrote: > Since its introduction in 1ce4922e720 this function lived as an > outcast in an #if 0 block. My memory is faint now, but I believe radvd as a whole is now nearly unused, since dnsmasq gained the same functionality (route advertisement) soon after

Re: [libvirt] [PATCH] news: Make changes understandable for users

2017-03-30 Thread Andrea Bolognani
On Wed, 2017-03-29 at 06:34 -0400, John Ferlan wrote: > I find it ironic that I went against my normal practice and tried not to > be verbose. Just copying the git commit id message for a one liner. And > now it's turning into a more lengthy description. I guess it's very much a case-by-case

[libvirt] [PATCH v2 0/5] Fix gluster pool lookup issues

2017-03-30 Thread Peter Krempa
Peter Krempa (5): storage: util: Add boolean differentiating between gluster lookup type storage: util: Split out the gluster volume extraction code into new function test: Introduce testing of virStorageUtilGlusterExtractPoolSources storage: Fix XPath for looking up gluster volume

[libvirt] [PATCH v2 2/5] storage: util: Split out the gluster volume extraction code into new function

2017-03-30 Thread Peter Krempa
To allow testing of the algorithm, split out the extractor into a separate helper. --- src/storage/storage_util.c | 95 +++--- src/storage/storage_util.h | 4 ++ 2 files changed, 59 insertions(+), 40 deletions(-) diff --git a/src/storage/storage_util.c

[libvirt] [PATCH v2 3/5] test: Introduce testing of virStorageUtilGlusterExtractPoolSources

2017-03-30 Thread Peter Krempa
Add a test program called virstorageutiltest and test the gluster pool detection code. --- tests/Makefile.am | 15 ++- .../gluster-parse-basic-native.xml | 6 ++ .../gluster-parse-basic-netfs.xml | 7 ++

[libvirt] [PATCH v2 5/5] storage: gluster: Use volume name as "" field in the XML

2017-03-30 Thread Peter Krempa
For native gluster pools the field denotes a directory inside the pool. For the actual pool name the field has to be used. --- src/storage/storage_util.c| 15 --- tests/virstorageutildata/gluster-parse-basic-native.xml | 3 ++-

[libvirt] [PATCH v2 4/5] storage: Fix XPath for looking up gluster volume name

2017-03-30 Thread Peter Krempa
Use the relative lookup specifier rather than the global one. Otherwise only the first name would be looked up. Add a test case to cover the scenario. Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1436574 --- src/storage/storage_util.c | 2 +-

[libvirt] [PATCH v2 1/5] storage: util: Add boolean differentiating between gluster lookup type

2017-03-30 Thread Peter Krempa
The native gluster pool source list data differs from the data used for attaching gluster volumes as netfs pools. Currently the only difference was the format. Since native pools don't use it and later there will be more difference add a boolean to swithc between the types instead. ---

Re: [libvirt] Availability of libvirt-3.2.0 RC2

2017-03-30 Thread Daniel Veillard
On Thu, Mar 30, 2017 at 04:03:54PM +0200, Martin Kletzander wrote: > On Thu, Mar 30, 2017 at 11:27:43AM +0200, Daniel Veillard wrote: > > So the Release Candidate 2 is tagged in git and signed tarball and rpms > > are available from the usual place: > > > > ftp://libvirt.org/libvirt/ > > > >

Re: [libvirt] Live attaching a disk to a VM fails with apparmor enabled

2017-03-30 Thread Frank Schreuder
Hello Guido, I have great news. I'm able to successfully live attach a disk to a running VM with a loaded apparmor profile. My setup: Debian 8 Kernel 4.9.11 Libvirt 3.1.0 Apparmor 2.10 from Debian backports With same software and apparmor 2.9 from the stable Debian repo it fails. So

[libvirt] [PATCH 16/16] Init host cache info in drivers

2017-03-30 Thread Martin Kletzander
Added only in drivers that were already calling virCapabilitiesInitNUMA(). Instead of refactoring all the callers to behave the same way in case of error, just follow what the callers are doing for all the functions. Signed-off-by: Martin Kletzander --- src/lxc/lxc_conf.c

[libvirt] [PATCH 08/16] util: Use virStringTrimOptionalNewline in virFileRead*

2017-03-30 Thread Martin Kletzander
Signed-off-by: Martin Kletzander --- src/util/virfile.c| 18 +++--- src/util/virhostcpu.c | 4 ++-- src/util/virsysfs.c | 2 ++ 3 files changed, 11 insertions(+), 13 deletions(-) diff --git a/src/util/virfile.c b/src/util/virfile.c index

[libvirt] [PATCH 15/16] tests: Add tests for caches into vircaps2xmltest

2017-03-30 Thread Martin Kletzander
Signed-off-by: Martin Kletzander --- src/conf/capabilities.c | 2 +- tests/vircaps2xmldata/vircaps-x86_64-caches.xml | 15 +++ tests/vircaps2xmltest.c | 3 ++- 3 files changed, 18 insertions(+), 2 deletions(-)

[libvirt] [PATCH 11/16] tests: Test capability XMLs in vircaps2xmldata

2017-03-30 Thread Martin Kletzander
Signed-off-by: Martin Kletzander --- tests/virschematest.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tests/virschematest.c b/tests/virschematest.c index 4f194804afb3..c98625d412e2 100644 --- a/tests/virschematest.c +++ b/tests/virschematest.c @@

[libvirt] [PATCH 14/16] tests: Add missing cache data for vircaps2xmltest

2017-03-30 Thread Martin Kletzander
Commit a0fdd2f6f9a0cc77ae285c289e2c16d314b6a907 added some data from the system but forgot 3 files for each cache. Signed-off-by: Martin Kletzander --- tests/vircaps2xmldata/linux-caches/cpu/cpu0/cache/index0/id | 1 +

[libvirt] [PATCH 12/16] Add RNG schema for host cache information in capabilities

2017-03-30 Thread Martin Kletzander
Signed-off-by: Martin Kletzander --- docs/schemas/capability.rng | 34 ++ 1 file changed, 34 insertions(+) diff --git a/docs/schemas/capability.rng b/docs/schemas/capability.rng index 88e08d299ac9..208095302a63 100644 ---

[libvirt] [PATCH 07/16] util: Add virSysfsCpuDirOpen

2017-03-30 Thread Martin Kletzander
Signed-off-by: Martin Kletzander --- src/libvirt_private.syms | 1 + src/util/virsysfs.c | 14 ++ src/util/virsysfs.h | 5 + 3 files changed, 20 insertions(+) diff --git a/src/libvirt_private.syms b/src/libvirt_private.syms index

[libvirt] [PATCH 10/16] util: Add virSysfsGetCPUCache* functions

2017-03-30 Thread Martin Kletzander
Signed-off-by: Martin Kletzander --- src/libvirt_private.syms | 5 +++ src/util/virsysfs.c | 102 +++ src/util/virsysfs.h | 34 3 files changed, 141 insertions(+) diff --git a/src/libvirt_private.syms

[libvirt] [PATCH 13/16] Add host cache information into capabilities

2017-03-30 Thread Martin Kletzander
Signed-off-by: Martin Kletzander --- src/conf/capabilities.c | 156 +++ src/conf/capabilities.h | 29 + src/libvirt_private.syms | 1 + 3 files changed, 186 insertions(+) diff --git a/src/conf/capabilities.c

Re: [libvirt] [PATCH v2 2.5/5] qemu: Remove redundant capabilities

2017-03-30 Thread John Ferlan
On 03/30/2017 08:48 AM, Andrea Bolognani wrote: > Now that the NO_ACPI and NO_HPET capabilities are set > automatically by virQEMUCapsInitQMPBasicArch() if > appropriate for the architecture, they shouldn't be > used manually to avoid masking bugs. > --- > tests/qemuxml2argvtest.c | 10

[libvirt] [PATCH 00/16] Expose host cache information in capabilities

2017-03-30 Thread Martin Kletzander
I think thanks to previous patches regarding sysfs, this should be very easy to review. The XML snippet that shows how the capablity XML looks like can be seen in the second to last patch which adds test for it. Again, first few patches are trivial because I couldn't be bothered to split the

[libvirt] [PATCH 05/16] util: Add virFileReadValueScaledInt

2017-03-30 Thread Martin Kletzander
Signed-off-by: Martin Kletzander --- src/libvirt_private.syms | 1 + src/util/virfile.c | 28 src/util/virfile.h | 1 + 3 files changed, 30 insertions(+) diff --git a/src/libvirt_private.syms b/src/libvirt_private.syms index

[libvirt] [PATCH 09/16] util: Unify behaviour of the functions in sysfs.c

2017-03-30 Thread Martin Kletzander
Make virSysfsGet*ValueString() functions use virSysfsGetValueString() then we have one more allocation, but the code is cleaner and it's easier to make sure the behaviour (e.g. return -2 on missing file) isn't changed by mistake. Signed-off-by: Martin Kletzander ---

[libvirt] [PATCH 04/16] util: Add virStringTrimOptionalNewline

2017-03-30 Thread Martin Kletzander
Signed-off-by: Martin Kletzander --- src/util/virstring.h | 8 1 file changed, 8 insertions(+) diff --git a/src/util/virstring.h b/src/util/virstring.h index a5550e30d2e2..603650aa1588 100644 --- a/src/util/virstring.h +++ b/src/util/virstring.h @@ -288,4 +288,12

[libvirt] [PATCH 06/16] util: Add virSysfsDirOpen

2017-03-30 Thread Martin Kletzander
Signed-off-by: Martin Kletzander --- src/libvirt_private.syms | 1 + src/util/virsysfs.c | 17 - src/util/virsysfs.h | 6 ++ 3 files changed, 23 insertions(+), 1 deletion(-) diff --git a/src/libvirt_private.syms b/src/libvirt_private.syms

Re: [libvirt] [PATCH V2 1/2] util: Add more virsysfs functions for handling resctrl sysfs

2017-03-30 Thread Martin Kletzander
On Thu, Mar 30, 2017 at 04:07:11PM +0800, Eli Qiao wrote: Extended /sys/fs/resctrl sysfs handling. Signed-off-by: Eli Qiao --- src/libvirt_private.syms | 11 - src/util/virsysfs.c | 102 ++- src/util/virsysfs.h |

[libvirt] [PATCH 02/16] util: Fix virDirRead() description

2017-03-30 Thread Martin Kletzander
Signed-off-by: Martin Kletzander --- src/util/virfile.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/util/virfile.c b/src/util/virfile.c index a91c2c349501..c0f448d3437d 100644 --- a/src/util/virfile.c +++ b/src/util/virfile.c @@ -2861,11

Re: [libvirt] Availability of libvirt-3.2.0 RC2

2017-03-30 Thread Martin Kletzander
On Thu, Mar 30, 2017 at 11:27:43AM +0200, Daniel Veillard wrote: So the Release Candidate 2 is tagged in git and signed tarball and rpms are available from the usual place: ftp://libvirt.org/libvirt/ I still have the same issue than with RC1 in my limited testing, a Windows XP VM fails

[libvirt] [PATCH 03/16] virsysfs: Add comments to separate logical blocks of functions

2017-03-30 Thread Martin Kletzander
Signed-off-by: Martin Kletzander --- src/util/virsysfs.c | 15 +-- src/util/virsysfs.h | 11 +++ 2 files changed, 24 insertions(+), 2 deletions(-) diff --git a/src/util/virsysfs.c b/src/util/virsysfs.c index 7a98b488e0ff..c482e188a301 100644 ---

[libvirt] [PATCH 01/16] conf: Fix possible memleak in capabilities

2017-03-30 Thread Martin Kletzander
If formatting NUMA topology fails, the function returns immediatelly, but the buffer structure allocated on the stack references lot of heap-allocated memory and that would get lost in such case. Signed-off-by: Martin Kletzander --- src/conf/capabilities.c | 6 +- 1

Re: [libvirt] [PATCH 0/3] storage: remove inactive transient pools after restart

2017-03-30 Thread Erik Skultety
On Thu, Mar 30, 2017 at 02:03:44PM +0200, Peter Krempa wrote: > Peter Krempa (3): > storage: backend: Use correct stringifier for pool type > storage: driver: Split out code fixing pool state after deactivation > storage: driver: Remove unavailable transient pools after restart > >

[libvirt] [PATCH 0/2] news: Further improvements

2017-03-30 Thread Andrea Bolognani
This applies on top of Peter's series[1], which has already been ACKed. [1] https://www.redhat.com/archives/libvir-list/2017-March/msg01478.html Andrea Bolognani (2): news: Remove handling of random HTML tags news: Allow empty elements docs/news-html.xsl| 20 +---

[libvirt] [PATCH 2/2] news: Allow empty elements

2017-03-30 Thread Andrea Bolognani
Creating dummy elements was a workaround for the HTML DTD not allowing empty elements, but we can do better by tweaking the the XSLT stylesheet. --- docs/news-html.xsl| 8 +--- docs/news.xml | 9 - docs/schemas/news.rng | 17 - 3 files changed, 13

[libvirt] [PATCH 1/2] news: Remove handling of random HTML tags

2017-03-30 Thread Andrea Bolognani
Now that the source file is validated against a schema that only allows the HTML tag to be used, we can rely on that assumption to simplify our XSLT stylesheet. --- docs/news-html.xsl | 12 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/docs/news-html.xsl

Re: [libvirt] [PATCH] [libvirt-php] fix libvirt_stream_send/libvirt_stream_recv

2017-03-30 Thread Michal Privoznik
On 03/30/2017 03:18 PM, Vasiliy Tolstov wrote: 2017-03-30 16:06 GMT+03:00 Michal Privoznik : Frankly, I've no idea whether this should be here. I feel like no because VIRT_ZVAL_STRINGL should not look into the recv_buf at any position greater than retval. That is why we

[libvirt] libvirt 2.3.0 and later versions hanging

2017-03-30 Thread Paul Gildea
Hi, I am starting a libvritd process when booting up an embedded networking system via python, like so: subprocess.Popen(["libvirtd","-d"],stdout=subprocess.PIPE,stderr=subprocess.PIPE) This runs and works fine for version 1.2.20. However after I upgraded to 2.3.0 I started noticing an

Re: [libvirt] [PATCH] [libvirt-php] fix libvirt_stream_send/libvirt_stream_recv

2017-03-30 Thread Vasiliy Tolstov
2017-03-30 16:06 GMT+03:00 Michal Privoznik : > Frankly, I've no idea whether this should be here. I feel like no because > VIRT_ZVAL_STRINGL should not look into the recv_buf at any position greater > than retval. That is why we give it the length of the string after all. Can

Re: [libvirt] [PATCH] [libvirt-php] fix libvirt_stream_send/libvirt_stream_recv

2017-03-30 Thread Michal Privoznik
On 03/29/2017 07:51 PM, Vasiliy Tolstov wrote: Signed-off-by: Vasiliy Tolstov --- src/libvirt-php.c | 36 1 file changed, 16 insertions(+), 20 deletions(-) diff --git a/src/libvirt-php.c b/src/libvirt-php.c index

Re: [libvirt] [PATCH] allow to specify empty base and top for block commit

2017-03-30 Thread Michal Privoznik
On 03/28/2017 12:26 PM, Vasiliy Tolstov wrote: Signed-off-by: Vasiliy Tolstov --- src/libvirt-php.c | 22 ++ 1 file changed, 14 insertions(+), 8 deletions(-) ACKed and pushed. Michal -- libvir-list mailing list libvir-list@redhat.com

Re: [libvirt] [PATCH 0/3] Fix gluster volume lookup of multiple volumes

2017-03-30 Thread Peter Krempa
On Wed, Mar 29, 2017 at 15:23:37 +0200, Peter Krempa wrote: > Fix the broken XPath and add tests. > > Peter Krempa (3): > storage: util: Split out the gluster volume extraction code into new > function > test: Introduce testing of virStorageUtilGlusterExtractPoolSources > storage: Fix

Re: [libvirt] [PATCH v2 2/5] tests: Initialize basic capabilities properly

2017-03-30 Thread Andrea Bolognani
On Wed, 2017-03-29 at 19:50 -0400, John Ferlan wrote: > > The capabilities used in test cases should match those used > > during normal operation for the tests to make any sense. >  > Could you add just a bit of text about why all -no-acpi is removed > (mostly) and why -no-hpet is added to a

Re: [libvirt] [PATCH 1/3] storage: backend: Use correct stringifier for pool type

2017-03-30 Thread Erik Skultety
On Thu, Mar 30, 2017 at 02:03:45PM +0200, Peter Krempa wrote: > When registering a storage poll backend, the code would use > virStorageTypeToString instead of virStoragePoolTypeToString. The > following message would be logged: > > virDriverLoadModuleFunc:71 : Lookup function

[libvirt] [PATCH v2 2.5/5] qemu: Remove redundant capabilities

2017-03-30 Thread Andrea Bolognani
Now that the NO_ACPI and NO_HPET capabilities are set automatically by virQEMUCapsInitQMPBasicArch() if appropriate for the architecture, they shouldn't be used manually to avoid masking bugs. --- tests/qemuxml2argvtest.c | 10 -- 1 file changed, 4 insertions(+), 6 deletions(-) diff

Re: [libvirt] [PATCH] qemuDomainSnapshotPrepare: Don't always assume vm->def->os.loader

2017-03-30 Thread Peter Krempa
On Thu, Mar 30, 2017 at 14:06:22 +0200, Michal Privoznik wrote: > In 9e2465834 a check that denies internal snapshots when pflash > based loader is configured for the domain. However, if there's > none and an user tries to do an internal snapshot they will > witness daemon crash as in that case

[libvirt] [PATCH] qemuDomainSnapshotPrepare: Don't always assume vm->def->os.loader

2017-03-30 Thread Michal Privoznik
In 9e2465834 a check that denies internal snapshots when pflash based loader is configured for the domain. However, if there's none and an user tries to do an internal snapshot they will witness daemon crash as in that case vm->def->os.loader is NULL and we dereference it unconditionally.

[libvirt] [PATCH] storage: gluster: Implement 'checkPool' method so that state is restored

2017-03-30 Thread Peter Krempa
After restart of libvirtd the 'checkPool' method is supposed to validate that the pool is online. Since libvirt then refreshes the pool contents anyways just return whether the pool was supposed to be online so that the code can be reached. This is necessary since if a pool does not implement the

[libvirt] [PATCH 1/3] storage: backend: Use correct stringifier for pool type

2017-03-30 Thread Peter Krempa
When registering a storage poll backend, the code would use virStorageTypeToString instead of virStoragePoolTypeToString. The following message would be logged: virDriverLoadModuleFunc:71 : Lookup function 'virStorageBackendSCSIRegister' virStorageBackendRegister:174 : Registering storage backend

[libvirt] [PATCH 3/3] storage: driver: Remove unavailable transient pools after restart

2017-03-30 Thread Peter Krempa
If a transient storage pool is deemed inactive after libvirtd restart it would not be deleted from the list. Reuse virStoragePoolUpdateInactive along with a refactor necessary to properly update the state. Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1242801 ---

[libvirt] [PATCH 2/3] storage: driver: Split out code fixing pool state after deactivation

2017-03-30 Thread Peter Krempa
After a pool is made inactive the definition objects need to be updated (if a new definition is prepared) and transient pools need to be completely removed. Split out the code doing these steps into a separate function for later reuse. --- src/storage/storage_driver.c | 40

[libvirt] [PATCH 0/3] storage: remove inactive transient pools after restart

2017-03-30 Thread Peter Krempa
Peter Krempa (3): storage: backend: Use correct stringifier for pool type storage: driver: Split out code fixing pool state after deactivation storage: driver: Remove unavailable transient pools after restart src/storage/storage_backend.c | 2 +- src/storage/storage_driver.c | 68

Re: [libvirt] [PATCH] tests: Rename VIRT_TEST_* macros to VIR_TEST_*

2017-03-30 Thread Michal Privoznik
On 03/29/2017 04:49 PM, Andrea Bolognani wrote: We use the "vir" prefix pretty consistently in our APIs, both external and internal, which made these macros stood out. ACK Michal -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list

Re: [libvirt] testing volDownload and volUpload different md5 on source and dest for qcow2

2017-03-30 Thread Michal Privoznik
On 03/29/2017 06:42 PM, Vasiliy Tolstov wrote: Hi. I'm fix libvirt php binding to properly recv from stream and after that test volume download and volume upload functions. And see, that in case of raw image md5sum on src and on dst is equal. But in case of qcow - phisical size of image is

Re: [libvirt] [PATCH v2 4/5] qemu: Enforce ACPI, UEFI requirements

2017-03-30 Thread John Ferlan
On 03/30/2017 03:47 AM, Andrea Bolognani wrote: > On Wed, 2017-03-29 at 19:50 -0400, John Ferlan wrote: > [...] >>> @@ -2884,6 +2884,26 @@ qemuDomainDefValidate(const virDomainDef *def, >>> goto cleanup; >>> } >>> >>> +/* On x86, UEFI requires ACPI */ >>> +if

[libvirt] Availability of libvirt-3.2.0 RC2

2017-03-30 Thread Daniel Veillard
So the Release Candidate 2 is tagged in git and signed tarball and rpms are available from the usual place: ftp://libvirt.org/libvirt/ I still have the same issue than with RC1 in my limited testing, a Windows XP VM fails networking access, nothing in the logs, but the problem could be on

[libvirt] [PATCH V2 2/2] test: Add fake cpu id file

2017-03-30 Thread Eli Qiao
Added fake cpu cache id and resctrl file Signed-off-by: Eli Qiao --- tests/vircaps2xmldata/linux-caches/cpu/cpu0/cache/index0/id | 1 + tests/vircaps2xmldata/linux-caches/cpu/cpu0/cache/index1/id | 1 + tests/vircaps2xmldata/linux-caches/cpu/cpu0/cache/index2/id | 1 +

[libvirt] [PATCH V2 1/2] util: Add more virsysfs functions for handling resctrl sysfs

2017-03-30 Thread Eli Qiao
Extended /sys/fs/resctrl sysfs handling. Signed-off-by: Eli Qiao --- src/libvirt_private.syms | 11 - src/util/virsysfs.c | 102 ++- src/util/virsysfs.h | 16 src/util/virsysfspriv.h | 1 + 4 files

Re: [libvirt] [PATCH 0/3 for 3.2.0] Fix host-model CPU with non-migratable features

2017-03-30 Thread Ján Tomko
On Wed, Mar 29, 2017 at 04:53:16PM +0200, Jiri Denemark wrote: This series fixes a regression in libvirt which would break domains with a CPU defined as, for example: Such domains would work just fine with libvirt <= 3.1.0 or QEMU < 2.9.0, but they would be broken with current

Re: [libvirt] [PATCH v2 4/5] qemu: Enforce ACPI, UEFI requirements

2017-03-30 Thread Andrea Bolognani
On Wed, 2017-03-29 at 19:50 -0400, John Ferlan wrote: [...] > > @@ -2884,6 +2884,26 @@ qemuDomainDefValidate(const virDomainDef *def, > >  goto cleanup; > >  } > >   > > +/* On x86, UEFI requires ACPI */ > > +if (def->os.loader && > > +def->os.loader->type ==