Re: [libvirt] using virsh remotely

2009-02-27 Thread Andreas Rittershofer


Am 27.02.2009 um 15:40 schrieb Daniel P. Berrange:


On Fri, Feb 27, 2009 at 03:36:15PM +0100, Andreas Rittershofer wrote:

I can use virsh as a command line tool, for exampe

virsh list

gives me the list of the running machines and I am back to the  
prompt.


When I make

virsh -c qemu+ssh://maschine-2/system list

I get the list of the running machine on the remote machine-2 - but
that's it, I am not back to the prompt automatically.


What version of libvirt have you got ?  There is a bug in 0.6.0 which
causes it to hang when disconnecting from the remote server

http://www.redhat.com/archives/libvir-list/2009-February/msg00104.html



I'm using Debian testing and therein is 0.5.1-6.

mfg ar
--
Hier könnte keine Signatur stehen.


--
Libvir-list mailing list
Libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list


[libvirt] using virsh remotely

2009-02-27 Thread Andreas Rittershofer

I can use virsh as a command line tool, for exampe

virsh list

gives me the list of the running machines and I am back to the prompt.

When I make

virsh -c qemu+ssh://maschine-2/system list

I get the list of the running machine on the remote machine-2 - but  
that's it, I am not back to the prompt automatically.


I want virsh to behave used remotely as used locally - execute the  
command and go back to the prompt.

How this can be done?

mfg ar
--
Hier könnte keine Signatur stehen.


--
Libvir-list mailing list
Libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list


Re: [libvirt] networking with two hosts

2009-02-26 Thread Andreas Rittershofer


Am 26.02.2009 um 20:26 schrieb Radek Hladik:


Andreas Rittershofer napsal(a):

My problem is:
1.) VM1 running on host A must have network access to VM3 when VM3  
is running on host B by default _and_

2.) when VM3 is running on host A because host B failed.
In some of my configurations 1.) worked but 2.) not, in some other  
configurations 2.) worked but 1.) not.

I must have missed some detail ...


I do not see the problem. With the bridged scenario every VM has  
direct access to the physical network and it is not important on  
which host it runs. If the VMs are running on the same host, their  
ethernet frames will just "turn around" in the bridge interface and  
if they are running on different hosts they will go thru the real  
ethernet.


State 1)
A: VM1
B: VM3

Eth. frames will go like this: VM1->BrA->PhysCardA->Ethernet- 
>PhysCardB->BrB->VM3

State 2)

A: VM1+VM3
B: x

Eth. frames will go like this:
VM1->BrA->VM3



NOW I've got it!
The errors in my configuration were two different network  
configurations on host A and on host B - I always thought that the  
network on host A and the network on host B must have different IP  
addresses. Now there is only on network configuration for host A _and_  
host B and everything is fine!


Thank you very much for your help!

mfg ar

--
Hier könnte keine Signatur stehen.


--
Libvir-list mailing list
Libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list


Re: [libvirt] networking with two hosts

2009-02-26 Thread Andreas Rittershofer


Am 25.02.2009 um 23:28 schrieb 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

and 1.) must still be fulfilled.

Does somebody has any hints about realising this scenario with  
libvirt

and KVM?




Thank you for your answer.



Basically the idea is like this. You have your hosts on one ethernet  
segment. You create bridge on each hosts and put hosts physical  
adapter into it (lets call the bridges BrA and BrB). The bridge  
behaves like a virtual ethernet switch. You should configure IP on  
the bridge not on the physical interface itself. And now if you add  
any other adapter into the bridge, it will act as if it is directly  
on the ethernet. This has been used for bridging two or more  
ethernet segments into one for a long time.


This was not the problem and runs fine.



If you setup your VMs correctly (see the wiki page for details),  
libivirt will create hosts virtual adapter and add it to the bridge.  
For example for VM1 running on A it will create i.e. vnet1 and add  
it to the bridge BrA. The virtualized interface in the VM1 will have  
direct access to the ethernet segment. It can have IP address from  
the same range as the hosts, etc...


This was not the problem too and runs fine too.

My problem is:
1.) VM1 running on host A must have network access to VM3 when VM3 is  
running on host B by default _and_

2.) when VM3 is running on host A because host B failed.

