Re: [libvirt] networking with two hosts

2009-02-25 Thread Radek Hladik
Andreas Rittershofer napsal(a): Am 25.02.2009 um 00:11 schrieb David Lutterkort: On Tue, 2009-02-24 at 14:25 +0100, Andreas Rittershofer wrote: Task 1.) Each VM must have network access to each other VM and to the outside. Task 2.) When one host fails, all VMs are running on the remainig host

Re: [libvirt] [PATCH 2/5] Add virNodeDeviceAttach()/ReAttach()/Reset() APIs

2009-02-25 Thread Mark McLoughlin
On Wed, 2009-02-25 at 19:58 +, Daniel P. Berrange wrote: > > > While I can see a point in providing public APIs to attach/detach > > > drivers to devices - because we need this for Xen driver PCI > > > passthrough, I'm not sure theres a compelling need for exposing > > > a reset function, bec

Re: [libvirt] [PATCH 2/5] Add virNodeDeviceAttach()/ReAttach()/Reset() APIs

2009-02-25 Thread Mark McLoughlin
On Wed, 2009-02-25 at 19:42 +, Daniel P. Berrange wrote: > > > I think the attach/detach functions should be in the nodedev > > > driver too, because they're not really part of the HV functionality. > > > On modern Linux kernels, both Xen & KVM (and any other users) have > > > the same pci-stu

[libvirt] [PATCH 3/6] Add virsh nodedev-dettach, nodedev-reattach and nodedev-reset

2009-02-25 Thread Mark McLoughlin
Add virsh commands corresponding to each of the new methods. Signed-off-by: Mark McLoughlin --- src/virsh.c | 126 +++ 1 files changed, 126 insertions(+), 0 deletions(-) diff --git a/src/virsh.c b/src/virsh.c index 298dde0..8ae79c5 100644

[libvirt] [PATCH 1/6] Add pci utility functions

2009-02-25 Thread Mark McLoughlin
Add implementations of dettach, reattach and reset for PCI devices. Background to this code can be found here: http://marc.info/?l=kvm&m=123454366317045 Some notes: * pci-stub was first introduced in 2.6.29; if it's not available, then dettach can only unbind the device from the hos

[libvirt] [PATCH 2/6] Add virNodeDeviceAttach()/ReAttach()/Reset() APIs

2009-02-25 Thread Mark McLoughlin
Before starting a guest virNodeDeviceAttach() is intended to be called on all node devices to be assigned to a guest, followed by virNodeDeviceReset() on those devices. Once the guest has been shutdown, virNodeDeviceReset() followed by virNodeDeviceReAttach() should be called in order to make the

[libvirt] [PATCH 0/6] Add device assignment related node device methods (v2)

2009-02-25 Thread Mark McLoughlin
Hey, Okay, here's the patches again with the following changes: - Pass virConnectPtr to all pciDevice methods - Read the vendor/product ID from sysfs rather than supplying it to pciGetDevice() - Re-factor the Dettach/ReAttach() so that it can be more easily used with pciba

[libvirt] [PATCH 5/6] Add qemu dettach/reattach/reset implementation

2009-02-25 Thread Mark McLoughlin
Implement the new methods in the QEMU driver by parsing the node device XML to obtain the PCI device details and then calling the appropriate PCI utility function. Signed-off-by: Mark McLoughlin --- src/qemu_driver.c | 123 +++- 1 files changed, 1

[libvirt] [PATCH 6/6] Dettach and reset assigned PCI devices before starting QEMU

2009-02-25 Thread Mark McLoughlin
This adds a new property indicating whether or not we should automatically dettach/reset. Signed-off-by: Mark McLoughlin --- docs/schemas/domain.rng|6 +++ src/domain_conf.c | 12 +- src/domain_conf.h

[libvirt] [PATCH 4/6] Implement attach/reattach/reset in the remote driver

2009-02-25 Thread Mark McLoughlin
Nothing to see here, just a bunch of plumbing. Signed-off-by: Mark McLoughlin --- qemud/remote.c | 78 qemud/remote_dispatch_args.h |3 + qemud/remote_dispatch_prototypes.h | 21 ++ qemud/remote_dispatch_table.h

[libvirt] [PATCH] Add a trivial example program

2009-02-25 Thread David Allan
This example code illustrates connecting to the hypervisor and making some simple API calls. Added a little code to let the user specify the URI of the hypervisor on the command line, per the suggestion of Rich Jones. Changes per Jim Meyering Handle failure of virConnectNumOfDomains and virCon

[libvirt] [PATCH 0/1] Resend of example program

2009-02-25 Thread David Allan
I'm just resending this patch, as nobody objected to it after I incorporated the feedback I got, but it never got applied, either. Dave -- Libvir-list mailing list Libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list

