[libvirt] [PATCH] Update domain xml after usb hotplug

2008-08-21 Thread Cole Robinson
The recently added usb hostdev and mass storage device hotplug code doesn't append the devices to the running guests xml if the hotplug succeeds. The attached patch fixes this. Thanks, Cole commit 8df17db8b36a2c1e8efa430a0493f66825b6b80e Author: Cole (Work Acct) <[EMAIL PROTECTED]> Date: Thu Aug

[libvirt] [PATCH] Fix disk device ordering

2008-08-21 Thread Cole Robinson
When parsing the domain xml, disks are supposed to be rearranged in an alphabetic order based on bus type and target. The reordering code had a flaw though, in that it would always put the first disk it encountered at the head of the list, and had no way of putting new entries in front of it. The

[libvirt] [PATCH] Fix cd eject segfault

2008-08-21 Thread Cole Robinson
The cdrom eject code was trying to dereference the NULL source of an empty cdrom. Attached patch fixes this. Thanks, Cole commit 5925689b5b94b29a520dcfbc7f4f1cfa0a0a0183 Author: Cole Robinson <[EMAIL PROTECTED]> Date: Thu Aug 21 17:56:25 2008 -0400 Prevent cdrom eject from segfaulting when

[libvirt] [PATCH] Check disk target collision when parsing domain xml

2008-08-21 Thread Cole Robinson
The current domain xml parsing doesn't check if disks are specified with duplicate targets ("hda" etc.). The attached patch adds a check for this. Thanks, Cole commit 27df1653474738a2ce83c89e7bdb2c4f7327f9b6 Author: Cole Robinson <[EMAIL PROTECTED]> Date: Thu Aug 21 14:58:04 2008 -0400 Che

[libvirt] [PATCH] Set correct device type when parsing input devices

2008-08-21 Thread Cole Robinson
In virDomainDeviceDefParse, parsing an input device was actually setting it's type as DEVICE_DISK. The attached patch fixes this. Thanks, Cole commit 75150ac2536c427f74875fc563abf2fc06595dda Author: Cole Robinson <[EMAIL PROTECTED]> Date: Thu Aug 21 13:27:38 2008 -0400 Fix setting input de

[libvirt] [PATCH] Add success output to virsh attach/detach commands

2008-08-21 Thread Cole Robinson
The virsh attach-* and detach-* commands don't say anything if the operation succeeds, which doesn't seem very polite. The attached adds some simple feedback. Thanks, Cole commit eda28c5de3d367d001ca89ffc969fcc3c0185abb Author: Cole Robinson <[EMAIL PROTECTED]> Date: Thu Aug 21 17:59:13 2008 -0

[libvirt] anyone implementing host device enumeration?

2008-08-21 Thread David Lively
Hi - I'm about to start working on host device enumeration, along the (HAL-ish) lines of what was discussed back in April: https://www.redhat.com/archives/libvir-list/2008-April/msg5.html I know the xml details haven't been fully fleshed out, but there seems to be agreement that it will

Re: [libvirt] [PATCH] introducing (for logical storage pools)

2008-08-21 Thread Jim Meyering
David Lively <[EMAIL PROTECTED]> wrote: > Oops - that was against an old base. Sorry. Here's the new one. Good timing. I was in the process of replying, after having done the merge and add-conn-arg bit. > Also fixed a few other issues ... ACK. I compared the result of my merge/tweaks and your

RE: [libvirt] Using Xen config files

2008-08-21 Thread Matthew Donovan
I'm still having problems with this. I've dug around and found errors in the qemu-dm log. When I try to start the VM with libvirt, the error I'm getting is: "xs_read(/vm/414e73de-cf1e-487c-87e0-d4ebf7a23576/rtc/timeoffset): read error" I did a xenstore-ls on the /vm/414e73de-cf1e-487c-87e0-d4ebf

[libvirt] [PATCH] configure.in: Prepend -lpthread to LIBS if required.

2008-08-21 Thread Jim Meyering
"Jun Koi" <[EMAIL PROTECTED]> wrote: > The latest cvs version has an error when compiling: > > make[3]: Entering directory `/home/jun/projects/libvirt-0821/src' > /bin/bash ../libtool --tag=CC --mode=link gcc -g -O2 -Wall ... > ./.libs/libvirt.so: undefined reference to `pthread_sigmask' > coll

