Hi, i have a problem with network configuration in domU. My dom0 - system is SuSE 10.0, Xen-3 (suse-rpms, updated via yast) in domU i also have suse 10.0. xm create works fine, the domU is booting. now my problem is: the network card does not appear as eth0, but as ethX with X >= 1 and incrementing every xm create (ie. after first xm create the card appears as eth1, after a reboot and a second xm create the card appears as eth2 and so on) manually activating ethX in domU works as workaround: cd /etc/sysconfig/network ifconfig -a ---> getting "X" cp ifcfg-eth0 ifcfg-ethX ifup ethX or alternatively via appropriate ifconfig and route - calls How can i set up xen so that the card always appears as eth0 ? thanks and regards, Stefan Schueffler schueffler@softgarden.de _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Fallback User ohne externe Platte
2006-Jan-08 11:22 UTC
[Xen-users] Re: domU network problem
Does it work using /etc/network - files? Kind regards, Ingo _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Hi in SuSE-linux these files are located in /etc/sysconfig/network/, i think that are the files you meant?> Does it work using /etc/network - files?i do have a ifcfg-eth0 - file, and on boot the boot-message says: Setting up network interfaces: lo IP address: 127.0.0.1/8 Waiting for mandatory device: eth0 19 18 17 16 15 13 cat: /sys/class/net/eth0/ifindex: No such file or directory 12 11 10 9 8 7 6 5 4 3 2 1 0 cat: /sys/class/net/eth0/ifindex: No such file or directory eth0 interface could not be set up in the /sys/class/net - directory there currently is a /eth22 - subdirectory, on next boot it will be eth23, eth24 and so on. In the current case, manually activating eth22 with ifconfig and setting the routing and ip-adress works fine (from domU i can ping the outside and from the outside the domU), but this solves not the problem of increasing eth-numbers. the kernel command line in domU is: Kernel command line: ip=:1.2.3.4:::vm1:eth0:dhcp root=/dev/sda1 ro 3 VMID=1 there is an "eth0" in this line, but the kernel seems to ignore this. regards Stefan _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
On Sun, Jan 08, 2006 at 01:41:52PM +0100, Stefan Schueffler wrote:> in SuSE-linux these files are located in /etc/sysconfig/network/, > i think that are the files you meant? > > > Does it work using /etc/network - files? > > i do have a ifcfg-eth0 - file, and on boot the boot-message says: > > Setting up network interfaces: > lo IP address: 127.0.0.1/8 > Waiting for mandatory device: eth0 > 19 18 17 16 15 13 cat: /sys/class/net/eth0/ifindex: No such file or directory > 12 11 10 9 8 7 6 5 4 3 2 1 0 cat: /sys/class/net/eth0/ifindex: No such file > or directory > eth0 interface could not be set up > > in the /sys/class/net - directory there currently is a /eth22 - subdirectory, > on next boot it will be eth23, eth24 and so on. > > In the current case, manually activating eth22 with ifconfig and setting the > routing and ip-adress works fine (from domU i can ping the outside and from > the outside the domU), but this solves not the problem of increasing > eth-numbers.I haven''t used SuSE, but as a guess, perhaps SuSE is confused by the fact that xend assigns a different random MAC address to the virtual network card on each boot? There might scripts that check the MAC address of the card on boot, and if it hasn''t been seen before, assign it a new network interface name (eth22, eth23, etc.) If this is the case, then you should be able to fix the problem either by disabling this feature in your SuSE network configuration (I can''t provide any specific help here, unfortunately), or assigning a static MAC address in the xend configuration file. --Michael Vrable _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Not exactly. Perhaps I should explain what I want to do: I want a virtual host to run as a mail server, but it can''t have an external ip. It seems to be very difficult to find good doccumentation on how to do this. The machine is already setup with an eth1 that NATs a lan. How should I configure networking in this scenario? Thanks, Michael Fallback User ohne externe Platte wrote:>Does it work using /etc/network - files? > >Kind regards, >Ingo > >_______________________________________________ >Xen-users mailing list >Xen-users@lists.xensource.com >http://lists.xensource.com/xen-users > >_______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
I seem to have gotten it working by downgrading to xen-2. I simply bridged eth1 with the host''s vif, and now it works perfectly! It works just like any other client on the eth1 subnet. It''s disappointing that xen3.0 has made networking so much more complicated while providing very little documentation for doing anything besides default scenarios. Thanks for the help, Michael Michael Hrivnak wrote:> Not exactly. Perhaps I should explain what I want to do: > > I want a virtual host to run as a mail server, but it can''t have an > external ip. It seems to be very difficult to find good > doccumentation on how to do this. > > The machine is already setup with an eth1 that NATs a lan. How should > I configure networking in this scenario? > > Thanks, > Michael > > Fallback User ohne externe Platte wrote: > >> Does it work using /etc/network - files? >> >> Kind regards, >> Ingo >> >> _______________________________________________ >> Xen-users mailing list >> Xen-users@lists.xensource.com >> http://lists.xensource.com/xen-users >> >> > > > _______________________________________________ > Xen-users mailing list > Xen-users@lists.xensource.com > http://lists.xensource.com/xen-users_______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Hi all, thanks for your help, i got it working. The solution to the problem is that suse linux has a udev-rule to create persistent names for hotplug-devices enabled by default. using the xen-feature to set a random mac-address for the interface leads to the situation, that suse must give a new device-id on every boot, as the network card appears to be a "new" one (new unseen mac-address) and the old device-ids are locked by suse for the old mac-address. the solution is either a) to remove the udev-rule for persistent device-ids or b) to set a fixed mac-address so that suse can use the same interface-id on each boot. Some informations: on suse linux 10 (and probably 9.3 als) the udev-rules are located in /etc/udev/rules.d/ the rule to set a new device-id (eth0, eth1, ethxx...) is located in 31-net_create_names.rules old assignment (mac-address-to-device-id) are stored in 30-net_persistent_names.rules there you should delete the assignments set by suse on your first hundred reboots while trying to solve the problem :-) regards Stefan Schueffler _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Hallo Stefan Great! Now, is it at all possible to share wityh us the steps to your success? I have tried http://www.opensuse.org/Installing_Xen3 all this week end, to no avail! Maybe you''ve got the correct recipe :-) Cheers, Jimmy nui.fr Quoting Stefan Schueffler <schueffler@softgarden.de>:> Hi all, > > thanks for your help, i got it working. > > The solution to the problem is that suse linux has a > udev-rule to create persistent names for hotplug-devices enabled by > default. > > using the xen-feature to set a random mac-address for the interface leads > to the situation, that suse must give a new device-id on every boot, as > the network card appears to be a "new" one (new unseen mac-address) and > the old device-ids are locked by suse for the old mac-address. > > the solution is either > a) to remove the udev-rule for persistent device-ids or > b) to set a fixed mac-address so that suse can use the same interface-id > on each boot. > > Some informations: > on suse linux 10 (and probably 9.3 als) the udev-rules are located in > /etc/udev/rules.d/ > the rule to set a new device-id (eth0, eth1, ethxx...) is located in > 31-net_create_names.rules > old assignment (mac-address-to-device-id) are stored in > 30-net_persistent_names.rules > there you should delete the assignments set by suse on your first hundred > reboots while trying to solve the problem :-) > > regards > Stefan Schueffler > > _______________________________________________ > Xen-users mailing list > Xen-users@lists.xensource.com > http://lists.xensource.com/xen-users >_______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users