Re: [libvirt] [ 0/5] netdev ethernet allow to set ip, route and peer address

2016-04-07 Thread Vasiliy Tolstov
2016-04-07 20:38 GMT+03:00 Daniel P. Berrange : > I fixed the few problems with this and pushed it to git. Thank you for help! -- Vasiliy Tolstov, e-mail: v.tols...@selfip.ru -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list

Re: [libvirt] Unsupported network type ethernet

2016-04-07 Thread sonia verma
Thanks Daniel. I'm trying to run software Opencontrail on ARM arch which in turn usses libvirt with network type=ethernet.I cannot use type=bridge or type=network for connectivity of the guest LXC VMs. *Thanks Vasiliy*Please let me know once we are ready with the patches for ethernet support. R

[libvirt] [PATCH v2 01/10] virsh: report when vz driver is compiled

2016-04-07 Thread Maxim Nestratov
Signed-off-by: Maxim Nestratov --- tools/virsh.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/tools/virsh.c b/tools/virsh.c index fe33839..5a61189 100644 --- a/tools/virsh.c +++ b/tools/virsh.c @@ -580,6 +580,9 @@ virshShowVersion(vshControl *ctl ATTRIBUTE_UNUSED) #ifdef WITH_OPENVZ

[libvirt] [PATCH v2 07/10] vz: implement connectGetSysinfo hypervisor callback

2016-04-07 Thread Maxim Nestratov
Signed-off-by: Maxim Nestratov --- src/vz/vz_driver.c | 25 + src/vz/vz_utils.h | 1 + 2 files changed, 26 insertions(+) diff --git a/src/vz/vz_driver.c b/src/vz/vz_driver.c index e9fe89f..dce7a87 100644 --- a/src/vz/vz_driver.c +++ b/src/vz/vz_driver.c @@ -177,6 +177,7

[libvirt] [PATCH v2 03/10] vz: remove drivername field from vzConn structure

2016-04-07 Thread Maxim Nestratov
No need to remember connection name and have corresponding domain type to keep backward compatibility with former 'parallels' driver. It is enough to be able to accept 'parallels' uri and domain types. Signed-off-by: Maxim Nestratov --- src/vz/vz_driver.c | 2 -- src/vz/vz_utils.c | 5 + sr

[libvirt] [PATCH v2 09/10] vz: minor cleanup

2016-04-07 Thread Maxim Nestratov
remove unnecessary vzConnectClose prototype and make local structure vzDomainDefParserConfig be static Signed-off-by: Maxim Nestratov --- src/vz/vz_driver.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/vz/vz_driver.c b/src/vz/vz_driver.c index 50da2fe..b3ce404 100644

[libvirt] [PATCH v2 00/10] vz: change vz driver to be stateful driver and other enhancements

2016-04-07 Thread Maxim Nestratov
There is no benefit in providing two ways of connecting to vz driver: by connecting via daemon and directly from client. Both ways finally come to a host where vz daemon sits. Always connecting via daemon allows us to have a single list of domains and share it among all connections. Since v1: rem

[libvirt] [PATCH v2 04/10] vz: add Hypervisor prefix to vz and parallels Driver structures

