[libvirt] conftest segfault
by Gene Czarcinski
One of the libvirt tests (conftest) has been segfaulting for some time
with no indication of a test failure other than a message in syslog. I
verified this by building libvirt-1.0.3-1 with mock.
Gene
11 years, 9 months
[libvirt] [libvirt-designer 1/2] Fix libvirt caps -> libosinfo platform short id mapping
by Christophe Fergeau
The code was building an id starting with kvm- while libosinfo qemu
description uses qemu-kvm-. Also, starting from qemu 1.2.0, there is
no separate qemu-kvm tarball.
guess_platform_from_connect is starting to be a bit magic, it may
be better to add a <machine> attribute to libosinfo <platform>
description and to use this to improve the matching between
libosinfo data and libvirt caps.
---
examples/virtxml.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/examples/virtxml.c b/examples/virtxml.c
index 09f49cf..a68843d 100644
--- a/examples/virtxml.c
+++ b/examples/virtxml.c
@@ -442,13 +442,13 @@ guess_platform_from_connect(GVirConnection *conn)
}
/* do some mappings:
- * QEMU -> kvm
+ * QEMU -> qemu-kvm
* Xen -> xen
*/
type = g_ascii_strdown(hv_type, -1);
- if (g_str_equal(type, "qemu")) {
+ if (g_str_equal(type, "qemu") && ver <= 1002000) {
g_free(type);
- type = g_strdup("kvm");
+ type = g_strdup("qemu-kvm");
}
major = ver / 1000000;
--
1.8.1.4
11 years, 9 months
[libvirt] [PATCH 1/2] Fix /pool/storage/directory@path documentation
by Christophe Fergeau
Because of a wrong copy and paste, the documentation was saying that
'path' is the path to a block device node while it's a path to a
directory.
---
Pushed under the trivial rule
docs/formatstorage.html.in | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/docs/formatstorage.html.in b/docs/formatstorage.html.in
index 8ac7ab1..49ae818 100644
--- a/docs/formatstorage.html.in
+++ b/docs/formatstorage.html.in
@@ -84,7 +84,7 @@
<dt><code>directory</code></dt>
<dd>Provides the source for pools backed by directories. May
only occur once. Contains a single attribute <code>path</code>
- which is the fully qualified path to the block device node.
+ which is the fully qualified path to the backing directory.
<span class="since">Since 0.4.1</span></dd>
<dt><code>adapter</code></dt>
<dd>Provides the source for pools backed by SCSI adapters. May
--
1.8.1.4
11 years, 9 months
[libvirt] [PATCH 0/5]Add startupPolicy attribute support for hard disks
by Guannan Ren
The set of patches is trying to add 'startupPolicy' attribute support
to the source element of hard disks. Policy levels are using the
mandatory, requisite, optional levels as originally documented.
For the 'optional' policy, there is a little difference from CDROM and
Floppy which only drop its source path, for disks, if missing, the
checking function will drop their definitions, because qemu doesn't
allow missing source path for hard disk.
If guest is using per-device boot element for its devices, after dropping
one or more bootable device, the boot order will not be contiguous, the way
here I use is to reorder them to make them contiguous. In this way, I
introduce two new bit-operating functions
virBitmapNextLastSetBit: Search for the last set bit before
certain position.
virBitmapNextLastSetBit: Search for the last clear bit before
certain position.
Guannan Ren(5)
[PATCH 1/5] conf: add startupPolicy attribute for harddisk
[PATCH 2/5] util: add two functions to find last set or unset bit in
[PATCH 3/5] qemu: move disk presence checking before disk chain
[PATCH 4/5] qemu: drop disk definition if missing and reorder
[PATCH 5/5] event: add hard disk dropping event reason enum
docs/formatdomain.html.in | 9 +++++---
include/libvirt/libvirt.h.in | 1 +
src/conf/domain_conf.c | 21 +++++++++++++------
src/conf/domain_conf.h | 1 +
src/libvirt_private.syms | 2 ++
src/qemu/qemu_domain.c | 106 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++----------
src/qemu/qemu_process.c | 7 ++++---
src/util/virbitmap.c | 96 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
src/util/virbitmap.h | 6 ++++++
tests/virbitmaptest.c | 51 +++++++++++++++++++++++++++++++++++++++++++++-
10 files changed, 276 insertions(+), 24 deletions(-)
11 years, 9 months
[libvirt] qmp monitor is broken
by Gerd Hoffmann
Hi,
$subject says it. Bisecting points to:
commit 23673ca740e0eda66901ca801a5a901df378b063
Author: Anthony Liguori <aliguori(a)us.ibm.com>
Date: Tue Mar 5 23:21:23 2013 +0530
qemu-char: add watch support
This allows a front-end to request for a callback when the backend
is writable again.
Signed-off-by: Anthony Liguori <aliguori(a)us.ibm.com>
Signed-off-by: Amit Shah <amit.shah(a)redhat.com>
Symtoms: "virsh start" hangs (not always, but most of the time). When
killing qemu it prints an error message:
error: Failed to start domain fedora-org-virtio
error: internal error cannot parse json {"return": [{"name":
"chardev-remove"}, {"name": "chardev-add"}, {"name": "query-target"},
{"name": "query-cpu-definitions"}, {"name": "query-machines"}, {"name":
"device-list-properties"}, {"name": "qom-list-types"}, {"name":
"change-vnc-password"}, {"name": "nbd-server-stop"}, {"name":
"nbd-server-add"}, {"name": "nbd-server-start"}, {"name": "qom-get"},
{"name": "qom-set"}, {"name": "qom-list"}, {"name": "query-block-jobs"},
{"name": "query-balloon"}, {"name": "query-migrate-capabilities"},
{"name": "migrate-set-capabilities"}, {"name": "query-migrate"},
{"name": "query-uuid"}, {"name": "query-name"}, {"name": "query-spice"},
{"name": "query-vnc"}, {"name": "query-mice"}, {"name": "query-status"},
{"name": "query-kvm"}, {"name": "query-pci"}, {"name": "query-cpus"},
{"name": "query-blockstats"}, {"name": "query-block"}, {"name":
"query-chardev"}, {"name": "query-events"}, {"name": "query-commands"},
{"name": "query-version"}, {"name": "human-monitor-command"}, {"name":
"qmp_capabilities
So it looks like a bulky qmp reply is written incomplete (or corrupted)
and libvirt waits forever for the missing bits ...
cheers,
Gerd
11 years, 9 months
[libvirt] [ANNOUNCE] libvirt-glib 0.1.6 release
by Daniel P. Berrange
I am pleased to announce that a new release of the libvirt-glib package,
version 0.1.6, is now available from
ftp://libvirt.org/libvirt/glib/
The packages are GPG signed with
Key fingerprint: DAF3 A6FD B26B 6291 2D0E 8E3F BE86 EBB4 1510 4FDF (4096R)
New in this release:
- Prefer g_strlcpy over strncpy
- Fix potential crashes in some error handling cases
- Fix typo in gvir_config_init docs which broke vala binding
- Use 'transfer none' for argv parameter in all init functions
- Ensure stream data parameters are annotated to be guint8
arrays, not gchar, since they're not NULL terminated
strings.
- Replace FSF address with URL in copyright headers
- Add API for changing Spice compression parameters.
libvirt-glib comprises three distinct libraries:
- libvirt-glib - Integrate with the GLib event loop and error handling
- libvirt-gconfig - Representation of libvirt XML documents as GObjects
- libvirt-gobject - Mapping of libvirt APIs into the GObject type system
NB: While libvirt aims to be API/ABI stable forever, with libvirt-glib
we are not yet guaranteeing that libvirt-glib libraries are API/ABI
permanently stable. As of the 0.0.8 release, we have tentatively frozen
the API/ABI with the intent of being longterm stable hereafter, but
there is still a small chance we might find flaws requiring an API/ABI
change. The likelihood of this is low, however, and we will strive to
avoid it.
Follow up comments about libvirt-glib should be directed to the regular
libvir-list(a)redhat.com development list.
Thanks to all the people involved in contributing to this release.
Regards,
Daniel
--
|: http://berrange.com -o- http://www.flickr.com/photos/dberrange/ :|
|: http://libvirt.org -o- http://virt-manager.org :|
|: http://autobuild.org -o- http://search.cpan.org/~danberr/ :|
|: http://entangle-photo.org -o- http://live.gnome.org/gtk-vnc :|
11 years, 9 months
[libvirt] [PATCH v8 0/3] DEVICE_DELETED event
by Michael S. Tsirkin
libvirt has a long-standing bug: when removing the device,
it can request removal but does not know when the
removal completes. Add an event so we can fix this in a robust way.
First patch only adds the event with ID, second patch adds a path field.
Split this way for ease of backport (stable downstreams without QOM
would want to only take the first patch).
Event without fields is still useful as management can use it to
poll device list to figure out which device was removed.
Signed-off-by: Michael S. Tsirkin <mst(a)redhat.com>
If there are no more comments I'll stick this on my
pci branch.
Changes from v7:
- none, v7 was malformed series sent by mistake
Changes from v6:
- make empty event use data: {}, Markus prefers this
Changes from v5:
- Emit an empty event on unnamed devices in patch 1/3, as suggested by Markus
Changes from v4:
- Add extra triggers and extra fields as requested by Markus
Changes from v3:
- Document that we only emit events for devices with
and ID, as suggested by Markus
Changes from v2:
- move event toward the end of device_unparent,
so that parents are reported after their children,
as suggested by Paolo
Changes from v1:
- move to device_unparent
- address comments by Andreas and Eric
--
Anthony Liguori
Michael S. Tsirkin (3):
qdev: DEVICE_DELETED event
qom: pass original path to unparent method
qmp: add path to device_deleted event
QMP/qmp-events.txt | 18 ++++++++++++++++++
hw/qdev.c | 15 +++++++++++++--
include/monitor/monitor.h | 1 +
include/qom/object.h | 3 ++-
monitor.c | 1 +
qapi-schema.json | 4 +++-
qom/object.c | 4 +++-
7 files changed, 41 insertions(+), 5 deletions(-)
--
MST
11 years, 9 months
[libvirt] [libvirt-sandbox][PATCH] Docs: fix a typo in help documents
by Alex Jia
Signed-off-by: Alex Jia <ajia(a)redhat.com>
---
bin/virt-sandbox.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/bin/virt-sandbox.c b/bin/virt-sandbox.c
index bd7ac49..654a205 100644
--- a/bin/virt-sandbox.c
+++ b/bin/virt-sandbox.c
@@ -87,10 +87,10 @@ int main(int argc, char **argv) {
{ "name", 'n', 0, G_OPTION_ARG_STRING, &name,
N_("name of the sandbox"), "NAME" },
{ "mount", 'm', 0, G_OPTION_ARG_STRING_ARRAY, &mounts,
- N_("mount a filesystem int he guest"), "TYPE:TARGET=SOURCE" },
+ N_("mount a filesystem in the guest"), "TYPE:TARGET=SOURCE" },
{ "include", 'i', 0, G_OPTION_ARG_STRING_ARRAY, &includes,
N_("file to copy into custom dir"), "GUEST-PATH=HOST-PATH", },
- { "includefile", 'I', 0, G_OPTION_ARG_STRING, &includefile,
+ { "interfile", 'I', 0, G_OPTION_ARG_STRING, &includefile,
N_("file contain list of files to include"), "FILE" },
{ "network", 'N', 0, G_OPTION_ARG_STRING_ARRAY, &networks,
N_("setup network interface properties"), "PATH", },
--
1.7.1
11 years, 9 months
[libvirt] [PATCH] qemu: Fix startupPolicy regression
by Jiri Denemark
Commit 82d5fe543720da6d83c1d6bfa1c347d7d9fda278
qemu: check backing chains even when cgroup is omitted
added backing file checks just before the code that removes optional
disks if they are not present. However, the backing chain code fails in
case the disk file does not exist, which makes qemuProcessStart fail
regardless on configured startupPolicy.
Note that startupPolicy implementation is still wrong after this patch
since it only check the first file in a possible chain. It should rather
check the complete backing chain. But this is an existing limitation
that can be solved later. After all, startupPolicy is most useful for
CDROM images and they won't make use of backing files in most cases.
---
src/qemu/qemu_process.c | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/src/qemu/qemu_process.c b/src/qemu/qemu_process.c
index 1941d4e..3d2b7d6 100644
--- a/src/qemu/qemu_process.c
+++ b/src/qemu/qemu_process.c
@@ -3621,14 +3621,15 @@ int qemuProcessStart(virConnectPtr conn,
goto cleanup;
VIR_DEBUG("Checking for CDROM and floppy presence");
+ if (qemuDomainCheckDiskPresence(driver, vm,
+ flags & VIR_QEMU_PROCESS_START_COLD) < 0)
+ goto cleanup;
+
for (i = 0; i < vm->def->ndisks ; i++) {
if (qemuDomainDetermineDiskChain(driver, vm->def->disks[i],
false) < 0)
goto cleanup;
}
- if (qemuDomainCheckDiskPresence(driver, vm,
- flags & VIR_QEMU_PROCESS_START_COLD) < 0)
- goto cleanup;
/* Get the advisory nodeset from numad if 'placement' of
* either <vcpu> or <numatune> is 'auto'.
--
1.8.1.5
11 years, 9 months