Re: [libvirt] [PATCH] document static host IP assignment

2009-02-25 Thread Daniel Veillard
On Thu, Feb 12, 2009 at 04:59:58PM -0600, Charles Duffy wrote: > Back in August 2008, DV added support for providing static IP/hostname > assignments to dnsmasq via elements in the network definition. > > Since this functionality isn't covered in the documentation, I wrote up > a quick patch,

Re: [libvirt] [PATCH 2/5] Add virNodeDeviceAttach()/ReAttach()/Reset() APIs

2009-02-25 Thread Daniel P. Berrange
On Wed, Feb 25, 2009 at 07:16:28PM +, Mark McLoughlin wrote: > On Wed, 2009-02-25 at 17:51 +, Daniel P. Berrange wrote: > > On Tue, Feb 24, 2009 at 10:21:48PM +, Mark McLoughlin wrote: > > > Before starting a guest virNodeDeviceAttach() is intended > > > to be called on all node devices

Re: [libvirt] [PATCH 2/5] Add virNodeDeviceAttach()/ReAttach()/Reset() APIs

2009-02-25 Thread Daniel P. Berrange
On Wed, Feb 25, 2009 at 07:16:28PM +, Mark McLoughlin wrote: > On Wed, 2009-02-25 at 17:51 +, Daniel P. Berrange wrote: > > On Tue, Feb 24, 2009 at 10:21:48PM +, Mark McLoughlin wrote: > > > Before starting a guest virNodeDeviceAttach() is intended > > > to be called on all node devices

Re: [libvirt] [PATCH 2/5] Add virNodeDeviceAttach()/ReAttach()/Reset() APIs

2009-02-25 Thread Mark McLoughlin
On Wed, 2009-02-25 at 17:51 +, Daniel P. Berrange wrote: > On Tue, Feb 24, 2009 at 10:21:48PM +, Mark McLoughlin wrote: > > Before starting a guest virNodeDeviceAttach() is intended > > to be called on all node devices to be assigned to a guest, > > followed by virNodeDeviceReset() on those

Re: [libvirt] [PATCH 1/5] Add pci utility functions

2009-02-25 Thread Mark McLoughlin
On Wed, 2009-02-25 at 15:54 +, Daniel P. Berrange wrote: > On Tue, Feb 24, 2009 at 10:21:47PM +, Mark McLoughlin wrote: > > Add implementations of dettach, reattach and reset for > > PCI devices. > > > > Background to this code can be found here: > > > > http://marc.info/?l=kvm&m=123454

Re: [libvirt] [PATCH 2/2] Implement node device assignment in QEMU driver

2009-02-25 Thread Mark McLoughlin
On Wed, 2009-02-25 at 15:14 +, Daniel P. Berrange wrote: > I don't think we should be calling back out to the public API from > internal impl here. If the XML just uses the PCI address directly > then we can easily call the internal pciDettach() and pciReAttach() > APIs directly, and avoid th

Re: [libvirt] [PATCH 0/2] Dettach and reset devices before assigning to guests

2009-02-25 Thread Mark McLoughlin
On Wed, 2009-02-25 at 15:10 +, Daniel P. Berrange wrote: > I don't like this idea really. The reason we use the PCI address in the > XML is because that is a guarenteed stable identifier. The names given > to nodedevices are currently under such a guarentee. So if we used the > nodedev naming

Re: [libvirt] [PATCH 2/5] Add virNodeDeviceAttach()/ReAttach()/Reset() APIs

2009-02-25 Thread Daniel P. Berrange
On Tue, Feb 24, 2009 at 10:21:48PM +, Mark McLoughlin wrote: > Before starting a guest virNodeDeviceAttach() is intended > to be called on all node devices to be assigned to a guest, > followed by virNodeDeviceReset() on those devices. > > Once the guest has been shutdown, virNodeDeviceReset()

Re: [libvirt] networking with two hosts

2009-02-25 Thread Andreas Rittershofer
Am 25.02.2009 um 00:11 schrieb David Lutterkort: On Tue, 2009-02-24 at 14:25 +0100, Andreas Rittershofer wrote: Task 1.) Each VM must have network access to each other VM and to the outside. Task 2.) When one host fails, all VMs are running on the remainig host and 1.) must still be fulfill

Re: [libvirt] [PATCH 1/5] Add pci utility functions

2009-02-25 Thread Daniel P. Berrange
On Tue, Feb 24, 2009 at 10:21:47PM +, Mark McLoughlin wrote: > Add implementations of dettach, reattach and reset for > PCI devices. > > Background to this code can be found here: > > http://marc.info/?l=kvm&m=123454366317045 > > Some notes: > > * pci-stub was first introduced in 2.6.29

Re: [libvirt] Multpile network interfaces have same MAC address

