[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-users] How to assign fixed ip-addres to vifN.0?



Hello,
I'm trying for days to get the netwerk up in domU.
Dom0 is linux-2.6.16.28-xen (xen-sources from Gentoo).
DomU is the previous version (2.6.16.26-r1).

In dom0: brctl show:
bridge name     bridge id               STP enabled     interfaces
xenbr0          8000.feffffffffff       no              vif0.0
                                                        peth0
Dom0 got his ip-adress (10.0.0.2) on eth0 via dhcp from another
machine.

DomU config:
kernel = "/boot/vmlinuz-2.6.16.26-r1-xenU"
memory = 64
name = "Cardhu"
vif = [ 'mac=00:16:3e:00:00:03, ip=10.0.0.3' ]
dhcp = "off"
netmask = "255.255.255.0"
gateway = "10.0.0.2"
hostname = "CARDHU"
disk = [ 'phy:hda5,hda5,w' ]
root = "/dev/hda5 ro"

Under gentoo, dom0 is looking for network startup scripts
in /etc/init.d/net.<interface name> so I made links for
net.vif1.0, net.vif2.0 and so on.
Then, if there is no configuration for vifN.0, gentoo assumes
DHCP and I do not want DHCP (the broadcasts seem to disapear).
Therefore. I included
config_vif1.0=( "10.0.0.51/24" )
config_vif2.0=( "10.0.0.52/24" )
and so on, in /etc/conf.d/net. (I don't want those addresses
but it is just to prevent dom0 from running DCHP to bring up
vifN.0).

Nevertheless, DHCP is still used to bring vifN.0 up but never
succeeds. From /var/log/messages:

Sep 15 16:06:50 OBAN logger: /etc/xen/scripts/vif-bridge: online
XENBUS_PATH=backend/vif/5/0
Sep 15 16:06:51 OBAN device vif5.0 entered promiscuous mode
Sep 15 16:06:51 OBAN xenbr0: port 3(vif5.0) entering learning state
Sep 15 16:06:51 OBAN xenbr0: topology change detected, propagating
Sep 15 16:06:51 OBAN xenbr0: port 3(vif5.0) entering forwarding state
Sep 15 16:06:51 OBAN logger: /etc/xen/scripts/vif-bridge: Successful
vif-bridge online for vif5.0, bridge xenbr0.
Sep 15 16:06:51 OBAN logger: /etc/xen/scripts/vif-bridge: Writing
backend/vif/5/0/hotplug-status connected to xenstore.
Sep 15 16:06:51 OBAN logger: /etc/xen/scripts/block: add
XENBUS_PATH=backend/vbd/5/773
Sep 15 16:06:53 OBAN logger: /etc/xen/scripts/block: Writing
backend/vbd/5/773/physical-device 3:5 to xenstore.
Sep 15 16:06:53 OBAN logger: /etc/xen/scripts/block: Writing
backend/vbd/5/773/hotplug-status connected to xenstore.
Sep 15 16:06:55 OBAN rc-scripts: Configuration not set for vif5.0 -
assuming DHCP
Sep 15 16:07:00 OBAN dhclient: DHCPDISCOVER on vif5.0 to 255.255.255.255
port 67 interval 2
Sep 15 16:07:02 OBAN dhclient: DHCPDISCOVER on vif5.0 to 255.255.255.255
port 67 interval 5
Sep 15 16:07:07 OBAN dhclient: DHCPDISCOVER on vif5.0 to 255.255.255.255
port 67 interval 5

So, I have never seen a domU with a network interface other than lo :-)
Why the #%#@&^* is xend not take the vif [ 'ip=.... ] stuff from the
config file for domU? Can somebody please help me?
Other things I tried but did not bring me any closer then this to domU
networking:
 - The route scripts instead of the bridge-scripts.
 - Explicitly running dhcpd in dom0 on peth0 (doesn't
   work because there is no ip-address)

Thanks for reading this far,
Hans.

_______________________________________________
Xen-users mailing list
Xen-users@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-users


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.