Re: [libvirt] [PATCH 0/7] Drop support for QEMU < 0.12.0

2015-11-06 Thread Daniel P. Berrange
On Thu, Nov 05, 2015 at 11:05:53AM -0700, Eric Blake wrote: > On 11/05/2015 10:47 AM, Cole Robinson wrote: > > On 11/05/2015 12:33 PM, Daniel P. Berrange wrote: > >> The patches for introducing virtlogd will be significantly > >> simplified if we don't need to worry about parsing stderr > >>

Re: [libvirt] [PATCH 0/7] Drop support for QEMU < 0.12.0

2015-11-06 Thread Daniel P. Berrange
On Thu, Nov 05, 2015 at 06:15:52PM -0500, John Ferlan wrote: > > > On 11/05/2015 12:33 PM, Daniel P. Berrange wrote: > > The patches for introducing virtlogd will be significantly > > simplified if we don't need to worry about parsing stderr > > during startup. This is required prior to QEMU

Re: [libvirt] [PATCH 0/7] Drop support for QEMU < 0.12.0

2015-11-06 Thread Daniel P. Berrange
On Fri, Nov 06, 2015 at 07:42:35AM +0100, Peter Krempa wrote: > On Thu, Nov 05, 2015 at 17:33:52 +, Daniel Berrange wrote: > > The patches for introducing virtlogd will be significantly > > simplified if we don't need to worry about parsing stderr > > during startup. This is required prior to

Re: [libvirt] [PATCH 2/7] qemu: remove all support for kQEMU

2015-11-06 Thread Daniel P. Berrange
On Thu, Nov 05, 2015 at 05:04:54PM -0500, John Ferlan wrote: > > > On 11/05/2015 12:33 PM, Daniel P. Berrange wrote: > > The kQEMU accelerator was deleted in QEMU 0.12, so we no > > longer need to support it in the QEMU driver. > > > > Signed-off-by: Daniel P. Berrange > >

Re: [libvirt] [PATCH 3/7] qemu: assume -vnc arg always takes a ':'

2015-11-06 Thread Daniel P. Berrange
On Thu, Nov 05, 2015 at 05:21:39PM -0500, John Ferlan wrote: > > > On 11/05/2015 12:33 PM, Daniel P. Berrange wrote: > > As of QEMU 0.9.0 the -vnc option accepts a ':' to separate port > > from listen address, so the QEMU driver can assume that support > > for listen addresses is always

Re: [libvirt] [PATCH 4/7] qemu: assume 'info chardev' is always available

2015-11-06 Thread Daniel P. Berrange
On Thu, Nov 05, 2015 at 03:18:12PM -0500, John Ferlan wrote: > > > On 11/05/2015 12:33 PM, Daniel P. Berrange wrote: > > As of QEMU 0.11.0 the 'info chardev' monitor command can be > > used to report on allocated chardev paths, so we can drop > > support for parsing QEMU stderr to locate the PTY

Re: [libvirt] [PATCH 6/7] qemu: assume -drive argument is always available

2015-11-06 Thread Daniel P. Berrange
On Thu, Nov 05, 2015 at 04:51:10PM -0500, John Ferlan wrote: > > > On 11/05/2015 12:33 PM, Daniel P. Berrange wrote: > > As of QEMU 0.9.1 the -drive argument can be used to configure > > all disks, so the QEMU driver can assume it is always available > > and drop support for -hda/-cdrom/etc. > >

Re: [libvirt] [PATCH v3 01/11] libvirt: Export libvirt config getters by moving them to util

2015-11-06 Thread Daniel P. Berrange
On Fri, Nov 06, 2015 at 12:46:16PM +0100, Erik Skultety wrote: > virConnectGetConfig and virConnectGetConfigPath were static libvirt > methods, merely because there hasn't been any need for having them > internally exported yet. Since libvirt-admin also needs to reference > libvirt config file,

[libvirt] [PATCH] tests: redo test argv file line wrapping

2015-11-06 Thread Daniel P. Berrange
Back in commit bd6c46fa0cfe275c24debc1152cfc5206c04b59b Author: Juerg Haefliger Date: Mon Jan 31 06:42:57 2011 -0500 tests: handle backspace-newline pairs in test input files all the test argv files were line wrapped so that the args were less than 80

