[libvirt] PATCH 2/2: Support <video> element in QEMU driver
by Daniel P. Berrange
This patch extends the QEMU driver to support the <video> element
for configuring the type of video adapter exposed to the guest.
It implements the XML -> ARGV and ARGV -> XML conversions, so both
import & export work. Some of the existing tests are updated to
use the <video> element to get test coverage. The QEMU help parsing
test is changed to use symbolic constants instead of black magic
hex constants. This supports both old -std-vga and new -vga style
QEMU args.
Daniel
From: Daniel P. Berrange <berrange(a)redhat.com>
Date: Mon, 6 Jul 2009 14:59:19 +0100
Subject: [PATCH 2/3] Support <video> element for QEMU guests
* src/qemu_conf.c, src/qemu_conf.h: Use -vga or -std-vga
when starting guests if video card is present
* tests/qemuhelptest.c: Change to use constants instead
of hardcoded hex numbers, and add VGA support
* tests/qemuxml2argvdata/qemuxml2argv-graphics-sdl-fullscreen.xml,
tests/qemuxml2argvdata/qemuxml2argv-graphics-sdl.args,
tests/qemuxml2argvdata/qemuxml2argv-graphics-sdl.xml,
tests/qemuxml2argvdata/qemuxml2argv-graphics-vnc-sasl.args,
tests/qemuxml2argvdata/qemuxml2argv-graphics-vnc-sasl.xml,
tests/qemuxml2argvdata/qemuxml2argv-graphics-vnc-tls.xml,
tests/qemuxml2argvdata/qemuxml2argv-graphics-vnc.xml,
tests/qemuxml2argvdata/qemuxml2argv-input-xen.xml: Add <video>
element for testing graphics adapter
* tests/qemuxml2argvtest.c: Add QEMUD_CMD_FLAG_VGA flag
* tests/qemuxml2xmltest.c: Add missing graphics-vnc-sasl/tls tests
---
src/qemu_conf.c | 89 ++++++++++++++++++++
src/qemu_conf.h | 1 +
tests/qemuhelptest.c | 66 +++++++++++++-
.../qemuxml2argv-graphics-sdl-fullscreen.xml | 3 +
.../qemuxml2argv-graphics-sdl.args | 2 +-
.../qemuxml2argvdata/qemuxml2argv-graphics-sdl.xml | 3 +
.../qemuxml2argv-graphics-vnc-sasl.args | 2 +-
.../qemuxml2argv-graphics-vnc-sasl.xml | 3 +
.../qemuxml2argv-graphics-vnc-tls.xml | 3 +
.../qemuxml2argvdata/qemuxml2argv-graphics-vnc.xml | 3 +
tests/qemuxml2argvdata/qemuxml2argv-input-xen.xml | 3 +
tests/qemuxml2argvtest.c | 2 +-
tests/qemuxml2xmltest.c | 2 +
13 files changed, 174 insertions(+), 8 deletions(-)
diff --git a/src/qemu_conf.c b/src/qemu_conf.c
index 9ca60b9..6337045 100644
--- a/src/qemu_conf.c
+++ b/src/qemu_conf.c
@@ -78,6 +78,15 @@ VIR_ENUM_IMPL(qemuDiskCacheV2, VIR_DOMAIN_DISK_CACHE_LAST,
"writethrough",
"writeback");
+VIR_ENUM_DECL(qemuVideo)
+
+VIR_ENUM_IMPL(qemuVideo, VIR_DOMAIN_VIDEO_TYPE_LAST,
+ "std",
+ "cirrus",
+ "vmware",
+ NULL, /* no arg needed for xen */
+ NULL /* don't support vbox */);
+
int qemudLoadDriverConfig(struct qemud_driver *driver,
const char *filename) {
@@ -455,6 +464,8 @@ static unsigned int qemudComputeCmdFlags(const char *help,
if (strstr(help, "format="))
flags |= QEMUD_CMD_FLAG_DRIVE_FORMAT;
}
+ if (strstr(help, "-vga") && !strstr(help, "-std-vga"))
+ flags |= QEMUD_CMD_FLAG_VGA;
if (strstr(help, "boot=on"))
flags |= QEMUD_CMD_FLAG_DRIVE_BOOT;
if (version >= 9000)
@@ -1533,6 +1544,53 @@ int qemudBuildCommandLine(virConnectPtr conn,
ADD_ARG_LIT("-full-screen");
}
+ if (def->nvideos) {
+ if (def->nvideos > 1) {
+ qemudReportError(conn, NULL, NULL, VIR_ERR_INTERNAL_ERROR,
+ "%s", _("only one video card is currentely supported"));
+ goto error;
+ }
+
+ if (qemuCmdFlags & QEMUD_CMD_FLAG_VGA) {
+ if (def->videos[0]->type == VIR_DOMAIN_VIDEO_TYPE_XEN) {
+ /* nothing - vga has no effect on Xen pvfb */
+ } else {
+ const char *vgastr = qemuVideoTypeToString(def->videos[0]->type);
+ if (!vgastr) {
+ qemudReportError(conn, NULL, NULL, VIR_ERR_INTERNAL_ERROR,
+ _("video type %s is not supported with QEMU"),
+ virDomainVideoTypeToString(def->videos[0]->type));
+ goto error;
+ }
+
+ ADD_ARG_LIT("-vga");
+ ADD_ARG_LIT(vgastr);
+ }
+ } else {
+
+ switch (def->videos[0]->type) {
+ case VIR_DOMAIN_VIDEO_TYPE_VGA:
+ ADD_ARG_LIT("-std-vga");
+ break;
+
+ case VIR_DOMAIN_VIDEO_TYPE_VMVGA:
+ ADD_ARG_LIT("-vmwarevga");
+ break;
+
+ case VIR_DOMAIN_VIDEO_TYPE_XEN:
+ case VIR_DOMAIN_VIDEO_TYPE_CIRRUS:
+ /* No special args - this is the default */
+ break;
+
+ default:
+ qemudReportError(conn, NULL, NULL, VIR_ERR_INTERNAL_ERROR,
+ _("video type %s is not supported with QEMU"),
+ virDomainVideoTypeToString(def->videos[0]->type));
+ goto error;
+ }
+ }
+ }
+
/* Add sound hardware */
if (def->nsounds) {
int size = 100;
@@ -2428,6 +2486,7 @@ virDomainDefPtr qemuParseCommandLine(virConnectPtr conn,
char *path;
int nnics = 0;
const char **nics = NULL;
+ int video = VIR_DOMAIN_VIDEO_TYPE_CIRRUS;
if (!progargv[0]) {
qemudReportError(conn, NULL, NULL, VIR_ERR_INTERNAL_ERROR,
@@ -2805,6 +2864,18 @@ virDomainDefPtr qemuParseCommandLine(virConnectPtr conn,
def->os.bootloader = strdup(val);
if (!def->os.bootloader)
goto no_memory;
+ } else if (STREQ(arg, "-vmwarevga")) {
+ video = VIR_DOMAIN_VIDEO_TYPE_VMVGA;
+ } else if (STREQ(arg, "-std-vga")) {
+ video = VIR_DOMAIN_VIDEO_TYPE_VGA;
+ } else if (STREQ(arg, "-vga")) {
+ WANT_VALUE();
+ video = qemuVideoTypeFromString(val);
+ if (video < 0) {
+ qemudReportError(conn, NULL, NULL, VIR_ERR_INTERNAL_ERROR,
+ _("unknown video adapter type '%s'"), val);
+ goto error;
+ }
} else if (STREQ(arg, "-domid")) {
WANT_VALUE();
/* ignore, generted on the fly */
@@ -2859,6 +2930,24 @@ virDomainDefPtr qemuParseCommandLine(virConnectPtr conn,
def->graphics[def->ngraphics++] = sdl;
}
+ if (def->ngraphics) {
+ virDomainVideoDefPtr vid;
+ if (VIR_ALLOC(vid) < 0)
+ goto no_memory;
+ if (def->virtType == VIR_DOMAIN_VIRT_XEN)
+ vid->type = VIR_DOMAIN_VIDEO_TYPE_XEN;
+ else
+ vid->type = video;
+ vid->vram = virDomainVideoDefaultRAM(def, vid->type);
+ vid->heads = 1;
+
+ if (VIR_REALLOC_N(def->videos, def->nvideos+1) < 0) {
+ virDomainVideoDefFree(vid);
+ goto no_memory;
+ }
+ def->videos[def->nvideos++] = vid;
+ }
+
VIR_FREE(nics);
if (!def->name) {
diff --git a/src/qemu_conf.h b/src/qemu_conf.h
index c0ed46d..9065821 100644
--- a/src/qemu_conf.h
+++ b/src/qemu_conf.h
@@ -57,6 +57,7 @@ enum qemud_cmd_flags {
QEMUD_CMD_FLAG_DRIVE_CACHE_V2 = (1 << 12), /* Is the cache= flag wanting new v2 values */
QEMUD_CMD_FLAG_KVM = (1 << 13), /* Whether KVM is compiled in */
QEMUD_CMD_FLAG_DRIVE_FORMAT = (1 << 14), /* Is -drive format= avail */
+ QEMUD_CMD_FLAG_VGA = (1 << 15), /* Is -vga avail */
};
/* Main driver state */
diff --git a/tests/qemuhelptest.c b/tests/qemuhelptest.c
index bf8a293..73eae54 100644
--- a/tests/qemuhelptest.c
+++ b/tests/qemuhelptest.c
@@ -89,11 +89,67 @@ mymain(int argc, char **argv)
ret = -1; \
} while (0)
- DO_TEST("qemu-0.9.1", 0x002f, 9001, 0, 0);
- DO_TEST("kvm-74", 0x633e, 9001, 1, 74);
- DO_TEST("qemu-0.10.5", 0x5c6f, 10005, 0, 0);
- DO_TEST("qemu-kvm-0.10.5", 0x7d7e, 10005, 1, 0);
- DO_TEST("kvm-86", 0x7d7e, 10050, 1, 0);
+ DO_TEST("qemu-0.9.1",
+ QEMUD_CMD_FLAG_KQEMU |
+ QEMUD_CMD_FLAG_VNC_COLON |
+ QEMUD_CMD_FLAG_NO_REBOOT |
+ QEMUD_CMD_FLAG_DRIVE |
+ QEMUD_CMD_FLAG_NAME,
+ 9001, 0, 0);
+ DO_TEST("kvm-74",
+ QEMUD_CMD_FLAG_VNC_COLON |
+ QEMUD_CMD_FLAG_NO_REBOOT |
+ QEMUD_CMD_FLAG_DRIVE |
+ QEMUD_CMD_FLAG_DRIVE_BOOT |
+ QEMUD_CMD_FLAG_NAME |
+ QEMUD_CMD_FLAG_VNET_HDR |
+ QEMUD_CMD_FLAG_MIGRATE_KVM_STDIO |
+ QEMUD_CMD_FLAG_KVM |
+ QEMUD_CMD_FLAG_DRIVE_FORMAT,
+ 9001, 1, 74);
+ DO_TEST("qemu-0.10.5",
+ QEMUD_CMD_FLAG_KQEMU |
+ QEMUD_CMD_FLAG_VNC_COLON |
+ QEMUD_CMD_FLAG_NO_REBOOT |
+ QEMUD_CMD_FLAG_DRIVE |
+ QEMUD_CMD_FLAG_NAME |
+ QEMUD_CMD_FLAG_UUID |
+ QEMUD_CMD_FLAG_MIGRATE_QEMU_TCP |
+ QEMUD_CMD_FLAG_MIGRATE_QEMU_EXEC |
+ QEMUD_CMD_FLAG_DRIVE_CACHE_V2 |
+ QEMUD_CMD_FLAG_DRIVE_FORMAT |
+ QEMUD_CMD_FLAG_VGA,
+ 10005, 0, 0);
+ DO_TEST("qemu-kvm-0.10.5",
+ QEMUD_CMD_FLAG_VNC_COLON |
+ QEMUD_CMD_FLAG_NO_REBOOT |
+ QEMUD_CMD_FLAG_DRIVE |
+ QEMUD_CMD_FLAG_DRIVE_BOOT |
+ QEMUD_CMD_FLAG_NAME |
+ QEMUD_CMD_FLAG_UUID |
+ QEMUD_CMD_FLAG_VNET_HDR |
+ QEMUD_CMD_FLAG_MIGRATE_QEMU_TCP |
+ QEMUD_CMD_FLAG_MIGRATE_QEMU_EXEC |
+ QEMUD_CMD_FLAG_DRIVE_CACHE_V2 |
+ QEMUD_CMD_FLAG_KVM |
+ QEMUD_CMD_FLAG_DRIVE_FORMAT |
+ QEMUD_CMD_FLAG_VGA,
+ 10005, 1, 0);
+ DO_TEST("kvm-86",
+ QEMUD_CMD_FLAG_VNC_COLON |
+ QEMUD_CMD_FLAG_NO_REBOOT |
+ QEMUD_CMD_FLAG_DRIVE |
+ QEMUD_CMD_FLAG_DRIVE_BOOT |
+ QEMUD_CMD_FLAG_NAME |
+ QEMUD_CMD_FLAG_UUID |
+ QEMUD_CMD_FLAG_VNET_HDR |
+ QEMUD_CMD_FLAG_MIGRATE_QEMU_TCP |
+ QEMUD_CMD_FLAG_MIGRATE_QEMU_EXEC |
+ QEMUD_CMD_FLAG_DRIVE_CACHE_V2 |
+ QEMUD_CMD_FLAG_KVM |
+ QEMUD_CMD_FLAG_DRIVE_FORMAT |
+ QEMUD_CMD_FLAG_VGA,
+ 10050, 1, 0);
return ret == 0 ? EXIT_SUCCESS : EXIT_FAILURE;
}
diff --git a/tests/qemuxml2argvdata/qemuxml2argv-graphics-sdl-fullscreen.xml b/tests/qemuxml2argvdata/qemuxml2argv-graphics-sdl-fullscreen.xml
index fe1fe1a..f3fc588 100644
--- a/tests/qemuxml2argvdata/qemuxml2argv-graphics-sdl-fullscreen.xml
+++ b/tests/qemuxml2argvdata/qemuxml2argv-graphics-sdl-fullscreen.xml
@@ -20,5 +20,8 @@
</disk>
<input type='mouse' bus='ps2'/>
<graphics type='sdl' display=':0.1' xauth='/root/.Xauthority' fullscreen='yes'/>
+ <video>
+ <model type='cirrus' vram='9216' heads='1'/>
+ </video>
</devices>
</domain>
diff --git a/tests/qemuxml2argvdata/qemuxml2argv-graphics-sdl.args b/tests/qemuxml2argvdata/qemuxml2argv-graphics-sdl.args
index 3b2b049..f908252 100644
--- a/tests/qemuxml2argvdata/qemuxml2argv-graphics-sdl.args
+++ b/tests/qemuxml2argvdata/qemuxml2argv-graphics-sdl.args
@@ -1 +1 @@
-LC_ALL=C PATH=/bin HOME=/home/test USER=test LOGNAME=test XAUTHORITY=/root/.Xauthority DISPLAY=:0.1 /usr/bin/qemu -S -M pc -m 214 -smp 1 -monitor pty -no-acpi -boot c -hda /dev/HostVG/QEMUGuest1 -net none -serial none -parallel none -usb
+LC_ALL=C PATH=/bin HOME=/home/test USER=test LOGNAME=test XAUTHORITY=/root/.Xauthority DISPLAY=:0.1 /usr/bin/qemu -S -M pc -m 214 -smp 1 -monitor pty -no-acpi -boot c -hda /dev/HostVG/QEMUGuest1 -net none -serial none -parallel none -usb -std-vga
diff --git a/tests/qemuxml2argvdata/qemuxml2argv-graphics-sdl.xml b/tests/qemuxml2argvdata/qemuxml2argv-graphics-sdl.xml
index 1e04f12..431c3c9 100644
--- a/tests/qemuxml2argvdata/qemuxml2argv-graphics-sdl.xml
+++ b/tests/qemuxml2argvdata/qemuxml2argv-graphics-sdl.xml
@@ -20,5 +20,8 @@
</disk>
<input type='mouse' bus='ps2'/>
<graphics type='sdl' display=':0.1' xauth='/root/.Xauthority'/>
+ <video>
+ <model type='vga' vram='9216' heads='1'/>
+ </video>
</devices>
</domain>
diff --git a/tests/qemuxml2argvdata/qemuxml2argv-graphics-vnc-sasl.args b/tests/qemuxml2argvdata/qemuxml2argv-graphics-vnc-sasl.args
index a41a57c..bd63540 100644
--- a/tests/qemuxml2argvdata/qemuxml2argv-graphics-vnc-sasl.args
+++ b/tests/qemuxml2argvdata/qemuxml2argv-graphics-vnc-sasl.args
@@ -1 +1 @@
-LC_ALL=C PATH=/bin HOME=/home/test USER=test LOGNAME=test SASL_CONF_DIR=/root/.sasl2 /usr/bin/qemu -S -M pc -m 214 -smp 1 -monitor pty -no-acpi -boot c -hda /dev/HostVG/QEMUGuest1 -net none -serial none -parallel none -usb -vnc 127.0.0.1:3,sasl
+LC_ALL=C PATH=/bin HOME=/home/test USER=test LOGNAME=test SASL_CONF_DIR=/root/.sasl2 /usr/bin/qemu -S -M pc -m 214 -smp 1 -monitor pty -no-acpi -boot c -hda /dev/HostVG/QEMUGuest1 -net none -serial none -parallel none -usb -vnc 127.0.0.1:3,sasl -vga cirrus
diff --git a/tests/qemuxml2argvdata/qemuxml2argv-graphics-vnc-sasl.xml b/tests/qemuxml2argvdata/qemuxml2argv-graphics-vnc-sasl.xml
index cbaa1da..b6f99d3 100644
--- a/tests/qemuxml2argvdata/qemuxml2argv-graphics-vnc-sasl.xml
+++ b/tests/qemuxml2argvdata/qemuxml2argv-graphics-vnc-sasl.xml
@@ -20,5 +20,8 @@
</disk>
<input type='mouse' bus='ps2'/>
<graphics type='vnc' port='5903' autoport='no' listen='127.0.0.1'/>
+ <video>
+ <model type='cirrus' vram='9216' heads='1'/>
+ </video>
</devices>
</domain>
diff --git a/tests/qemuxml2argvdata/qemuxml2argv-graphics-vnc-tls.xml b/tests/qemuxml2argvdata/qemuxml2argv-graphics-vnc-tls.xml
index cbaa1da..b6f99d3 100644
--- a/tests/qemuxml2argvdata/qemuxml2argv-graphics-vnc-tls.xml
+++ b/tests/qemuxml2argvdata/qemuxml2argv-graphics-vnc-tls.xml
@@ -20,5 +20,8 @@
</disk>
<input type='mouse' bus='ps2'/>
<graphics type='vnc' port='5903' autoport='no' listen='127.0.0.1'/>
+ <video>
+ <model type='cirrus' vram='9216' heads='1'/>
+ </video>
</devices>
</domain>
diff --git a/tests/qemuxml2argvdata/qemuxml2argv-graphics-vnc.xml b/tests/qemuxml2argvdata/qemuxml2argv-graphics-vnc.xml
index cbaa1da..b6f99d3 100644
--- a/tests/qemuxml2argvdata/qemuxml2argv-graphics-vnc.xml
+++ b/tests/qemuxml2argvdata/qemuxml2argv-graphics-vnc.xml
@@ -20,5 +20,8 @@
</disk>
<input type='mouse' bus='ps2'/>
<graphics type='vnc' port='5903' autoport='no' listen='127.0.0.1'/>
+ <video>
+ <model type='cirrus' vram='9216' heads='1'/>
+ </video>
</devices>
</domain>
diff --git a/tests/qemuxml2argvdata/qemuxml2argv-input-xen.xml b/tests/qemuxml2argvdata/qemuxml2argv-input-xen.xml
index 1e80317..fea7f8e 100644
--- a/tests/qemuxml2argvdata/qemuxml2argv-input-xen.xml
+++ b/tests/qemuxml2argvdata/qemuxml2argv-input-xen.xml
@@ -20,5 +20,8 @@
</disk>
<input type='mouse' bus='xen'/>
<graphics type='vnc' port='5903' autoport='no' listen='127.0.0.1'/>
+ <video>
+ <model type='xen' vram='4096' heads='1'/>
+ </video>
</devices>
</domain>
diff --git a/tests/qemuxml2argvtest.c b/tests/qemuxml2argvtest.c
index 28609eb..2a93018 100644
--- a/tests/qemuxml2argvtest.c
+++ b/tests/qemuxml2argvtest.c
@@ -216,7 +216,7 @@ mymain(int argc, char **argv)
driver.vncSASL = 1;
driver.vncSASLdir = strdup("/root/.sasl2");
- DO_TEST("graphics-vnc-sasl", 0);
+ DO_TEST("graphics-vnc-sasl", QEMUD_CMD_FLAG_VGA);
driver.vncTLS = 1;
driver.vncTLSx509verify = 1;
driver.vncTLSx509certdir = strdup("/etc/pki/tls/qemu");
diff --git a/tests/qemuxml2xmltest.c b/tests/qemuxml2xmltest.c
index ab9943d..7db7611 100644
--- a/tests/qemuxml2xmltest.c
+++ b/tests/qemuxml2xmltest.c
@@ -102,6 +102,8 @@ mymain(int argc, char **argv)
DO_TEST("disk-drive-cache-v1-wb");
DO_TEST("disk-drive-cache-v1-none");
DO_TEST("graphics-vnc");
+ DO_TEST("graphics-vnc-sasl");
+ DO_TEST("graphics-vnc-tls");
DO_TEST("graphics-sdl");
DO_TEST("graphics-sdl-fullscreen");
DO_TEST("input-usbmouse");
--
1.6.2.5
--
|: Red Hat, Engineering, London -o- http://people.redhat.com/berrange/ :|
|: http://libvirt.org -o- http://virt-manager.org -o- http://ovirt.org :|
|: http://autobuild.org -o- http://search.cpan.org/~danberr/ :|
|: GnuPG: 7D3B9505 -o- F3C9 553F A1DA 4AC2 5648 23C1 B3DF F742 7D3B 9505 :|
15 years, 11 months
[libvirt] daily builds of pristine upstream sources for qemu, qemu-kvm, and libvirt
by Dustin Kirkland
Howdy, developers of qemu, qemu-kvm, and libvirt. I periodically see
bug reports on these lists from users of Ubuntu packages of these
projects.
Since these users are often running some version of the project older
than the current development branch, it's more interesting to know if
the user can reproduce the bug on the latest development sources.
I have constructed some automation that builds Debian/Ubuntu binaries
for amd64, i386, and lpia platforms directly from your master git
repositories every day at 11:00 UTC, and publishes them in a special,
opt-in repository. These daily builds also drop any specific patches
we may be carrying, in order to minimize the delta between the
binaries built and your upstream sources.
* https://launchpad.net/~ubuntu-virt/+archive/virt-daily-upstream
In the event that an Ubuntu user reports a problem, and there's an
interest in trying to reproduce the problem against the tip of the
development branch, we can point them at this resource for testing
purposes.
Additionally, this tool also has the ability to expose build
breakages. For example (let's not debug this in this thread), at the
moment, qemu's build is broken, somewhere near:
....
LINK cris-softmmu/qemu-system-cris
../libqemu_common.a(esdaudio.o): In function `qesd_run_in':
/build/buildd/qemu-0.10.50.20090707062004/audio/esdaudio.c:400:
undefined reference to `audio_pt_lock'
....
Launchpad publishes the full build logs available for each
architecture at the link above. For the above example, the specific
build log is:
* http://launchpadlibrarian.net/28761559/buildlog_ubuntu-karmic-amd64.qemu_...
If anyone has suggestions as to the utility of this resource, I would
appreciate constructive feedback.
Cheers,
--
:-Dustin
15 years, 11 months
[libvirt] [PATCH] allow to set path to xen userspace tools
by Guido Günther
Hi,
attached patch makes the path to the xen userspace tools configurable.
Debian keeps this under /usr/lib/xen-default/ instead of /usr/lib/xen/.
We don't have the amd64 libs in /usr/lib64/xen either so we can use:
./configure --with-xen-tools=/usr/lib/xen-defaults --with-xen-tools64=/usr/lib/xen-defaults
instead of patching src/xen_internals.c directly.
Skipping above options gives the current behaviour. I checked that "make
check" still passes. O.k. to apply?
Cheers,
-- Guido
15 years, 11 months
[libvirt] [PATCH] Power Hypervisor Support for libvirt - minimum set of features
by Eduardo Otubo
Hello all,
This is the initial patch for the driver for IBM Power Hypervisors. The
minimum set of features are now implemented: list, list --all and
dumpxml. Here is the Changeset since last PATCH I sent:
* The URI has changed to: phyp://user@[hmc|ivm]/managed_system. If the
system is a HMC+VIOS based, only an HMC authentication will be required.
Commands will be sent to VIOS trough HMC command line. And if the system
is an IVM based, then just provide the username and password for IVM.
* Since the Power Hypervisor has no information about UUID's, I built a
little database (uuid_db) to store and associate LPAR ID's with UUID
randomly generated by the API.
* The command dumpxml is implemented, but there are some informations
missing. Fetching informations like fstab, os type, uptime, IP addr and
so on, will only be available in a future versions of the HMC system.
* The TODO list is now set to implement life cycle functions.
Thanks in advance,
[]'s
--
Eduardo Otubo
Software Engineer
Linux Technology Center
IBM Systems & Technology Group
Mobile: +55 19 8135 0885
otubo(a)linux.vnet.ibm.com
15 years, 11 months
[libvirt] PATCH: 0/3: Run QEMU guests within a CGroup
by Daniel P. Berrange
Recent Linux kernels have a new concept of 'CGroups' which is a way to
group tasks on the system and apply policy to them as a whole. We already
use this in the LXC container driver, to control total memory usage of
things runing within a container.
This patch series is a proof of concept to make use of CGroups in the
QEMU driver. The idea is that we have a 3 level cgroup hierarchy
- Top level; contains the libvirtd daemon itself
- 2nd level: one per libvirt driver, but dos not contain any
processes.
- 3rd level: one per guest VM. Contains the QEMU process
The host admin can do control on the top level and 2nd level to set an
overall system policy. libvirt will then provide APIs / capabilities to
control individual VMs policy.
Daniel
--
|: Red Hat, Engineering, London -o- http://people.redhat.com/berrange/ :|
|: http://libvirt.org -o- http://virt-manager.org -o- http://ovirt.org :|
|: http://autobuild.org -o- http://search.cpan.org/~danberr/ :|
|: GnuPG: 7D3B9505 -o- F3C9 553F A1DA 4AC2 5648 23C1 B3DF F742 7D3B 9505 :|
15 years, 11 months
[libvirt] [PATCH 1/2] Added new filesystem glusterfs
by Harshavardhana
Added new enum for glusterfs, another netfs based filesystem.
---
src/storage_conf.c | 2 +-
src/storage_conf.h | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/storage_conf.c b/src/storage_conf.c
index 5f724dc..16ed906 100644
--- a/src/storage_conf.c
+++ b/src/storage_conf.c
@@ -68,7 +68,7 @@ VIR_ENUM_IMPL(virStoragePoolFormatFileSystem,
VIR_ENUM_IMPL(virStoragePoolFormatFileSystemNet,
VIR_STORAGE_POOL_NETFS_LAST,
- "auto", "nfs")
+ "auto", "nfs", "glusterfs")
VIR_ENUM_IMPL(virStoragePoolFormatDisk,
VIR_STORAGE_POOL_DISK_LAST,
diff --git a/src/storage_conf.h b/src/storage_conf.h
index 8a4fed2..27dc4a7 100644
--- a/src/storage_conf.h
+++ b/src/storage_conf.h
@@ -151,7 +151,6 @@ struct _virStoragePoolSourceHost {
int protocol;
};
-
/*
* Available extents on the underlying storage
*/
@@ -366,6 +365,7 @@ VIR_ENUM_DECL(virStoragePoolFormatFileSystem)
enum virStoragePoolFormatFileSystemNet {
VIR_STORAGE_POOL_NETFS_AUTO = 0,
VIR_STORAGE_POOL_NETFS_NFS,
+ VIR_STORAGE_POOL_NETFS_GLUSTERFS,
VIR_STORAGE_POOL_NETFS_LAST,
};
VIR_ENUM_DECL(virStoragePoolFormatFileSystemNet)
--
1.6.0.6
15 years, 11 months
[libvirt] Can't boot guest after adding an IDE storage
by M. Mohan Kumar
Hi,
We installed Fedora 11 guest in an emulated SCSI disk using virt-install.
After the installation the guest was shutdown and additional IDE virtual
storage was added to the guest.
When we try to boot the guest from virt-manager, it tries to boot from the
newly added IDE storage (instead of installed SCSI storage) and fails to
boot.
It seems that how the disk devices are sorted is the problem. There is a bug
opened to track this issue:
https://bugzilla.redhat.com/show_bug.cgi?id=507271
As dicussed in the bugzilla, ideally there should be a 'bootable' flag for
each storage device. Also virt-manager could another option to specify which
disk to boot from.
Regards, M. Mohan Kumar
15 years, 11 months