In some of my configurations 1.) worked but 2.) not, in some other  
configurations 2.) worked but 1.) not.


I must have missed some detail ...

mfg ar



--
Hier könnte keine Signatur stehen.


--
Libvir-list mailing list
Libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list


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 fulfilled.

Does somebody has any hints about realising this scenario with  
libvirt

and KVM?


What you want is a 'shared network interface'[1]

David

[1]
http://wiki.libvirt.org/page/Networking#Bridged_networking_.28aka_.22shared_physical_device.22.29




Thank you for this answer - but it is too short.

I'm working since two days on this problem but I cannot solve it until  
now.


Some configurations are working when the VMs are on different nodes  
but are failing when all machines are running on one node and vice  
versa.


Can you please go in more details?

mfg ar

--
Hier könnte keine Signatur stehen.


--
Libvir-list mailing list
Libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list


[libvirt] networking with two hosts

2009-02-24 Thread Andreas Rittershofer

The following situation is given:

Host A with VM1 and VM2 running.
Host B with VM3 und VM4 running.

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 fulfilled.


Does somebody has any hints about realising this scenario with libvirt  
and KVM?


mfg ar
--
Hier könnte keine Signatur stehen.


--
Libvir-list mailing list
Libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list


[libvirt] networking with VMs on two nodes

2009-02-23 Thread Andreas Rittershofer
I have two nodes and on each several virtual machines  running under  
KVM/qemu. I've set up the default-network on each node and so I can:


1.) ping from host do guest
2.) ping from guest to host
3.) ping from guest tu guest


But all this is only possibe on each node by itself.

What I need now is network connection between a VM on node 1 to  
another VM on node 2. How to setup this?


When both nodes are fine every node runs a few guests. But when one  
node goes down, all guests have to be run on the remaining node.


mfg ar
--
Hier könnte keine Signatur stehen.


--
Libvir-list mailing list
Libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list


Re: [libvirt] Networking with libvirt

2009-02-22 Thread Andreas Rittershofer


Am 22.02.2009 um 21:11 schrieb Andreas Rittershofer:

2.) It runs only one or two minutes and than dies. I have to reboot  
the virtual machine to get it up and running again - and I don't no  
why either.



The network connection is very unstable: When there is no traffic ping  
runs and runs and there are no problems.


When there is traffic, i.e. when I try an aptitude update/upgrade, the  
connection breaks down and I have to reboot the VM. What could this be?


mfg ar

--
Hier könnte keine Signatur stehen.


--
Libvir-list mailing list
Libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list


Re: [libvirt] Networking with libvirt

2009-02-22 Thread Andreas Rittershofer


Am 22.02.2009 um 17:25 schrieb Andreas Rittershofer:

I want to setup networking under KVM and with libvirt. I read a lot  
the last two days, but it is not working as desired. I don't want  
bridging, I want it with a tap-device created via vde_switch. I  
cannot figure out what to put in /etc/libvirt/qemu/machine.xml and / 
etc/libvirt/qemu/networks/network.xml - there is no really good  
documentation. /var/log/libvirt/qemu/maschine.log shows a lot of  
parameters when I start the VM with virsh start machine, but I  
cannot figure out where to set these values or where to set the  
defaults.



Now the network is  running - but:

1.) I don't know why.
2.) It runs only one or two minutes and than dies. I have to reboot  
the virtual machine to get it up and running again - and I don't no  
why either.


mfg ar
--
Hier könnte keine Signatur stehen.


--
Libvir-list mailing list
Libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list


[libvirt] Networking with libvirt

2009-02-22 Thread Andreas Rittershofer
I want to setup networking under KVM and with libvirt. I read a lot  
the last two days, but it is not working as desired. I don't want  
bridging, I want it with a tap-device created via vde_switch. I cannot  
figure out what to put in /etc/libvirt/qemu/machine.xml and /etc/ 
libvirt/qemu/networks/network.xml - there is no really good  
documentation. /var/log/libvirt/qemu/maschine.log shows a lot of  
parameters when I start the VM with virsh start machine, but I cannot  
figure out where to set these values or where to set the defaults.


mfg ar
--
Hier könnte keine Signatur stehen.


--
Libvir-list mailing list
Libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list