Re: [libvirt] [PATCH 2/3] virnetdev: Message in virNetDevSendEthtoolIoctl rather than caller.

2015-11-06 Thread Ján Tomko
On Wed, Nov 04, 2015 at 10:18:27AM -0500, John Ferlan wrote: > > > On 11/04/2015 04:39 AM, Ján Tomko wrote: > > On Tue, Nov 03, 2015 at 07:18:10PM -0500, John Ferlan wrote: > >> Since virNetDevSetupControl can generate a virReportSystemError, rather > >> than message in the caller for any

[libvirt] [PATCH libvirt-java] Add new WITH_SNAPSHOTS removal flag for Storage Volumes

2015-11-06 Thread Wido den Hollander
This was recently added to libvirt and this is to match the API Signed-off-by: Wido den Hollander --- src/main/java/org/libvirt/StorageVol.java | 4 1 file changed, 4 insertions(+) diff --git a/src/main/java/org/libvirt/StorageVol.java

Re: [libvirt] [PATCH] tests: redo test argv file line wrapping

2015-11-06 Thread Martin Kletzander
On Fri, Nov 06, 2015 at 01:30:35PM +, Daniel P. Berrange wrote: Back in commit bd6c46fa0cfe275c24debc1152cfc5206c04b59b Author: Juerg Haefliger Date: Mon Jan 31 06:42:57 2011 -0500 tests: handle backspace-newline pairs in test input files all the test argv

Re: [libvirt] [PATCH] tests: redo test argv file line wrapping

2015-11-06 Thread Daniel P. Berrange
On Fri, Nov 06, 2015 at 04:00:04PM +0100, Martin Kletzander wrote: > On Fri, Nov 06, 2015 at 01:30:35PM +, Daniel P. Berrange wrote: > >Back in > > > > commit bd6c46fa0cfe275c24debc1152cfc5206c04b59b > > Author: Juerg Haefliger > > Date: Mon Jan 31 06:42:57 2011

Re: [libvirt] [PATCH] vz: implement memory setting functions in driver

