Hi Folks,
I am trying to setup two virtual machines like this:
1) each VM needs to have internet working
2) each VM should have a private internal network interface
3) each VM should also have a IP which should be accessible from each other. e.g. If VM1 has 10.0.2.10 and VM2 has 10.0.2.11, VM1 should be able to ssh into 10.0.2.11 and vice-versa.
What kind of a virtualbox networking setup do I need?
Till now, I have been able to make only NAT (static IP and DHCP configurations -- in the 10.0.n.x subnet, where n >=2) and internal networking work -- with windows host and Ubuntu VMs. Host Only networking is turning out difficult to get to work.. even with the promiscuous wireless mode in windows.
I would appreciate your thoughts.
Thanks
Gaurav
What kind of a virtualbox networking setup do I need?
-
- Posts: 7
- Joined: 14. Apr 2008, 21:08
-
- Posts: 7
- Joined: 14. Apr 2008, 21:08
assume that I will be behind a NETGEAR router
Just assume that I will be behind a NETGEAR router and I will have a subnet of 192.168.0.x
-
- Volunteer
- Posts: 167
- Joined: 5. Apr 2008, 22:43
- Primary OS: MS Windows 7
- VBox Version: PUEL
- Guest OSses: Windows XP, Ubuntu 10.04, Legacy Testing
To use Host networking, you have to bridge the VirtualBox adapter with the Host's ethernet adapter. Unfortunately, most wireless adapters on the market don't support bridging, which may be the problem you're having with Host Interface. You may be able to accomplish what you need by setting up ICS on the wireless adapter, but I haven't really worked with multiple VM's running simultaneously and can't say much about networking 2 VMs yet.
-
- Volunteer
- Posts: 17798
- Joined: 17. Mar 2008, 13:41
- Primary OS: Debian other
- VBox Version: PUEL
- Guest OSses: Windows XP, Windows 7, Linux
- Location: /dev/random
I have tried the ICS option with the wireless card, it does not work as you might think. Use NAT for both VMs to access internet, use the Internal Networking for private communication between the VMs. As NAT will give you an IP address of 10.0.2.15 on both machines, it's best to set a different subnet range for the internal interface. Since you're on the 192.168.0.x range, you can use either 192.168.1+.x or, to really seperate things, use the class B network 172.16-31.x.y range. Either way, be sure not to use the 192.168.0.x range, as that will put you in the same range as the other network systems, though they cannot access your VMs, the VMs can access them and that could lead to conflicts when trying to ssh to the other VM.
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.
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.
-
- Volunteer
- Posts: 167
- Joined: 5. Apr 2008, 22:43
- Primary OS: MS Windows 7
- VBox Version: PUEL
- Guest OSses: Windows XP, Ubuntu 10.04, Legacy Testing
Here's another idea for you . . . VBox supports 4 network adapters per VM, so set both VM's up with NAT for internet access, and a Host adapter for each to bridge together in the host, but not bridged with the host's ethernet. If you try this, let me know if it works and how well. Theoretically, this should create an isolated VM network that should give both VMs internet access as well.