2016-04-07 Thread Maxim Nestratov
--- src/vz/vz_driver.c | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/vz/vz_driver.c b/src/vz/vz_driver.c index 9de88cd..f2bbf1e 100644 --- a/src/vz/vz_driver.c +++ b/src/vz/vz_driver.c @@ -1491,7 +1491,7 @@ vzConnectUnregisterCloseCallback(virConnectPtr conn,

[libvirt] [PATCH v2 02/10] vz: change the order of capabilities reported

2016-04-07 Thread Maxim Nestratov
'vz' goes first now to make clients like virt-manager choose 'vz' instead of 'parallels' Signed-off-by: Maxim Nestratov --- src/vz/vz_driver.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/vz/vz_driver.c b/src/vz/vz_driver.c index e12a95a..47a5060 100644 --- a/src

[libvirt] [PATCH v2 05/10] vz: build driver as module and don't register it on client's side

2016-04-07 Thread Maxim Nestratov
Make it possible to build vz driver as a module and don't link it with libvirt.so statically. Remove registering it on client's side as far as we start relying on daemon Signed-off-by: Maxim Nestratov --- daemon/Makefile.am | 4 daemon/libvirtd.c| 9 + src/Makefile.a

[libvirt] [PATCH v2 08/10] vz: remove vzDriverLock/Unlock function

2016-04-07 Thread Maxim Nestratov
We don't need them anymore as all pointers within vzDriver structure are not changed during the time it exists. Where we still need to synchronize we use virObjectLock/Unlock as far as vzDriver is lockable object. Signed-off-by: Maxim Nestratov --- src/vz/vz_driver.c | 35 ---

[libvirt] [PATCH v2 10/10] vz: change vzConnectIsAlive behavior

2016-04-07 Thread Maxim Nestratov
Now it detects if a connection to vz dispatcher is up or not by comparing current driver to connection stored pointer. Signed-off-by: Maxim Nestratov --- src/vz/vz_driver.c | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/vz/vz_driver.c b/src/vz/vz_driver.c index b3ce

[libvirt] [PATCH v2 06/10] vz: introduce new vzDriver lockable structure and use it

2016-04-07 Thread Maxim Nestratov
This patch introduces a new 'vzDriver' lockable object and provides helper functions to allocate/destroy it and we pass it to prlsdkXxx functions instead of virConnectPtr. Now we store domain related objects such as domain list, capabitilies etc. within a single vz_driver vzDriver structure, which

Re: [libvirt] [PATCH] libxl: libxl_domain_create_restore has an extra argument

2016-04-07 Thread Wei Liu
On Thu, Apr 07, 2016 at 05:35:33PM +0100, Daniel P. Berrange wrote: > On Wed, Apr 06, 2016 at 04:43:07PM -0500, Doug Goldstein wrote: > > On 4/5/16 9:20 AM, Wei Liu wrote: > > > In the latest libxenlight code, libxl_domain_create_restore accepts a > > > new argument. Update libvirt's libxl driver f

Re: [libvirt] [ 5/5] qemu domain allow to set ip address, peer address and route

2016-04-07 Thread Daniel P. Berrange
On Mon, Apr 04, 2016 at 09:00:06PM +, Vasiliy Tolstov wrote: > Signed-off-by: Vasiliy Tolstov > --- > src/qemu/qemu_interface.c | 39 +++ > 1 file changed, 39 insertions(+) > > diff --git a/src/qemu/qemu_interface.c b/src/qemu/qemu_interface.c > index 13a5

Re: [libvirt] [ 0/5] netdev ethernet allow to set ip, route and peer address

2016-04-07 Thread Daniel P. Berrange
On Thu, Apr 07, 2016 at 06:35:43PM +0100, Daniel P. Berrange wrote: > On Mon, Apr 04, 2016 at 09:00:01PM +, Vasiliy Tolstov wrote: > > Some minor improvements and patch split as suggested by Laine Stump > > FYI, make sure you include the word PATCH in mails, so they get > picked up by out patc

Re: [libvirt] [ 3/5] lxc domain allow to set peer address

2016-04-07 Thread Daniel P. Berrange
On Mon, Apr 04, 2016 at 09:00:04PM +, Vasiliy Tolstov wrote: > Signed-off-by: Vasiliy Tolstov > --- > src/lxc/lxc_container.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/src/lxc/lxc_container.c b/src/lxc/lxc_container.c > index 348bbfbc01fc..a1deb0c00d4c 100644 >

Re: [libvirt] [ 2/5] libvirt domain xml allow to set peer address

2016-04-07 Thread Daniel P. Berrange
On Mon, Apr 04, 2016 at 09:00:03PM +, Vasiliy Tolstov wrote: > Signed-off-by: Vasiliy Tolstov > --- > docs/formatdomain.html.in | 12 +++- > docs/schemas/domaincommon.rng | 5 + > src/conf/domain_conf.c| 14 +- > src/conf/domain_conf.h| 1 + > 4 f

Re: [libvirt] [ 4/5] bridge network ignore peer address

2016-04-07 Thread Daniel P. Berrange
On Mon, Apr 04, 2016 at 09:00:05PM +, Vasiliy Tolstov wrote: > Signed-off-by: Vasiliy Tolstov > --- > src/network/bridge_driver.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/src/network/bridge_driver.c b/src/network/bridge_driver.c > index 0d14e3a3..73236ffe1

Re: [libvirt] [ 1/5] virnetdev allow to set peer address

2016-04-07 Thread Daniel P. Berrange
On Mon, Apr 04, 2016 at 09:00:02PM +, Vasiliy Tolstov wrote: > Signed-off-by: Vasiliy Tolstov > --- > src/util/virnetdev.c | 54 > > src/util/virnetdev.h | 1 + > 2 files changed, 39 insertions(+), 16 deletions(-) > diff --git a/src/util

Re: [libvirt] [ 0/5] netdev ethernet allow to set ip, route and peer address

2016-04-07 Thread Daniel P. Berrange
On Mon, Apr 04, 2016 at 09:00:01PM +, Vasiliy Tolstov wrote: > Some minor improvements and patch split as suggested by Laine Stump FYI, make sure you include the word PATCH in mails, so they get picked up by out patch tracking too, otherwise they could get left without being noticed. Regards

Re: [libvirt] 200ms delay waiting for qemu monitor

2016-04-07 Thread Daniel P. Berrange
On Thu, Apr 07, 2016 at 09:08:38AM +0200, Michal Privoznik wrote: > On 06.04.2016 21:45, Richard W.M. Jones wrote: > > [Thanks to Dan Berrangé for doing the analysis of this one] > > > > I was investigating a 200+ millisecond delay when libvirt starts a > > qemu guest. You can see the traces here

Re: [libvirt] [PATCH] libxl: libxl_domain_create_restore has an extra argument

2016-04-07 Thread Daniel P. Berrange
On Wed, Apr 06, 2016 at 04:43:07PM -0500, Doug Goldstein wrote: > On 4/5/16 9:20 AM, Wei Liu wrote: > > In the latest libxenlight code, libxl_domain_create_restore accepts a > > new argument. Update libvirt's libxl driver for that. Use the macro > > provided by libxenlight to detect which version s

Re: [libvirt] [PATCH v2] add func to set shared drivers after libvirtd init

2016-04-07 Thread Maxim Nestratov
19.11.2015 15:22, Mikhail Feoktistov пишет: Diff from v1: Remove vz prefix from the title of this letter. Because this is the common case for all drivers in libvirt. Description: Built-in drivers in libvirt are initialized before libvirtd initialization. Libvirt loads shared drivers on libvirtd

Re: [libvirt] [PATCH v2 0/3] qemu: Explicitly check for gnutls_rnd()

2016-04-07 Thread Andrea Bolognani
On Thu, 2016-04-07 at 11:46 -0400, John Ferlan wrote: > >   configure: Restore CFLAGS properly after GnuTLS checks > >   configure: Always use old_CFLAGS and old_LIBS > >   qemu: Explicitly check for gnutls_rnd() > >  > >  configure.ac   | 31 +++ > >  src/qemu/qe

Re: [libvirt] [PATCH v2] host-validate: Improve CPU flags processing

2016-04-07 Thread Andrea Bolognani
On Tue, 2016-04-05 at 12:35 +0200, Ján Tomko wrote: > > +/* Split the line using " " as a delimiter. The first token > > + * will always be ":", but that's okay */ > > +if (!(tokens = virStringSplitCount(start, " ", 0, &ntokens))) > > +continue; > > + > > +  

Re: [libvirt] [PATCH v2 0/3] qemu: Explicitly check for gnutls_rnd()

2016-04-07 Thread John Ferlan
On 04/07/2016 09:29 AM, Andrea Bolognani wrote: > Patch 1 fixes a bug in configure. > > Patch 2 performs a minor cleanup. > > Patch 3 is the fix for the build issues currently experienced > on CentOS 6 (see [1]). > > Changes from v1: > > * update CFLAGS and LIBS before performing the check,

Re: [libvirt] Unsupported network type ethernet

2016-04-07 Thread Vasiliy Tolstov
2016-04-07 17:25 GMT+03:00 Daniel P. Berrange : > We don't currently have support for it for LXC - we recommend using > type=bridge or type=network for connectivity. We would consider patches > for type=ethernet though if someone wants to write them > > > Regards, > Daniel I can take this after m

Re: [libvirt] Unsupported network type ethernet

2016-04-07 Thread Daniel P. Berrange
On Thu, Apr 07, 2016 at 07:45:34PM +0530, sonia verma wrote: > Hi Team > > I need to launch LXC VM using ethernet network type using libvirt.While > trying the same, I'm getting below errors .. > > *error: internal error: Unsupported network type ethernet* > > Is there any patch available to ad

[libvirt] Unsupported network type ethernet

2016-04-07 Thread sonia verma
Hi Team I need to launch LXC VM using ethernet network type using libvirt.While trying the same, I'm getting below errors .. *error: internal error: Unsupported network type ethernet* Is there any patch available to add ethernet support to Libvirt with LXC VM ? Please let me know regarding th

[libvirt] [PATCH v2 0/3] qemu: Explicitly check for gnutls_rnd()

2016-04-07 Thread Andrea Bolognani
Patch 1 fixes a bug in configure. Patch 2 performs a minor cleanup. Patch 3 is the fix for the build issues currently experienced on CentOS 6 (see [1]). Changes from v1: * update CFLAGS and LIBS before performing the check, so that the compiler can actually find the function Cheers. [1

[libvirt] [PATCH v2 1/3] configure: Restore CFLAGS properly after GnuTLS checks

2016-04-07 Thread Andrea Bolognani
The previous value of CFLAGS was saved as old_cflags but later restored from old_CFLAGS, which is clearly not correct. Restore CFLAGS from the right variable. --- configure.ac | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/configure.ac b/configure.ac index 85fc6e1..6088f77 10

[libvirt] [PATCH v2 2/3] configure: Always use old_CFLAGS and old_LIBS

2016-04-07 Thread Andrea Bolognani
The variables used for storing CFLAGS and LIBS before temporarily modifying them was consistent when it comes to the name, but not when it comes to the case. Make sure names are completely consistent. --- configure.ac | 26 +- 1 file changed, 13 insertions(+), 13 deletions

[libvirt] [PATCH v2 3/3] qemu: Explicitly check for gnutls_rnd()

2016-04-07 Thread Andrea Bolognani
Our use of gnutls_rnd(), introduced with commit ad7520e8, is conditional to the availability of the header file. Such check, however, turns out not to be strict enough, as there are some versions of GnuTLS (eg. 2.8.5 from CentOS 6) that provide the header file, but not the function itself, which

Re: [libvirt] [PATCH] qemu: Check for gnutls_rnd() explicitly

2016-04-07 Thread Andrea Bolognani
On Thu, 2016-04-07 at 13:57 +0200, Andrea Bolognani wrote: > Our use of gnutls_rnd() is conditional to the availability of > the header file. > > Such check, however, turns out not to be strict enough as there > are some versions of gnutls (eg. 2.8.5 as available in CentOS 6) > that provide the h

[libvirt] [PATCH] qemu: Check for gnutls_rnd() explicitly

2016-04-07 Thread Andrea Bolognani
Our use of gnutls_rnd() is conditional to the availability of the header file. Such check, however, turns out not to be strict enough as there are some versions of gnutls (eg. 2.8.5 as available in CentOS 6) that provide the header file, but not the function itself, which was introduced in 2.12.0

Re: [libvirt] [PATCH] qemu: perf: Fix crash/memory corruption on failed VM start

2016-04-07 Thread Peter Krempa
On Thu, Apr 07, 2016 at 13:18:42 +0200, Ján Tomko wrote: > On Thu, Apr 07, 2016 at 12:52:19PM +0200, Peter Krempa wrote: > > The new perf code didn't bother to clear a pointer in 'priv' causing a > > double free or other memory corruption goodness if a VM failed to start. > > > > Clear the pointer

Re: [libvirt] [PATCH] qemu: perf: Fix crash/memory corruption on failed VM start

2016-04-07 Thread Ján Tomko
On Thu, Apr 07, 2016 at 12:52:19PM +0200, Peter Krempa wrote: > The new perf code didn't bother to clear a pointer in 'priv' causing a > double free or other memory corruption goodness if a VM failed to start. > > Clear the pointer after freeing the memory. > > Resolves: https://bugzilla.redhat.c

[libvirt] [PATCH] qemu: perf: Fix crash/memory corruption on failed VM start

2016-04-07 Thread Peter Krempa
The new perf code didn't bother to clear a pointer in 'priv' causing a double free or other memory corruption goodness if a VM failed to start. Clear the pointer after freeing the memory. Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1324757 --- src/qemu/qemu_process.c | 2 ++ 1 file cha

Re: [libvirt] [PATCH 0/3] vz: add boot order support

2016-04-07 Thread Nikolay Shirokovskiy
On 07.04.2016 12:56, Maxim Nestratov wrote: > 22.03.2016 16:56, Nikolay Shirokovskiy пишет: >> Let's add support for old school boot order via xml os section. >> >> Nikolay Shirokovskiy (3): >>vz: support boot order specification on define domain >>vz: fix disk order on load domain >>

Re: [libvirt] [PATCH 3/3] vz: support boot order in domain xml dump

2016-04-07 Thread Nikolay Shirokovskiy
On 07.04.2016 12:54, Maxim Nestratov wrote: > 22.03.2016 16:56, Nikolay Shirokovskiy пишет: >> As usual we try to deal correctly with vz domains that were >> created by other means and thus can have all range of SDK domain >> parameters. If vz domain boot order can't be represented >> in libvirt

[libvirt] [PATCH V5] libxl: support creating domain with VF assignment from a pool

2016-04-07 Thread Chunyan Liu
Add codes to support creating domain with network defition of assigning SRIOV VF from a pool. Signed-off-by: Chunyan Liu Signed-off-by: Jim Fehlig --- Rebase and send a new version. src/libxl/libxl_domain.c | 48 tests/Makefile.am| 3 ++

Re: [libvirt] [PATCH 0/3] vz: add boot order support

2016-04-07 Thread Maxim Nestratov
22.03.2016 16:56, Nikolay Shirokovskiy пишет: Let's add support for old school boot order via xml os section. Nikolay Shirokovskiy (3): vz: support boot order specification on define domain vz: fix disk order on load domain vz: support boot order in domain xml dump src/vz/vz_sdk.c |

Re: [libvirt] [PATCH 3/3] vz: support boot order in domain xml dump

2016-04-07 Thread Maxim Nestratov
22.03.2016 16:56, Nikolay Shirokovskiy пишет: As usual we try to deal correctly with vz domains that were created by other means and thus can have all range of SDK domain parameters. If vz domain boot order can't be represented in libvirt os boot section let's give warning and make os boot sectio

Re: [libvirt] [PATCH 2/3] vz: fix disk order on load domain

2016-04-07 Thread Maxim Nestratov
22.03.2016 16:56, Nikolay Shirokovskiy пишет: We want to report boot order in dumpxml for vz domains. Thus we want disks devices to be sorted in output compatible with boot ordering specification. So let's just use virDomainDiskInsert which makes appropriate sorting. Signed-off-by: Nikolay Shiro

Re: [libvirt] [PATCH 1/3] vz: support boot order specification on define domain

2016-04-07 Thread Maxim Nestratov
22.03.2016 16:56, Nikolay Shirokovskiy пишет: The patch makes some refactoring of the existing code. Current boot order spec code makes very simple thing in somewhat obscure way. In case of VMs it sets the first hdd as the only bootable device. In case of CTs it doesn't touch the boot order at a

Re: [libvirt] [PATCH] util: move ENODATA redefine to virutil.h

2016-04-07 Thread Andrea Bolognani
On Thu, 2016-04-07 at 10:17 +0100, Daniel P. Berrange wrote: > > So I think you should rather move the definition from viruuid.c > > to virrandom.c instead of virutil.h. > > > > ACK with that changed. > > Actually for this kind of super generic portability fix I'd > strongly suggest we put it in

[libvirt] [PATCH v4] Use-correct-pci-addresses-during-interface-detach

2016-04-07 Thread Nitesh Konkar
The virsh attach virsh detach interface command fails when both live and config are set and when the interface gets attached to different pci slots on live and config xml respectively. When we attach an interface with both --live and --config, the first time they get the same PCI slots, but the

Re: [libvirt] [PATCH] util: move ENODATA redefine to virutil.h

2016-04-07 Thread Daniel P. Berrange
On Thu, Apr 07, 2016 at 11:13:00AM +0200, Andrea Bolognani wrote: > On Thu, 2016-04-07 at 09:53 +0300, Roman Bogorodskiy wrote: > > FreeBSD lacks ENODATA, and viruuid.c redefines it to EIO. However, > > now we have virrandom.c that's using ENODATA also, so move this > > re-definition to a common pl

Re: [libvirt] [PATCH] util: move ENODATA redefine to virutil.h

2016-04-07 Thread Andrea Bolognani
On Thu, 2016-04-07 at 09:53 +0300, Roman Bogorodskiy wrote: > FreeBSD lacks ENODATA, and viruuid.c redefines it to EIO. However, > now we have virrandom.c that's using ENODATA also, so move this > re-definition to a common place, virutil.h, so it could fix things for > both consumers. > --- >  src/

[libvirt] [PATCH] storage_scsi: Handle physical HBA when deleting vHBA vport.

2016-04-07 Thread Nitesh Konkar
HBA will get treated as vHBA if not returned after detecting vhba_parent format. Signed-off-by: Nitesh Konkar --- Before Patch: # virsh pool-destroy poolhba_name error: Failed to destroy pool poolhba_name error: internal error: Invalid adapter name 'pci_000x_0x_00_x' for SCSI pool # virsh nodede

Re: [libvirt] [PATCH 1/2] qemu: alias: Fix calculation of RNG device aliases

2016-04-07 Thread Peter Krempa
On Wed, Apr 06, 2016 at 18:14:22 +0200, Pavel Hrdina wrote: > On Wed, Apr 06, 2016 at 05:52:48PM +0200, Peter Krempa wrote: > > For device hotplug, the new alias ID needs to be checked in the list > > rather than using the count of devices. Unplugging a device that is not > > last in the array will

Re: [libvirt] [PATCH] nss: Simplify move_and_align

2016-04-07 Thread Jiri Denemark
On Thu, Apr 07, 2016 at 09:31:06 +0200, Michal Privoznik wrote: > What this function does can be written much shorter. > > Signed-off-by: Michal Privoznik > --- > tools/nss/libvirt_nss.c | 8 +++- > 1 file changed, 3 insertions(+), 5 deletions(-) > > diff --git a/tools/nss/libvirt_nss.c b/t

[libvirt] [PATCH] nss: Simplify move_and_align

2016-04-07 Thread Michal Privoznik
What this function does can be written much shorter. Signed-off-by: Michal Privoznik --- tools/nss/libvirt_nss.c | 8 +++- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/tools/nss/libvirt_nss.c b/tools/nss/libvirt_nss.c index de34baf..587b171 100644 --- a/tools/nss/libvirt_nss

Re: [libvirt] 200ms delay waiting for qemu monitor

2016-04-07 Thread Michal Privoznik
On 06.04.2016 21:45, Richard W.M. Jones wrote: > [Thanks to Dan Berrangé for doing the analysis of this one] > > I was investigating a 200+ millisecond delay when libvirt starts a > qemu guest. You can see the traces here: > > http://oirase.annexia.org/tmp/libvirt.log > http://oirase.annexia.org