2015-11-06 Thread Maxim Nestratov
05.11.2015 13:13, Nikolay Shirokovskiy пишет: Implement functions for vz containers only. vz VMs memory managment thru libvirt yet to be designed. [snip] static virHypervisorDriver vzDriver = { .name = "vz", .connectOpen = vzConnectOpen,/* 0.10.0 */ @@ -1499,6

Re: [libvirt] [PATCH] tests: redo test argv file line wrapping

2015-11-06 Thread Martin Kletzander
On Fri, Nov 06, 2015 at 03:20:31PM +, Daniel P. Berrange wrote: On Fri, Nov 06, 2015 at 04:00:04PM +0100, Martin Kletzander wrote: On Fri, Nov 06, 2015 at 01:30:35PM +, Daniel P. Berrange wrote: >Back in > > commit bd6c46fa0cfe275c24debc1152cfc5206c04b59b > Author: Juerg Haefliger

Re: [libvirt] [PATCH] tests: redo test argv file line wrapping

2015-11-06 Thread Daniel P. Berrange
On Fri, Nov 06, 2015 at 04:32:52PM +0100, Martin Kletzander wrote: > On Fri, Nov 06, 2015 at 03:20:31PM +, Daniel P. Berrange wrote: > >On Fri, Nov 06, 2015 at 04:00:04PM +0100, Martin Kletzander wrote: > >>On Fri, Nov 06, 2015 at 01:30:35PM +, Daniel P. Berrange wrote: > >>>Back in > >>>

[libvirt] [PATCH 0/2] qemu: Fix mlock limit on memory hotplug

2015-11-06 Thread Peter Krempa
This is necessary so that VFIO doesn't break killing the guests. Peter Krempa (2): qemu: Extract logic to determine the mlock limit size for VFIO qemu: hotplug: Fix mlock limit handling on memory hotplug src/qemu/qemu_command.c | 18 ++ src/qemu/qemu_domain.c | 44

[libvirt] [PATCH 1/2] qemu: Extract logic to determine the mlock limit size for VFIO

2015-11-06 Thread Peter Krempa
New function qemuDomainGetMlockLimitBytes will now handle the calculation so that it unifies the logic to one place and allows later reuse. --- src/qemu/qemu_command.c | 18 ++ src/qemu/qemu_domain.c | 17 + src/qemu/qemu_domain.h | 2 ++ src/qemu/qemu_hotplug.c

[libvirt] [PATCH 2/2] qemu: hotplug: Fix mlock limit handling on memory hotplug

2015-11-06 Thread Peter Krempa
If mlock is required either due to use of VFIO hostdevs or due to the fact that it's enabled it needs to be tweaked prior to adding new memory or after removing a module. Add a helper to determine when it's necessary and reuse it both on hotplug and hotunplug. Resolves:

Re: [libvirt] [PATCH] tests: redo test argv file line wrapping

2015-11-06 Thread Daniel P. Berrange
On Fri, Nov 06, 2015 at 03:20:31PM +, Daniel P. Berrange wrote: > On Fri, Nov 06, 2015 at 04:00:04PM +0100, Martin Kletzander wrote: > > On Fri, Nov 06, 2015 at 01:30:35PM +, Daniel P. Berrange wrote: > > >Back in > > > > > > commit bd6c46fa0cfe275c24debc1152cfc5206c04b59b > > > Author:

Re: [libvirt] [PATCH] tests: redo test argv file line wrapping

2015-11-06 Thread Eric Blake
On 11/06/2015 09:16 AM, Daniel P. Berrange wrote: >>> >>> What if we fix the syntax-check instead and allow longer than 80 >>> character lines in case they have no space in it, or exactly one space >>> (to allow --parameter option,option,option,...)? That would make even >>> corner cases easier

[libvirt] [PATCH v2] tests: redo test argv file line wrapping

2015-11-06 Thread Daniel P. Berrange
Back in commit bd6c46fa0cfe275c24debc1152cfc5206c04b59b Author: Juerg Haefliger Date: Mon Jan 31 06:42:57 2011 -0500 tests: handle backspace-newline pairs in test input files all the test argv files were line wrapped so that the args were less than 80

Re: [libvirt] [PATCH] tests: redo test argv file line wrapping

2015-11-06 Thread Daniel P. Berrange
On Fri, Nov 06, 2015 at 09:23:20AM -0700, Eric Blake wrote: > On 11/06/2015 09:16 AM, Daniel P. Berrange wrote: > > >>> > >>> What if we fix the syntax-check instead and allow longer than 80 > >>> character lines in case they have no space in it, or exactly one space > >>> (to allow --parameter

[libvirt] [PATCH 1/5] Revert "utils: Remove the logging of errors from virNetDevSendEthtoolIoctl"

2015-11-06 Thread John Ferlan
From: "Daniel P. Berrange" This reverts commit 6f2a0198e913c91a2ef8b99db79b7d3cc5396957. This commit removed error reporting from virNetDevSendEthtoolIoctl pushing responsibility onto the callers. This is wrong, however, since virNetDevSendEthtoolIoctl calls

[libvirt] [PATCH 4/5] virnetdev: Check for root in virNetDevGetFeatures

2015-11-06 Thread John Ferlan
Since the SIOCETHTOOL ioctl only works for privileged daemons, if called when not root, then virNetDevGetFeatures will VIR_DEBUG a message and return 0 as if the functions were not available for the architecture. This effectively returns an empty bitmap indicating no features available.

[libvirt] [PATCH 0/5] Revert virNetDevSendEthtoolIoctl logging errors and adjust code after

2015-11-06 Thread John Ferlan
It's partially a reposting, partially some new stuff, and perhaps a v2 of something else. Patch 1 is Dan's revert patch - just because it's easier to have it done first. Patches 2 & 3 just adjust comments - no functional changes Patch 4 adds a check for root in virNetDevGetFeatures (rather than

[libvirt] [PATCH 3/5] virnetdev: Fix function comments for virNetDevGetFeatures

2015-11-06 Thread John Ferlan
In commit id 'c9027d8f4' when updating the posted patch to generate a bitmap instead of an array of named feature bits, adjustment of the args was missed Signed-off-by: John Ferlan --- src/util/virnetdev.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git

[libvirt] [PATCH 2/5] virnetdev: Document reasons for ignoring some SIOCETHTOOL errno values

2015-11-06 Thread John Ferlan
Recently reverted commit id '6f2a0198' showed a need to add extra comments when dealing with filtering of potential "non-issues". Scanning through upstream patch postings indicates early on the reasons for the filtering of specific ioctl failures were provided; however, when converted from

[libvirt] [PATCH 5/5] virnetdev: Use virNetDevSetupControl in virNetDevSendEthtoolIoctl

2015-11-06 Thread John Ferlan
Use virNetDevSetupControl instead of open coding using socket(AF_LOCAL...) and clearing virIfreq. By using virNetDevSetupControl, the socket is then opened using AF_PACKET which requires being privileged (effectively root) in order to complete successfully. Since that's now a requirement, then

Re: [libvirt] [PATCH 0/5] Revert virNetDevSendEthtoolIoctl logging errors and adjust code after

2015-11-06 Thread Daniel P. Berrange
On Fri, Nov 06, 2015 at 11:39:26AM -0500, John Ferlan wrote: > It's partially a reposting, partially some new stuff, and perhaps a v2 > of something else. > > Patch 1 is Dan's revert patch - just because it's easier to have it > done first. > > Patches 2 & 3 just adjust comments - no functional

Re: [libvirt] [PATCH 1/2] qemu: Extract logic to determine the mlock limit size for VFIO

2015-11-06 Thread John Ferlan
On 11/06/2015 10:47 AM, Peter Krempa wrote: > New function qemuDomainGetMlockLimitBytes will now handle the > calculation so that it unifies the logic to one place and allows later > reuse. > --- > src/qemu/qemu_command.c | 18 ++ > src/qemu/qemu_domain.c | 17 +

[libvirt] [PATCH v3 02/11] virt-admin: Introduce first working skeleton

2015-11-06 Thread Erik Skultety
This patch introduces virt-admin client which is based on virsh client, but had to reimplement several methods to meet virt-admin specific needs or remove unnecessary virsh specific logic. --- .gitignore | 1 + po/POTFILES.in | 1 + tools/Makefile.am | 26 ++- tools/virt-admin.c

[libvirt] [PATCH v3 04/11] admin: Move remote admin API version to a separate module

2015-11-06 Thread Erik Skultety
By moving the remote version into a separate module, we gain a slightly better maintainability in the long run than just by leaving it in one place with the existing libvirt-admin library which can start getting pretty messy later on. --- src/admin/admin_remote.c | 136

[libvirt] [PATCH v3 07/11] livirt: Move URI alias matching to util

2015-11-06 Thread Erik Skultety
As we need to provide support for URI aliases in libvirt-admin as well, URI alias matching needs to be internally visible. Since virConnectOpenResolveURIAlias does have a compatible signature, it could be easily reused by libvirt-admin. This patch moves URI alias matching to util, renaming it

[libvirt] [PATCH v3 09/11] admin: Add support for connection close callbacks

2015-11-06 Thread Erik Skultety
As we need a client disconnect handler, we also need a mechanism to register such handlers for a client. This patch introduced both the close callbacks and also the client vshAdmCatchDisconnect handler to be registered with it. By registering the handler we still need to make sure the client can

[libvirt] [PATCH v3 10/11] admin: Introduce virAdmConnectGetLibVersion

2015-11-06 Thread Erik Skultety
Introduce a new API to get libvirt version. It is worth noting, that libvirt-admin and libvirt share the same version number. Unfortunately, our existing API isn't generic enough to be used with virAdmConnectPtr as well. Also this patch wires up this API to the virt-admin client as a generic

[libvirt] [PATCH v3 11/11] virt-admin: Provide a man page for virt-admin

2015-11-06 Thread Erik Skultety
--- tools/Makefile.am| 12 +-- tools/virt-admin.pod | 255 +++ 2 files changed, 259 insertions(+), 8 deletions(-) create mode 100644 tools/virt-admin.pod diff --git a/tools/Makefile.am b/tools/Makefile.am index 62073f9..9180564 100644 ---

Re: [libvirt] [PATCH 0/7] Drop support for QEMU < 0.12.0

2015-11-06 Thread Daniel P. Berrange
On Thu, Nov 05, 2015 at 05:33:52PM +, Daniel P. Berrange wrote: > The patches for introducing virtlogd will be significantly > simplified if we don't need to worry about parsing stderr > during startup. This is required prior to QEMU 0.11 so > that we can get the dyanamically allocated

Re: [libvirt] [PATCH 2/2] qemu: hotplug: Fix mlock limit handling on memory hotplug

2015-11-06 Thread John Ferlan
On 11/06/2015 10:47 AM, Peter Krempa wrote: > If mlock is required either due to use of VFIO hostdevs or due to the > fact that it's enabled it needs to be tweaked prior to adding new memory > or after removing a module. Add a helper to determine when it's > necessary and reuse it both on

[libvirt] [PATCH v3 06/11] admin: Add URI support and introduce virAdmGetDefaultURI

2015-11-06 Thread Erik Skultety
Since virt-admin should be able to connect to various admin servers on hosted different daemons, we need to provide URI support to libvirt-admin. --- include/libvirt/libvirt-admin.h | 2 + src/datatypes.c | 2 + src/datatypes.h | 1 + src/libvirt-admin.c

[libvirt] [PATCH v3 03/11] admin: Introduce virAdmConnectIsAlive

2015-11-06 Thread Erik Skultety
Since most of our APIs rely on an acive functional connection to a daemon and we have such a mechanism in libvirt already, there's need to have such a way in libvirt-admin as well. By introducing a new public API, this patch provides support to check for an active connection. ---

[libvirt] [PATCH v3 01/11] libvirt: Export libvirt config getters by moving them to util

2015-11-06 Thread Erik Skultety
virConnectGetConfig and virConnectGetConfigPath were static libvirt methods, merely because there hasn't been any need for having them internally exported yet. Since libvirt-admin also needs to reference libvirt config file, 'xGetConfig' should be exported. Besides moving, this patch also renames

[libvirt] [PATCH v3 05/11] admin: Do not generate remoteAdminConnect{Open, Close}

2015-11-06 Thread Erik Skultety
As we plan to add more and more logic to remote connecting methods, these cannot be generated from admin_protocol.x anymore. Instead, this patch implements these to methods explicitly. --- src/admin/admin_protocol.x | 4 ++-- src/admin/admin_remote.c | 45

[libvirt] [PATCH v3 00/11] Introduce virt-admin client

2015-11-06 Thread Erik Skultety
v1: 1/9 - ACKed if adjusted 6/9 - ACKed 8/9 - ACKed if squashed into 4/9 --> resolves 7/9 v2: - double empty line in private.syms is preserved (1/9) - adjusted authors of virt-admin modules (2/9) - removed unnecessary includes from virt-admin module (2/9) - replaced "int" disconnected type

[libvirt] [PATCH v3 08/11] admin: Add support for URI aliases

2015-11-06 Thread Erik Skultety
Now that we introduced URI support in libvirt-admin, we should also support URI aliases during connection establishment phase. After applying this patch, virAdmConnectOpen will also support VIR_CONNECT_NO_ALIASES flag. --- src/libvirt-admin.c | 9 - 1 file changed, 8 insertions(+), 1

Re: [libvirt] [PATCH v3 07/11] livirt: Move URI alias matching to util

2015-11-06 Thread Daniel P. Berrange
On Fri, Nov 06, 2015 at 12:46:22PM +0100, Erik Skultety wrote: > As we need to provide support for URI aliases in libvirt-admin as well, URI > alias matching needs to be internally visible. Since > virConnectOpenResolveURIAlias does have a compatible signature, it could be > easily reused by

Re: [libvirt] [PATCH 0/2] Fix spurious error when migrating with memory hotplug

2015-11-06 Thread Peter Krempa
On Thu, Nov 05, 2015 at 20:37:09 +0100, Jiri Denemark wrote: > On Thu, Nov 05, 2015 at 15:38:41 +0100, Peter Krempa wrote: > > Peter Krempa (2): > > qemu: migration: Properly parse memory hotplug migration flag > > qemu: migration: Actually error out on unsupported migration flag > > > >