I am having difficulty getting networking to work under User Mode Linux. I have a SuSE 8.2 Pro system and a SuSE 9.0 Pro system. Under SuSE 8.2, I downloaded the 2.4.20 kernel from krexel (www.suse.com/~krexel/uml) and installed the uml-utilities package that comes with the distro. Note: I did not recompile my SuSE 8.2 kernel. I am running with the stock kernel patched for VMware. Under SuSE 9.0 I tried to use /usr/bin/linux, but that goes into some kind of continous SEGV loop (I straced it) and sucks up about 40-70% of CPU. I then use the same 2.4.20 kernel from krexel. The krexel pre-compiled kernel seemed to be a step in the right direction. On both systems using the krexel 2.4.20 kernel I can boot up a system, but I cannot get networking to work. tuntap, slip, tap... nothing. Also, umlbuilder just doesn't work. Without networking the servers are pretty useless as I cannot install anything else with YaST. Can someone explain how they got networking to work? -- David Nettles email: tetsuoni3000@yahoo.co.jp web: http://www.miteyo.org
On Sun, Nov 09, 2003 at 11:47:37PM -0500, David Nettles wrote:
I am having difficulty getting networking to work under User Mode Linux.
Can someone explain how they got networking to work?
Here is what works for me. Create a uml0 configuration file /etc/sysconfig/network/ifcfg-uml0: BOOTPROTO="static" BROADCAST="172.21.255.255" IPADDR="172.21.3.119" NETMASK="255.255.0.0" NETWORK="172.21.0.0" STARTMODE="manual" Of course, put IP address, netmask, etc of your choice there, this is just an example. The IP address is for the host side of the tunnel. Make sure you have a route to your uml machine in /etc/sysconfig/network/routes: 172.21.1.190 0.0.0.0 255.255.255.255 uml0 (172.21.1.190 is the uml(guest) side of the tunnel) Load tun.o kernel module: modprobe tun Configure a tunnel device to be used by your user ID: /usr/bin/tunctl -t uml0 -u <your UID> Bring up the tunnel device: /sbin/ifup uml0 Allow proxy arp on the tunnel device: /sbin/sysctl -w net.ipv4.conf.uml0.proxy_arp=1 /sbin/arp -Ds 172.21.1.190 eth0 pub (use your own uml IP address here) I assume forwarding is enabled, if not, run: echo 1 > /proc/sys/net/ipv4/ip_forward All preceding commands have to be run as root. Now as your regular user start uml_switch: /usr/bin/uml/switch -tap uml0 At this point everything should be ready to start your uml. linux ubd0=root.img ubd1=swap.img umid=<some name for your machine> con=pty con0=fd:0,fd:1 eth0=daemon This is a manual way of doing things. I also developed an rc-style script (/etc/init.d/uml) which uses a configuration file /etc/sysconfig/uml to make sysadmin life easier. If there is interest to this script, I can post it to the list. Regards, -Kastus
Kastus wrote:
On Sun, Nov 09, 2003 at 11:47:37PM -0500, David Nettles wrote:
I am having difficulty getting networking to work under User Mode Linux.
Can someone explain how they got networking to work?
Here is what works for me.
Create a uml0 configuration file /etc/sysconfig/network/ifcfg-uml0:
BOOTPROTO="static" BROADCAST="172.21.255.255" IPADDR="172.21.3.119" NETMASK="255.255.0.0" NETWORK="172.21.0.0" STARTMODE="manual"
Of course, put IP address, netmask, etc of your choice there, this is just an example. The IP address is for the host side of the tunnel.
Make sure you have a route to your uml machine in /etc/sysconfig/network/routes:
172.21.1.190 0.0.0.0 255.255.255.255 uml0
(172.21.1.190 is the uml(guest) side of the tunnel)
Load tun.o kernel module:
modprobe tun
Configure a tunnel device to be used by your user ID:
/usr/bin/tunctl -t uml0 -u <your UID>
Bring up the tunnel device:
/sbin/ifup uml0
Allow proxy arp on the tunnel device:
/sbin/sysctl -w net.ipv4.conf.uml0.proxy_arp=1 /sbin/arp -Ds 172.21.1.190 eth0 pub
(use your own uml IP address here)
I assume forwarding is enabled, if not, run:
echo 1 > /proc/sys/net/ipv4/ip_forward
All preceding commands have to be run as root.
Now as your regular user start uml_switch:
/usr/bin/uml/switch -tap uml0
At this point everything should be ready to start your uml.
linux ubd0=root.img ubd1=swap.img umid=<some name for your machine> con=pty con0=fd:0,fd:1 eth0=daemon
This is a manual way of doing things. I also developed an rc-style script (/etc/init.d/uml) which uses a configuration file /etc/sysconfig/uml to make sysadmin life easier.
If there is interest to this script, I can post it to the list.
Regards, -Kastus
Thanks, I'll give this a try and let report the results. -- David Nettles email: tetsuoni3000@yahoo.co.jp web: http://www.miteyo.org
Kastus wrote:
This is a manual way of doing things. I also developed an rc-style script (/etc/init.d/uml) which uses a configuration file /etc/sysconfig/uml to make sysadmin life easier.
If there is interest to this script, I can post it to the list.
Regards, -Kastus
Yes, please post this! :)
David Nettles wrote:
I am having difficulty getting networking to work under User Mode Linux.
I have a SuSE 8.2 Pro system and a SuSE 9.0 Pro system.
Under SuSE 8.2, I downloaded the 2.4.20 kernel from krexel (www.suse.com/~krexel/uml) and installed the uml-utilities package that comes with the distro. Note: I did not recompile my SuSE 8.2 kernel. I am running with the stock kernel patched for VMware.
Under SuSE 9.0 I tried to use /usr/bin/linux, but that goes into some kind of continous SEGV loop (I straced it) and sucks up about 40-70% of CPU.
I then use the same 2.4.20 kernel from krexel. The krexel pre-compiled kernel seemed to be a step in the right direction.
On both systems using the krexel 2.4.20 kernel I can boot up a system, but I cannot get networking to work. tuntap, slip, tap... nothing. Also, umlbuilder just doesn't work. Without networking the servers are pretty useless as I cannot install anything else with YaST.
Can someone explain how they got networking to work?
-- David Nettles email: tetsuoni3000@yahoo.co.jp web: http://www.miteyo.org
Oops... sorry, I mistyped the URL. It should have been: http://www.suse.com/~kraxel/uml/ -- David Nettles email: tetsuoni3000@yahoo.co.jp web: http://www.miteyo.org
participants (2)
-
David Nettles
-
Kastus