how easy to run multiple KVM guests networking with each other?

compdoc compdoc at hotrodpc.com
Tue Oct 11 21:03:50 UTC 2011


>  1) activate networking to that KVM guest, then
>
>  2) be able to run multiple KVM guests, with networking not just to
>the host, but to each other
>
>  if there's a step-by-step tutorial for this, that's great, but for
>now, i just want to know that it's doable.  i'm assuming that TUN/TAP
>networking is the obvious solution for the networking component.

KVM makes a virtual lan for you, usually with the address range something
like 192.168.200.0/24.

This virtual lan exists only within the host, so no network traffic travels
to your network switch when the guests are sending to each other. To reach
the internet, they nat through the host.

To attach virtual guests directly to your actual LAN, you create a bridge
that attaches to a physical nic. Then the guests can obtain an ip address
from your LAN's dhcp server. I like using a separate nic for this purpose.

No need for TUN/TAP. I think Xen installs TUN/TAP connections for you, but
installing KVM will not. It creates the virtual network and names it virbr0.

You can also delete the virtual network if you don't want it.








More information about the ubuntu-users mailing list