Page 1 of 1

separate LAN for network of physical hosts and virtual hosts

Posted: 10. Jul 2009, 20:19
by schoenborno
Is it possible to have a network of physical hosts on one network, and have the VM's they carry be on a completely separate network, without assigning static IP addresses? Ie both LAN's should use DHCP, but the host must only see one network, and the guest a different network. So how about following:

host 1:
  • nic 1: cat5 to LAN1, IP by DHCP
  • nic 2: cat5 to LAN 2, static IP unset
  • vm 1: bridged to nic 2, IP by DHCP
  • vm 2: bridged to nic 2, IP by DHCP
host 2:
  • nic 1: cat5 to LAN1, IP by DHCP
  • nic 2: cat5 to LAN 2, static IP unset
  • vm 3: bridged to nic 2, IP by DHCP
  • vm 4: bridged to nic 2, IP by DHCP
The two hosts would end up with an IP in the 10.0.0.x subnet, the four virtual machine guests with IP in the 192.168.0.x subnet, and no network traffic could go between the two networks.

Any reason why this wouldn't work?

Re: separate LAN for network of physical hosts and virtual hosts

Posted: 10. Jul 2009, 20:58
by vbox4me2
2 different subnets on the same LAN, hmm... only dhcp server issues if it can't differentiate between the two, I have 4 different subnets on one LAN and one dhcp server serving them all but this is highly smart dhcp software server solution that can handle this.

Re: separate LAN for network of physical hosts and virtual hosts

Posted: 11. Jul 2009, 03:32
by schoenborno
OP says "LAN 1" and "LAN 2", so there are two LANs (there has to be, since there can only be one DHCP server on a LAN and I don't have control over the main DHCP server -- ie the one on LAN 1 -- though I do have control over the DHCP server on LAN 2). I want to make sure that LAN 1 and 2 cannot be bridged (security restrictions).

Re: separate LAN for network of physical hosts and virtual hosts

Posted: 11. Jul 2009, 13:06
by vbox4me2
With a bridge you select which NIC is used by the VM, by default there should be no routing between 2 nics on the Host, so this should work, a ping and traceroute should show that fact.