Can't get networking working...

Discussions related to using VirtualBox on Linux hosts.
Post Reply
DeanoUk
Posts: 14
Joined: 4. May 2008, 13:28

Can't get networking working...

Post by DeanoUk »

Hi all.

I'm using SuSE Enterprise 10 (SP1), and trying to get networking working on a Windows XP (SP2) client. I'm using the latest Virtualbox 1.6.0.

I'd much prefer to use the Host Interface methodolgy as opposed to NAT and this is what I'm trying to do...

I've tried following the manual, but no luck. Here are the steps I've performed thus far:

1) Installed the bridging utils:

Code: Select all

sudo /sbin/yast -i bridge-utils
2) Added a filed /etc/sysconfig/network/ifcfg-br0 with the following:

Code: Select all

BOOTPROTO=’static’
IPADDR='10.0.0.220'
NETMASK=’255.255.255.0’
STARTMODE=’auto’
USERCONTROL=’no’
DHCLIENT_TIMEOUT=30
BRIDGE=’yes’
BRIDGE_PORTS=’eth0’
(You'll notice I've changed it from dhcp in the manual, as there is no dhcp server).

3) Changed the eth0 config to a static IP of 0.0.0.0.

4) Activiated the bridge:

Code: Select all

sudo /sbin/ifdown eth0
sudo /sbin/ifup br0
5) Added a vbox0 host:

Code: Select all

sudo VBoxAddIF vbox0 root br0
6) Changed my Windows client to use vbox0

7) Set my Windows client to an IP of 10.0.0.220

This doesn't work. Connection is seen in Windows but no net access (there doesn't seem to be any rx packets). There is net access on the client.


I looked at the ifconfig at vbox0 only had an ipv6 address, so I tried adding the ipv4 address I expected it to use:

Code: Select all

ifconfig vbox0 10.0.0.220
Still no luck.
I also can now not VNC remotely into the machine, and have to go through another machine on the same network - but this can be resolved later.

What am I doing wrong? Thanks in advance.
hkottmann
Posts: 1
Joined: 4. May 2008, 13:41

Post by hkottmann »

Hi all,

Host interface networking is not working properly with Virtualbox 1.6.0. I have the same problem on a openSuSE 10.3 host, other users have also reported the same problem on a Ubuntu host here:

http://forums.virtualbox.org/viewtopic.php?t=6092
DeanoUk
Posts: 14
Joined: 4. May 2008, 13:28

Post by DeanoUk »

Even if this is broken, I can't get web access on the host machine now - why is this?
Sasquatch
Volunteer
Posts: 17798
Joined: 17. Mar 2008, 13:41
Primary OS: Debian other
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: Windows XP, Windows 7, Linux
Location: /dev/random

Post by Sasquatch »

Do you use the PCNet emulation? If so, switch to the Intel/Pro1000 NIC emulation. That will work.

As for Host Interface, am I the only one for which it works just fine? I use Xubuntu 8.04 and am having no problems with networking. I have internet through NAT, and local network through HI.
Read the Forum Posting Guide before opening a topic.
VirtualBox FAQ: Check this before asking questions.
Online User Manual: A must read if you want to know what we're talking about.
Howto: Install Linux Guest Additions
Howto: Use Shared Folders on Linux Guest
See the Tutorials and FAQ section at the top of the Forum for more guides.
Try searching the forums first with Google and add the site filter for this forum.
E.g. install guest additions site:forums.virtualbox.org

Retired from this Forum since OSSO introduction.
DeanoUk
Posts: 14
Joined: 4. May 2008, 13:28

Post by DeanoUk »

I have but no luck. Considering I now don't have net access on the host, I'll probably need to get that working first...! Any ideas why it's now not accessible?
hege
Posts: 46
Joined: 3. Oct 2007, 09:16
Location: Finland

Post by hege »

DeanoUk
Posts: 14
Joined: 4. May 2008, 13:28

Post by DeanoUk »

Cheers hege.

Wish you guys used JIRA or something similar so we could watch for replies to bug tracking!
camh
Posts: 7
Joined: 17. Oct 2007, 11:09

Re: Can't get networking working...

Post by camh »

DeanoUk wrote: 2) Added a filed /etc/sysconfig/network/ifcfg-br0 with the following:

Code: Select all

BOOTPROTO=’static’
IPADDR='10.0.0.220'
NETMASK=’255.255.255.0’
STARTMODE=’auto’
USERCONTROL=’no’
DHCLIENT_TIMEOUT=30
BRIDGE=’yes’
BRIDGE_PORTS=’eth0’
(You'll notice I've changed it from dhcp in the manual, as there is no dhcp server).

7) Set my Windows client to an IP of 10.0.0.220

This doesn't work. Connection is seen in Windows but no net access (there doesn't seem to be any rx packets). There is net access on the client.
Both your host and your guest have the IP addres 10.0.0.220. The IP address you put on the bridge is the IP address of the host. It should be different to what you set the guest IP address to.

