Subject: Re: install/start problem: xen 2.0 / NetBSD 2.0, 2.0.2 and 3.0 Beta
To: Rainer =?iso-8859-1?Q?Brinkm=F6ller?= <rainer.brinkmoeller@web.de>
From: Manuel Bouyer <bouyer@antioche.lip6.fr>
List: port-xen
Date: 05/19/2005 12:09:09
On Thu, May 19, 2005 at 01:07:55AM +0200, Rainer Brinkmöller wrote:
>
> Hi,
>
> [...]
> Now there is only one problem (till now): I am not sure about the
> network configuration. In the /etc/xen/nbsd in the
> line for vif i put the real mac adress of my second ethernet card and
> the local network adress 192.168.1.88 i want to use
> (i think that i shouldn't do that, but i'm not sure). My knowledge about
> bridging is nearly null so i don't know how to configure it.
Well, no that's not the correct way of doing it. You need to use a mac
address which is not already used on your network for the vif (it's
a new interface which will appear on your network). Using a aa:00:00 prefix
is probably OK as it's not used by any ethernet vendor. If you use bridging,
don't put an IP in your nbsd config file, but the bridge interface you use.
I assume you'll use the interface wm0 in domain0 for your virtual domain(s)
(remplace this with the name of the interface you have on your system).
First, create a config file for a bridge interface, and add wm0 to it:
cat > /etc/ifconfig.bridge0 << EOF
create
!brconfig $int add wm0 up
EOF
To create this without rebooting, just do:
ifconfig bridge0 create
brconfig bridge0 add wm0 up
Now you can start adding other interfaces to this bridge, such as the
xvifN.0 (remplace N with the domain number) that will be created when starting
your guest domain.
Basically you need to do
ifconfig xvifN.0 up
brconfig bridge0 add xvifN.0
The /etc/xen/scripts/network script can do this for you, but you need to
adjust the version I put in the Xen howto. Change:
ifconfig x${vif} ${bridge}
to
ifconfig x${vif} up
brconfig ${bridge} add x${vif}
Then in you nbsd file you can put:
vif = [ 'mac=AA:00:00:50:0B:F0, bridge=bridge0' ]
And the corresponding xvif interface will be added to bridge 0 when the
domain is started.
> I also don't really understand the notes in the script /etc/xen/nbsd.
> Further i create /etc/ifconfig.xennet0 within "inet 192.168.1.88
> netmask 0xffffff00" and configured /etc/hosts, /etc/mygate,
> /etc/relsolv.conf and the rc.conf nearly like in domain0
> (just used a other hostname). This seem not to work. The ping command
> don't received packets.
This is right, the problem is in the bridge setup in domain0
--
Manuel Bouyer, LIP6, Universite Paris VI. Manuel.Bouyer@lip6.fr
NetBSD: 26 ans d'experience feront toujours la difference
--