Host Networking (H: Ubuntu 8.10 G: 2003 server)

Discussions related to using VirtualBox on Linux hosts.
Post Reply
wibblywobblyteapot
Posts: 3
Joined: 9. Apr 2009, 06:43
Primary OS: Ubuntu 8.10
VBox Version: OSE Debian
Guest OSses: 2003_server

Host Networking (H: Ubuntu 8.10 G: 2003 server)

Post by wibblywobblyteapot »

I'd really appreciate a little pointer to help me understand the concept of host networking.
The host box has 4 nics (eth0-3). Currently it uses eth0 for it's general LAN work.
This is in the 192.168.x.x range

I've been able to attach eth1 as a host adaptor to VB for the guest but it plain refuses to work (it's in a 10.x.x.x subnet known to work). The guest shows activity on the host (if the network ICONS on Windows can be trusted) but nothing on the distant host - if that makes sense. It's like the local VN guest is calling but unable to get any response. Activity is also shown on the VB console networking indicator itself. User is a member of the correct group.

To help me get a handle on this and troubleshoot it for myself I need to answer a couple of questions but my googling and RTFM'ing has not cleared them up - the online documentation varies wildly between older versions talking about bridging and TAP adaptors that appear to have been superseded - so I'm stumped on some basics;

1. On the host OS I assume I need to assign an IP to the guest host adaptor and bring it up. I've done this in the /etc/network/interfaces file
2. Does this IP address need to match the guest OS adaptor OR (I suspect) be listed as it's gateway
3. Can anyone point me to a good up-to-date resource on VB networking?

If anyone can spare a few minutes to clear this up I would be really grateful for your time.
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

Re: Host Networking (H: Ubuntu 8.10 G: 2003 server)

Post by Sasquatch »

If the guest gets a 10.0.2.x address, it's attached to NAT. You need to change it to Host Interface, or Bridged as it's in the new version.
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.
wibblywobblyteapot
Posts: 3
Joined: 9. Apr 2009, 06:43
Primary OS: Ubuntu 8.10
VBox Version: OSE Debian
Guest OSses: 2003_server

Re: Host Networking (H: Ubuntu 8.10 G: 2003 server)

Post by wibblywobblyteapot »

Thanks for the response. It is already set to host.
The guest OS has a static IP of 10.0.0.5. The host adaptor is mapped to eth1 on the host.

My question is on the HOST OS what do I need to set eth1 to? Do I bring it up and give it an IP, do I leave it down? Will VB bring it up?
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

Re: Host Networking (H: Ubuntu 8.10 G: 2003 server)

Post by Sasquatch »

You need a link on the interface first before you can actually use it. Then of course set the IP in the same range as your Guest.
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.
wibblywobblyteapot
Posts: 3
Joined: 9. Apr 2009, 06:43
Primary OS: Ubuntu 8.10
VBox Version: OSE Debian
Guest OSses: 2003_server

Re: Host Networking (H: Ubuntu 8.10 G: 2003 server)

Post by wibblywobblyteapot »

Sasquatch wrote:You need a link on the interface first before you can actually use it. Then of course set the IP in the same range as your Guest.
I think we are saying that the interface needs to be UP with an IP address in the same range as the guest. Thanks.
It still refuses to work on one physical machine where the guest is 2003 server. Ummmm.

What is odd is I have it working on a different box using similar settings where the host is ubuntu/guest xp.It has a serious flaw;
Instead of the host OS using eth0 for it's day to day internet connectivity, it seems to try and use eth1 which is bound to the guest and times out. It seems that host system tries to route packets over any interface to the outside world and I need to find a way to stop this and 'isolate' the interfaces.
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

Re: Host Networking (H: Ubuntu 8.10 G: 2003 server)

Post by Sasquatch »

For that last part, you need to change the routing table. Now, eth1 is the default gateway, which is wrong. Eth0 must be that. So instead of setting a default gateway on eth1, set a route to the network that's behind eth1. See the route man pages for how to do that. It's something like route add -net <network> eth1.

As for your first situation, yes, the interface must be UP, else it won't work. You need to switch on your mobile phone before you can call someone or be called ;).
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.
Post Reply