[libvirt] [PATCH] autobuild.sh: Fix minor shell-quoting bugs.

2008-08-21 Thread Jim Meyering
I noticed some minor quoting problems in ovirt's autobuild.sh, and since part of that code came from here, ... Here's a patch: >From 50c37706729b7748dbf92290c6ecf6bc3982f681 Mon Sep 17 00:00:00 2001 From: Jim Meyering <[EMAIL PROTECTED]> Date: Thu, 21 Aug 2008 17:55:19 +0200 Subject: [PATCH] autob

[libvirt] [PATCH] storage pool discovery

2008-08-21 Thread David Lively
Hi Folks - Here's my second pass at storage pool discovery. I've taken Daniel's suggestion and made it return a single XML doc containing elements rather than an array of docs (and also incorporated suggestions from Daniel V and Jim M). Note that the storage patch is closely related (witho

Re: [libvirt] [PATCH] introducing (for logical storage pools)

2008-08-21 Thread David Lively
Oops - that was against an old base. Sorry. Here's the new one. Also fixed a few other issues ... Dave On Mon, 2008-08-18 at 12:12 -0400, David Lively wrote: > Same patch, resubmitted after fixing allocation issue you pointed out. > Looking more closely, I notice it was leaking when pool/source

Re: [libvirt] Bug: Libvirt java : Connect domainDefineXML shows no effect, listDefinedDomains throws exception

2008-08-21 Thread Daniel Veillard
On Thu, Aug 21, 2008 at 02:51:44PM +0200, Thomas Fricke wrote: > Hi everybody > > in the libvirt java binding the the Connect method domainDefineXML() > seems to have no effect. > > Implementing a full lifecycle junit test for the virtual machine this > method does not have any result. > > Perh

[libvirt] PATCH: Allow specific FDs to be kept open in virExec()

2008-08-21 Thread Daniel P. Berrange
With my recent patches to virExec(), all FDs except stdin/out/err are closed before the child is exec'd to prevent accidental leaks. Of course I forgot the one key place where we need to propagate FDs... The TAP devices passed to QEMU. This patch adds a 'keepfd' parameter to virExec() which allows

[libvirt] Bug: Libvirt java : Connect domainDefineXML shows no effect, listDefinedDomains throws exception

2008-08-21 Thread Thomas Fricke
Hi everybody in the libvirt java binding the the Connect method domainDefineXML() seems to have no effect. Implementing a full lifecycle junit test for the virtual machine this method does not have any result. Perhaps related: listDefinedDomains shows empty result If at least one domain is run

Re: [libvirt] PATCH: Improve python exception messages

2008-08-21 Thread Daniel Veillard
On Thu, Aug 21, 2008 at 12:00:46PM +0100, Daniel P. Berrange wrote: > On Tue, Aug 19, 2008 at 10:31:34AM +0100, Daniel P. Berrange wrote: > > This patch makes sure we extract this real error message and use it to > > set the message associated with the exception object. This is one step > > in get

Re: [libvirt] pthread_sigmask undefined reference error

2008-08-21 Thread Jun Koi
On Thu, Aug 21, 2008 at 5:34 PM, Daniel P. Berrange <[EMAIL PROTECTED]> wrote: > On Thu, Aug 21, 2008 at 02:36:33PM +0900, Jun Koi wrote: >> Hi, >> >> The latest cvs version has an error when compiling: > >> -Wformat -Wformat-security -Wmissing-prototypes -Wnested-externs >> -Wpointer-arith -Wextra

Re: [libvirt] PATCH: Improve python exception messages

2008-08-21 Thread Daniel P. Berrange
On Tue, Aug 19, 2008 at 10:31:34AM +0100, Daniel P. Berrange wrote: > Most of the libvirt python API bindings use code snippet like this when > raising an exception: > > if ret is None:raise libvirtError('virConnectOpen() failed') > > > THis sets the message associated with the exception to

Re: [libvirt] PATCH: Ensure errors are guarenteed reported in virConnectOpen

2008-08-21 Thread Daniel P. Berrange
On Thu, Aug 21, 2008 at 10:42:51AM +0100, Daniel P. Berrange wrote: > Well, ok so let me step back a bit because there's actually several > layers to this issue... > > - The libvirtd is single threaded. This was reasonable at first, but > some of our APIs take a long time to complete, so we

