Create a private network between virtual machines running in multiple hosts using Virtualbox

networkingvirtualboxvirtualization

I want to create a private network between virtual machines running in multiple hosts using Virtualbox. Linux will be used as guest operating system, and Windows in the hosts.

How do I set this up using Virtualbox?

Best Answer

Option 1: Hardware

  • Purchase a dedicated NIC for each machine (or use VLANs if your NICs support them).
  • Attach these NIC to the virtual machines only
  • Connect these NICs together with an isolated physical switch or use VLANs on your switch if it is supported

This should give you a private network between hosts

Option 2: Software

  • Configure an OpenVPN server on a guest VM
  • Have each Linux machine VPN to the OpenVPN server on a network that only exists on the OpenVPN guest VM

By connecting the machines using virtual private networking, you should be able to create a private LAN that only those machines exist on.

Related Topic