You do not need to set the IP address of the vbox0 interface (or any interface that is a member of the bridge).

The way you have it set up now is that when the response packets arrive, they will be consumed by the host network stack and will not make it to the guest.
frank
Oracle Corporation
Posts: 3362
Joined: 7. Jun 2007, 09:11
Primary OS: Debian Sid
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: Linux, Windows
Location: Dresden, Germany
Contact:

Post by frank »

DeanoUk, you choose the user 'root' when doing VBoxAddIF but you have to use the user which is starting VBox there. Please never start VBox as root.

We are currently trying to reproduce these problems but still had no luck.
hughesjr
Posts: 6
Joined: 5. May 2008, 14:52

Post by hughesjr »

This thread mentions a problem with upgrading from 1.5.6 to 1.6.0 and AMD NIC problems,

I was able to get the Intel NIC working with a WinXP client on a CentOS host. The info is detailed here:

http://forums.virtualbox.org/viewtopic. ... 2164#22164
frank
Oracle Corporation
Posts: 3362
Joined: 7. Jun 2007, 09:11
Primary OS: Debian Sid
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: Linux, Windows
Location: Dresden, Germany
Contact:

Post by frank »

I was now able to reproduce this problem. It is indeed a 1.6.0 regression, fixed in SVN.
DeanoUk
Posts: 14
Joined: 4. May 2008, 13:28

Post by DeanoUk »

Even before I attempt to get networking running on the client VM, I'll need to get internet working on the host.

Here's my config:

Code: Select all

br0       Link encap:Ethernet  HWaddr 00:1D:09:68:50:33
          inet addr:10.0.0.220  Bcast:10.0.0.255  Mask:255.255.255.0
          inet6 addr: fe80::21d:9ff:fe68:5033/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:44 errors:0 dropped:0 overruns:0 frame:0
          TX packets:20069 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:5436 (5.3 Kb)  TX bytes:11840661 (11.2 Mb)

eth0      Link encap:Ethernet  HWaddr 00:1D:09:68:50:33
          inet6 addr: fe80::21d:9ff:fe68:5033/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:44 errors:0 dropped:0 overruns:0 frame:0
          TX packets:20998 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:6228 (6.0 Kb)  TX bytes:11986037 (11.4 Mb)
          Interrupt:169 Memory:f4000000-f4012100

eth1      Link encap:Ethernet  HWaddr 00:1D:09:68:50:31
          inet6 addr: fe80::21d:9ff:fe68:5031/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:11349 errors:0 dropped:0 overruns:0 frame:0
          TX packets:14 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:831111 (811.6 Kb)  TX bytes:1004 (1004.0 b)
          Interrupt:169 Memory:f8000000-f8012100

lo        Link encap:Local Loopback
          inet addr:127.0.0.1  Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING  MTU:16436  Metric:1
          RX packets:467940 errors:0 dropped:0 overruns:0 frame:0
          TX packets:467940 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:1323631269 (1262.3 Mb)  TX bytes:1323631269 (1262.3 Mb)

vbox0     Link encap:Ethernet  HWaddr 66:F8:E1:AB:F6:75
          inet6 addr: fe80::64f8:e1ff:feab:f675/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:4 overruns:0 carrier:0
          collisions:0 txqueuelen:500
          RX bytes:0 (0.0 b)  TX bytes:0 (0.0 b)

I've now assigned the client VM to 10.0.0.221, and removed the vbox0 IP as requested by camh.

I can SSH into 10.0.0.220 but I have no internet access from the serve, I can't ping google or an external IP - this is a bit weird?
DeanoUk
Posts: 14
Joined: 4. May 2008, 13:28

Post by DeanoUk »

Frank Mehnert wrote:DeanoUk, you choose the user 'root' when doing VBoxAddIF but you have to use the user which is starting VBox there. Please never start VBox as root.

We are currently trying to reproduce these problems but still had no luck.
Frank - cheers, just using root while we're debugging these problems, we won't continue to use it once we've resolved the issues!
DeanoUk
Posts: 14
Joined: 4. May 2008, 13:28

Post by DeanoUk »

It seems eth0 wasn't the correct ethernet config.
Bridging eth1 now allows me internet access on the client and host!
(Using the Intel card emu to get around the AMD problems).

However...
Though I can ssh out of the host box, and have internet access, I can now not remotely get into it via SSH or VNC, nor can I ping it.

Why would this be?!
DeanoUk
Posts: 14
Joined: 4. May 2008, 13:28

Post by DeanoUk »

DeanoUk wrote:It seems eth0 wasn't the correct ethernet config.
Bridging eth1 now allows me internet access on the client and host!
(Using the Intel card emu to get around the AMD problems).

However...
Though I can ssh out of the host box, and have internet access, I can now not remotely get into it via SSH or VNC, nor can I ping it.

Why would this be?!
A quick reboot seemed to solve these problems. Thanks for everyone's help thus far. Now onto a SuSE client...
Post Reply