Page 1 of 1

Virutal Router on Virutalbox

Posted: 9. Jan 2013, 11:07
by drkansari
Dear Genius,

I want to use virtual box as multiple site like there are different subnet like detail given below.

Site A: using Internal adapter
IP : 192.168.100.1
Subnet : 255.255.255.0

Site B: using Internal adapter
IP : 192.168.102.1
Subnet : 255.255.255.0

Site C: using Internal adapter
IP : 192.168.103.1
Subnet : 255.255.255.0

Site D: using Internal adapter
IP : 192.168.104.1
Subnet : 255.255.255.0

is it possible like all guest installed on subnet mention above can share data. keep in mind that are separate like different site in MPLS-VPN with different subnet. but i want to use virutalbox as MPLS-VPN testing lab.

Re: Virutal Router on Virutalbox

Posted: 9. Jan 2013, 11:12
by noteirak
Enable IP routing in your VM, and set the GW address of the other VM as the IP address of your router VM in the same internal network.
How to enable IP routing exactly will depend on your OS, but you will find *a lot* of guides on how to do it on google for any OS.

Re: Virutal Router on Virutalbox

Posted: 10. Jan 2013, 00:12
by BillG
Note that to really keep traffic for the sites separate you would need to put them in different internal networks as well as different subnets. In VirtualBox you do that by using a different name for each internal network. You would also need 4 NICs in your vm router - one for each site. eg

192.168.100.x dg 192.168.100.1
|
192.168.100.1 dg blank
router vm
192.168.102.1 dg blank
|
192.168.102.x dg 192.168.102.1

and so on for the other networks/subnets.