Re: [libvirt] PATCH: Ensure errors are guarenteed reported in virConnectOpen

2008-08-21 Thread Daniel P. Berrange
On Thu, Aug 21, 2008 at 11:30:11AM +0200, Daniel Veillard wrote: > On Thu, Aug 21, 2008 at 09:41:12AM +0100, Daniel P. Berrange wrote: > > On Thu, Aug 21, 2008 at 08:35:25AM +0200, Daniel Veillard wrote: > > > > To make it thread-safe we'll need to add a real virGetThreadLastError() > > > > API, wh

[libvirt] PATCH: Add libvirt_lxc to specfile

2008-08-21 Thread Daniel P. Berrange
FYI, just committed this change to fix the broken build last night Daniel Index: libvirt.spec.in === RCS file: /data/cvs/libvirt/libvirt.spec.in,v retrieving revision 1.90 diff -u -p -r1.90 libvirt.spec.in --- libvirt.spec.in 20

Re: [libvirt] PATCH: Ensure errors are guarenteed reported in virConnectOpen

2008-08-21 Thread Daniel Veillard
On Thu, Aug 21, 2008 at 09:41:12AM +0100, Daniel P. Berrange wrote: > On Thu, Aug 21, 2008 at 08:35:25AM +0200, Daniel Veillard wrote: > > > To make it thread-safe we'll need to add a real virGetThreadLastError() > > > API, which is something on my todo list - with that new apps can just > > > call

Re: [libvirt] [PATCH] Don't list capabilities entries if emulators can't be accessed

2008-08-21 Thread Jim Meyering
"Daniel P. Berrange" <[EMAIL PROTECTED]> wrote: > On Wed, Aug 20, 2008 at 12:51:05PM -0400, Cole Robinson wrote: >> The patch below fixes capabilities xml generation for >> the qemu driver if the emulators aren't found in the >> hardcoded paths. Current behavior will add a >> entry for the emulato

Re: [libvirt] PATCH: Ensure errors are guarenteed reported in virConnectOpen

2008-08-21 Thread Daniel P. Berrange
On Thu, Aug 21, 2008 at 08:35:25AM +0200, Daniel Veillard wrote: > On Wed, Aug 20, 2008 at 07:24:59PM +0100, Daniel P. Berrange wrote: > > On Wed, Aug 20, 2008 at 02:22:58PM +0100, Richard W.M. Jones wrote: > > > On Tue, Aug 19, 2008 at 11:35:18AM +0100, Daniel P. Berrange wrote: > > > > The guaren

Re: [libvirt] pthread_sigmask undefined reference error

2008-08-21 Thread Daniel P. Berrange
On Thu, Aug 21, 2008 at 02:36:33PM +0900, Jun Koi wrote: > Hi, > > The latest cvs version has an error when compiling: > -Wformat -Wformat-security -Wmissing-prototypes -Wnested-externs > -Wpointer-arith -Wextra -Wshadow -Wcast-align -Wwrite-strings > -Waggregate-return -Wstrict-prototypes -Winli

Re: [libvirt] Re: qemud/.libs/libvirtd?

2008-08-21 Thread Richard W.M. Jones
On Thu, Aug 21, 2008 at 12:43:54PM +0900, Jun Koi wrote: > OK, but now running /usr/sbin/libvirtd fails (" ... failed to connect > to the hypervisor"), meanwhile qemud/libvirtd works for me. What > should I do now to run libvirtd??? It's not possible to say, given the paucity of information availa

Re: [libvirt] Libvirt Xen daemon interaction in Red Hat Enterprise with virtualization

2008-08-21 Thread Daniel P. Berrange
On Wed, Aug 20, 2008 at 03:34:38PM -0700, vaibhav chugh wrote: > Thanks a lot for the reply. I checked the setting in my config file and they > look correct as specified by the webpage. I am able to connect to the unix > socket but my login to xend is failing. Urm, there is no 'login' process with

Re: [libvirt] PATCH: Ensure errors are guarenteed reported in virConnectOpen

2008-08-21 Thread Jim Meyering
"Daniel P. Berrange" <[EMAIL PROTECTED]> wrote: > The virConnectOpen method is unfortuantely rather special. While there is > a virConnect object available, the current rule is that drivers must report > errors against the global error object, because upon failure no virConnect > object will be ret