[libvirt] [PATCHv2 0/2] storage backend support matrix
by Cedric Bosdonnat
Hello,
Here is an updated version of the previous Storage backend support matrix in the doc.
As discussed with Michal, the matrix is now part of hvsupport.html with a
paragraph and link from storage.html.
This has now been turned into a series to fix the links in TOC of the storage
page
Cédric Bosdonnat (2):
Fix hvsupport toc
Generate status of the backend implementation in hvsupport.html
.gitignore | 1 +
docs/Makefile.am | 12 +++++--
docs/apibuild.py | 2 ++
docs/hvsupport.pl | 4 ++-
docs/storage.html.in | 13 ++++++++
docs/storagebackendstatus.py | 63 ++++++++++++++++++++++++++++++++++++
6 files changed, 91 insertions(+), 4 deletions(-)
create mode 100644 docs/storagebackendstatus.py
--
2.22.0
5 years, 3 months
[libvirt] [ocaml PATCH] Make const the return value of caml_named_value()
by Pino Toscano
With OCaml >= 4.09 caml_named_value() returns a const value *, so keep
the constness to build also in this case.
Signed-off-by: Pino Toscano <ptoscano(a)redhat.com>
---
libvirt/libvirt_c_oneoffs.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/libvirt/libvirt_c_oneoffs.c b/libvirt/libvirt_c_oneoffs.c
index 6f56f10..e23c0db 100644
--- a/libvirt/libvirt_c_oneoffs.c
+++ b/libvirt/libvirt_c_oneoffs.c
@@ -1207,7 +1207,7 @@ ocaml_libvirt_event_run_default_impl (value unitv)
#define DOMAIN_CALLBACK_BEGIN(NAME) \
value connv, domv, callback_id, result; \
connv = domv = callback_id = result = Val_int(0); \
- static value *callback = NULL; \
+ static const value *callback = NULL; \
caml_leave_blocking_section(); \
if (callback == NULL) \
callback = caml_named_value(NAME); \
@@ -1433,7 +1433,7 @@ timeout_callback(int timer, void *opaque)
{
value callback_id, result;
callback_id = result = Val_int(0);
- static value *callback = NULL;
+ static const value *callback = NULL;
caml_leave_blocking_section();
if (callback == NULL)
callback = caml_named_value("Libvirt.timeout_callback");
--
2.21.0
5 years, 3 months
[libvirt] [PATCH python] Fix -Wsign-compare warnings
by Cole Robinson
libvirt-override.c: In function ‘libvirt_virConnectBaselineHypervisorCPU’:
libvirt-override.c:9946:23: warning: comparison of integer expressions of different signedness: ‘size_t’ {aka ‘long unsigned int’} and ‘int’ [-Wsign-compare]
libvirt-override.c:9961:19: warning: comparison of integer expressions of different signedness: ‘size_t’ {aka ‘long unsigned int’} and ‘int’ [-Wsign-compare]
Use ssign_t as was similarly done in 75ec2acb6163b
Signed-off-by: Cole Robinson <crobinso(a)redhat.com>
---
libvirt-override.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/libvirt-override.c b/libvirt-override.c
index 5567f4a..ff2cfdf 100644
--- a/libvirt-override.c
+++ b/libvirt-override.c
@@ -9927,7 +9927,7 @@ libvirt_virConnectBaselineHypervisorCPU(PyObject *self ATTRIBUTE_UNUSED,
unsigned int flags;
char **xmlCPUs = NULL;
int ncpus = 0;
- size_t i;
+ ssize_t i;
char *cpu;
PyObject *ret = NULL;
--
2.21.0
5 years, 3 months
[libvirt] [PATCH] conf: domain: Fix tpm <encryption> comment
by Cole Robinson
The attribute is named 'secret', not 'uuid'
Signed-off-by: Cole Robinson <crobinso(a)redhat.com>
---
Pushed as trivial
src/conf/domain_conf.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c
index b7a342bb91..6c429cd593 100644
--- a/src/conf/domain_conf.c
+++ b/src/conf/domain_conf.c
@@ -13064,7 +13064,7 @@ virDomainSmartcardDefParseXML(virDomainXMLOptionPtr xmlopt,
*
* <tpm model='tpm-tis'>
* <backend type='emulator' version='2.0'>
- * <encryption uuid='32ee7e76-2178-47a1-ab7b-269e6e348015'/>
+ * <encryption secret='32ee7e76-2178-47a1-ab7b-269e6e348015'/>
* </backend>
* </tpm>
*/
--
2.21.0
5 years, 3 months
Re: [libvirt] [Qemu-block] [PATCH] docs: Update preferred NBD device syntax
by Eric Blake
[adding libvirt list]
On 9/3/19 1:50 PM, John Snow wrote:
>
>
> On 9/3/19 10:56 AM, Eric Blake wrote:
>> Mention the preferred URI form, especially since NBD is trying to
>> standardize that form: https://lists.debian.org/nbd/2019/06/msg00012.html
>>
>> Signed-off-by: Eric Blake <eblake(a)redhat.com>
>> ---
>> qemu-doc.texi | 16 +++++++++++-----
>> 1 file changed, 11 insertions(+), 5 deletions(-)
>>
>> diff --git a/qemu-doc.texi b/qemu-doc.texi
>> index 577d1e837640..c83fb347d77e 100644
>> --- a/qemu-doc.texi
>> +++ b/qemu-doc.texi
>> @@ -297,7 +297,14 @@ qemu-system-i386 -drive file=iscsi://192.0.2.1/iqn.2001-04.com.example/1
>>
>> @item NBD
>> QEMU supports NBD (Network Block Devices) both using TCP protocol as well
>> -as Unix Domain Sockets.
>> +as Unix Domain Sockets. With TCP, the default port is 10809.
>>
>> -Syntax for specifying a NBD device using TCP
>> +Syntax for specifying a NBD device using TCP, in preferred URI form:
>> +``nbd://<server-ip>[:<port>]/[<export>]''
>> +
>> +Syntax for specifying a NBD device using Unix Domain Sockets; remember
>> +that '?' is a shell glob character and may need quoting:
>> +``nbd+unix:///[<export>]?socket=<domain-socket>''
>> +
>> +Older syntax that is also recognized:
>
> Deprecated officially, or no?
>
>> ``nbd:<server-ip>:<port>[:exportname=<export>]''
>>
>> -Syntax for specifying a NBD device using Unix Domain Sockets
>> ``nbd:unix:<domain-socket>[:exportname=<export>]''
I didn't feel like starting a deprecation clock, in part because libvirt
is still using nbd:host:port:exportname during migration, similarly code
in virstoragefile.c is using only the old form. Do we want to start a
deprecation (as a separate patch), to prod faster changes in libvirt in
switching to the newer form where sensible?
>>
>> Example for TCP
>> @example
>> -qemu-system-i386 --drive file=nbd:192.0.2.1:30000
>> +qemu-system-i386 --drive file=nbd://192.0.2.1:30000
>> @end example
>>
>> Example for Unix Domain Sockets
>> @example
>> -qemu-system-i386 --drive file=nbd:unix:/tmp/nbd-socket
>> +qemu-system-i386 --drive "file=nbd+unix:///?socket=/tmp/nbd-socket"
>> @end example
>>
>> @item SSH
>>
>
> Reviewed-by: John Snow <jsnow(a)redhat.com>
Thanks; will queue through my NBD tree (regardless of whether we decide
I should add more patches to start a deprecation cycle).
--
Eric Blake, Principal Software Engineer
Red Hat, Inc. +1-919-301-3226
Virtualization: qemu.org | libvirt.org
5 years, 3 months
[libvirt] [PATCH 0/6] hostdev: handle usb detach/attach on node
by Nikolay Shirokovskiy
Hi, all.
This patch series aims to handle case when hostdev usb is detached and then
attached back on node. Currently libvirtd does not track these events so that in
the result hostdev usb is not usable.
On the first glace it make sense to delete device from qemu when hostdev is
detached on node and then add device back when hostdev is attached back. But
these series adds a different behaviour. On detaching device is deleted from
qemu and dummy (missing hostaddr and hostbus values) hostdev is inserted, then
on attaching device on node dummy device is deleted and proper one is inserted.
This way we have the same semantics of 'missing' flag for hostdev as in case of
hostdev missing on startup/migration to different host. Also with such
approach we additionally handle cases when hostdev is missing on startup but
later is attached to node.
Known issues:
The last patch tries to handle case when hostdev attached/detached when
libvirtd is down but if fails in one scenario. If hostdev is detached and thus
dummy device in inserted in qemu then if libvirtd is down and hostdev is
attached to node then qemu tries to bind appeared hostdev to the dummy device
but fails as device is missing in qemu's mount namespace. Later when libvirtd
is up and tries to replace dummy device with actual one the device_add fails
because libusb the qemu uses tracks that deviced was missed ealier. For this
reason I proposed to get rid of dummy device in RFC [1]. Alternatively libusb
can be fixed.
[1] https://www.redhat.com/archives/libvir-list/2019-August/msg01396.html
Nikolay Shirokovskiy (6):
qemu: track hostdev delete cause
qemu: handle usb hostdev add/del udev events
qemu: handle usb hostdev add/del on device DELETED_EVENT
conf: parse hostdev missing flag
qemu: handle libvirtd restarts during hostdev reattaching
qemu: handle hostdev add/del when libvirtd is down
src/conf/domain_conf.c | 32 ++++
src/conf/domain_conf.h | 10 ++
src/qemu/Makefile.inc.am | 2 +
src/qemu/qemu_conf.h | 3 +
src/qemu/qemu_domain.c | 2 +
src/qemu/qemu_domain.h | 2 +
src/qemu/qemu_driver.c | 376 +++++++++++++++++++++++++++++++++++++--
src/qemu/qemu_hotplug.c | 94 ++++++++--
src/qemu/qemu_hotplug.h | 7 +-
src/qemu/qemu_process.c | 55 +++++-
src/util/virhostdev.c | 6 +-
tests/qemuhotplugtest.c | 2 +-
12 files changed, 558 insertions(+), 33 deletions(-)
--
2.23.0
5 years, 3 months
[libvirt] [PATCH] maint: Post-release version bump to 5.8.0
by Jim Fehlig
Signed-off-by: Jim Fehlig <jfehlig(a)suse.com>
---
Pushed under trivial rule. Usually done by Michal but I need to push
other changes to news for the 5.8.0 cycle.
configure.ac | 2 +-
docs/news.xml | 8 ++++++++
2 files changed, 9 insertions(+), 1 deletion(-)
diff --git a/configure.ac b/configure.ac
index 7c76a9c9ec..da13d4f1ab 100644
--- a/configure.ac
+++ b/configure.ac
@@ -16,7 +16,7 @@ dnl You should have received a copy of the GNU Lesser General Public
dnl License along with this library. If not, see
dnl <http://www.gnu.org/licenses/>.
-AC_INIT([libvirt], [5.7.0], [libvir-list(a)redhat.com], [], [https://libvirt.org])
+AC_INIT([libvirt], [5.8.0], [libvir-list(a)redhat.com], [], [https://libvirt.org])
AC_CONFIG_SRCDIR([src/libvirt.c])
AC_CONFIG_AUX_DIR([build-aux])
AC_CONFIG_HEADERS([config.h])
diff --git a/docs/news.xml b/docs/news.xml
index 2484933f9a..0e3445ca41 100644
--- a/docs/news.xml
+++ b/docs/news.xml
@@ -39,6 +39,14 @@
-->
<libvirt>
+ <release version="v5.8.0" date="unreleased">
+ <section title="New features">
+ </section>
+ <section title="Improvements">
+ </section>
+ <section title="Bug fixes">
+ </section>
+ </release>
<release version="v5.7.0" date="2019-09-03">
<section title="New features">
<change>
--
2.22.0
5 years, 3 months
[libvirt] Release of libvirt 5.7.0
by Daniel Veillard
A few hours ago I tagged the release in git and pushed the signed tarball
and source rpm to the usual place:
https://libvirt.org/sources/
I also tagged a release of the python bindings which you can find at
https://libvirt.org/sources/python/
This is a balanced release with new features, improvements and bug fixes, also
note some deprecation for KVM assignment support and for build with older versions
of libxml2.
New features:
- qemu: Support Direct Mode for Hyper-V Synthetic timers
The QEMU driver now supports Direct Mode for Hyper-V Synthetic timers
for Hyper-V guests.
- lib: Add virDomainGetGuestInfo()
This API is intended to aggregate several guest agent information
queries and is inspired by stats API virDomainListGetStats(). It is
anticipated that this information will be provided by a guest agent
running within the domain. It's exposed as virsh guestinfo.
- Split libvirtd into separate daemons
The big monolithic libvirtd daemon can now be replaced by smaller
per-driver daemons. Distributions can chose if they want the former or
the latter. The libvirtd is still kept around for backwards
compatibility.
Removed features:
- Remove KVM assignment support
The KVM style of PCI device assignment was removed from the kernel in
version 4.12.0 after being deprecated since 4.2.0. Libvirt defaults to
VFIO for a long time. Remove support for KVM device assignment from
libvirt too.
- libxml: min required libxml is now 2.9.1
Support for building with libxml versions older than 2.9.1 has been
dropped.
Improvements:
- virsh: Support setting bandwidth in migrate subcommand
In addition to postcopy bandwidth, the virsh migrate subcommand now
supports specifying precopy bandwidth with the --bandwidth parameter.
- libxl: Implement domain metadata getter/setter
The libxl driver now supports virDomainGetMetadata() and
virDomainSetMetadata() APIs.
- test driver: Expand API coverage
Additional APIs have been implemented in the test driver.
- Report RNG device in domain capabilities XML
Libvirt now reports if RNG devices are supported by the underlying
hypervisor in the domain capabilities XML.
- Stop linking virt-login-shell and NSS plugins with libvirt.so
In order to allow libvirt to abort on out of memory, we need to stop
linking libvirt.so to virt-login-shell or the NSS plugins where we
don't want to abort. This change also resulted in smaller binaries and
libraries.
- qemu: Allow migration with disk cache on
When QEMU supports flushing caches at the end of migration, we can
safely allow migration even if disk/driver/@cache is neither none nor
directsync.
Bug fixes:
- Various security label remembering fixes
In the previous release libvirt introduced remembering of original
owners and SELinux labels on files. However, the feature did not work
properly with snapshots, on migrations or on network filesystems. This
is now fixed.
- Allow greater PCI domain numbers
Libvirt used to require PCI domain number to be not greater than
0xFFFF. The code was changed to allow 32 bits long numbers.
- Various D-Bus fixes
When D-Bus is not available, libvirt was reporting random errors. These
are now gone.
- Prefer read-only opening of PCI config files
When enumerating PCI bus, libvirt opens config files under sysfs mount
and parses them to learn various aspects of the device (e.g. its
capabilities). Only in a very limited number of cases it is actually
writing into the file. However, it used to open the file also for
writing even if it was only reading from it.
- Fix AppArmor profile
Since the 5.6.0 release, libvirt uses procfs to learn the list of
opened file descriptors when spawning a command. However, our AppArmor
profile was not allowing such access.
- Don't block storage driver when starting or building a pool
Starting or building a storage pool can take a long time to finish.
During this time the storage driver was blocked and thus no other API
involving the storage driver could run. This is now fixed.
Thanks everybody who helped for this release, be it with patches, reviews,
bug reports, docs, etc...
Enjoy the release !
Daniel
--
Daniel Veillard | Red Hat Developers Tools http://developer.redhat.com/
veillard(a)redhat.com | libxml Gnome XML XSLT toolkit http://xmlsoft.org/
http://veillard.com/ | virtualization library http://libvirt.org/
5 years, 3 months
[libvirt] [PATCH] news: rewording wrt NSS, virt-login-shell & split daemons
by Daniel P. Berrangé
Signed-off-by: Daniel P. Berrangé <berrange(a)redhat.com>
---
docs/news.xml | 27 ++++++++++++++++++---------
1 file changed, 18 insertions(+), 9 deletions(-)
diff --git a/docs/news.xml b/docs/news.xml
index bd112d56dc..f376e991cb 100644
--- a/docs/news.xml
+++ b/docs/news.xml
@@ -65,13 +65,13 @@
</change>
<change>
<summary>
- Split libvirtd into separate daemons
+ Experimental split of libvirtd into separate daemons
</summary>
<description>
The big monolithic libvirtd daemon can now be replaced by smaller
- per-driver daemons. Distributions can chose if they want the former
- or the latter. The libvirtd is still kept around for backwards
- compatibility.
+ per-driver daemons. The new split daemons are considered experimental
+ at this time and distributions are encouraged to continue using the
+ traditional libvirtd by default.
</description>
</change>
</section>
@@ -136,13 +136,22 @@
</change>
<change>
<summary>
- Stop linking virt-login-shell and NSS plugins with libvirt.so
+ Stop linking NSS plugins with libvirt.so
</summary>
<description>
- In order to allow libvirt to abort on out of memory, we need to stop
- linking libvirt.so to virt-login-shell or the NSS plugins where we
- don't want to abort. This change also resulted in smaller binaries
- and libraries.
+ This reduces the amount of code and 3rd party libraries are that
+ loaded into all processes.
+ </description>
+ </change>
+ <change>
+ <summary>
+ Split the setuid virt-login-shell binary into two pieces
+ </summary>
+ <description>
+ The setuid virt-login-shell binary is now a tiny shim that
+ sanitizes the process execution environment variables and
+ arguments, before launching the trusted virt-login-shell-helper
+ binary.
</description>
</change>
<change>
--
2.21.0
5 years, 3 months