2009-02-25 Thread David Mueller
On Wed, Feb 25, 2009 at 3:21 AM, Daniel P. Berrange wrote: > Last time I saw this was with QEMU and the rtl8139 nic, where there was > a bug setting up the MMIO space, so all NICs were reading their mac > from the first NIC's region instead of their own. I think I understand this, but I'm not sur

Re: [libvirt] [PATCH 2/2] Implement node device assignment in QEMU driver

2009-02-25 Thread Daniel P. Berrange
On Tue, Feb 24, 2009 at 10:35:39PM +, Mark McLoughlin wrote: > Handle a hostdev source specified as a node device name > by looking up the node device, parsing its XML for > PCI/USB address details, using those as the hostdev > source and, finally, dettaching and resetting the > device. I don'

Re: [libvirt] [PATCH 0/2] Dettach and reset devices before assigning to guests

2009-02-25 Thread Daniel P. Berrange
On Tue, Feb 24, 2009 at 10:35:37PM +, Mark McLoughlin wrote: > Hi, > The following two patches build on the previous series. > > The idea is simple - when starting a guest, we should > automatically dettach and reset any devices assigned to it. > > Rather than change t

Re: [libvirt] "type 'hvm' & arch 'i686' combination is not supported" error

2009-02-25 Thread Frederik Himpe
On Wed, Feb 25, 2009 at 02:17:29PM +0100, Frederik Himpe wrote: > On Wed, Feb 25, 2009 at 12:39:30PM +, Daniel P. Berrange wrote: > > > > > > > > > > > > > > > x86_64 > > > > > > > > > > > > > > > hvm > > > > > > 64 > > > /usr/bin/qemu-system-x86

[libvirt] [PATCH]: Fix non-live migration failure case

2009-02-25 Thread Chris Lalancette
All, There was a logic error in the Qemu driver when doing a non-live migrate. During a non-live migrate, on the source host during the Perform step, we pause the domain; however, if there was ever a failure, we were forgetting to unpause the domain, meaning that the domain was paused forever. Add

[libvirt] internal error Timed out while reading console log output

2009-02-25 Thread jmandawg
Hi, I just compiled installed Libvirt from the latest git repo, and for some reason when I try to start a VM from virsh I get the following error: virsh # start XPTest error: Failed to start domain XPTest error: internal error unable to start guest: and the corresponding output from l

Re: [libvirt] "type 'hvm' & arch 'i686' combination is not supported" error

2009-02-25 Thread Frederik Himpe
On Wed, Feb 25, 2009 at 12:39:30PM +, Daniel P. Berrange wrote: > > > > > > > > > > x86_64 > > > > > > > > > > hvm > > > > 64 > > /usr/bin/qemu-system-x86_64 > > pc > > isapc > > > > /usr/bin/qemu-kvm > > > >

Re: [libvirt] "type 'hvm' & arch 'i686' combination is not supported" error

2009-02-25 Thread Daniel P. Berrange
On Wed, Feb 25, 2009 at 01:34:11PM +0100, Frederik Himpe wrote: > On Wed, Feb 25, 2009 at 12:11:37PM +, Daniel P. Berrange wrote: > > On Mon, Feb 23, 2009 at 02:13:34PM +, Frederik Himpe wrote: > > > I recently updated for libvirt 0.4.6 to libvirt 0.6.0. Now several of the > > > virtual ma

Re: [libvirt] "type 'hvm' & arch 'i686' combination is not supported" error

2009-02-25 Thread Frederik Himpe
On Wed, Feb 25, 2009 at 12:11:37PM +, Daniel P. Berrange wrote: > On Mon, Feb 23, 2009 at 02:13:34PM +, Frederik Himpe wrote: > > I recently updated for libvirt 0.4.6 to libvirt 0.6.0. Now several of the > > virtual machines I defined, are not shown in virt-manager nor by virsh > > list -

Re: [libvirt] "type 'hvm' & arch 'i686' combination is not supported" error

2009-02-25 Thread Daniel P. Berrange
On Mon, Feb 23, 2009 at 02:13:34PM +, Frederik Himpe wrote: > I recently updated for libvirt 0.4.6 to libvirt 0.6.0. Now several of the > virtual machines I defined, are not shown in virt-manager nor by virsh > list --all, although the config files are still in /etc/libvirt/qemu. I > tried t

Re: [libvirt] Multpile network interfaces have same MAC address

2009-02-25 Thread Daniel P. Berrange
On Tue, Feb 24, 2009 at 01:29:41PM -0800, David Mueller wrote: > I remember seeing this problem before, but I can't remember what the > resolution was, nor can I find a discussion of the issue in > the list archives or Bugzilla. > > I've had my setup working for a while now, on both Fedora 8 and