Problems when creating a network bridge within a VM and trying to bridge between "internal networks"

Discussions related to using VirtualBox on Mac OS X hosts.
Post Reply
foo_
Posts: 19
Joined: 12. May 2018, 15:18

Problems when creating a network bridge within a VM and trying to bridge between "internal networks"

Post by foo_ »

I'm trying to prototype some network configs (virtually) and I'm running into problems when I'm bridging network adapters within VMs and then assigning them to VirtualBox "internal networks".

Here's one basic setup that doesn't seem to work:

NAT eth0 [MikroTik VM] eth1 <---internal network 1---> eth0 [Open vSwitch VM] eth1 <--- internal network 2 ---> eth0 [Ubuntu/Windows VM]

Notes:
MikroTik is running DHCP server, NAT, etc
Open vSwitch is installed on Ubuntu. This VM actually has 8x network cards, they are all bridged together.

From the above the VM on the right (Ubuntu or Windows etc) should receive an IP address from the DHCP server running on MikroTik RouterOS VM. This seems to work some of the time, however the Ubuntu/Windows VM can never ping the MikroTik router. Even when an IP address is assigned by DHCP, if I look at the ARP table on the Ubuntu/Windows VM, there is no entry for the MAC addresses from the MikroTik VM network card, or the network cards on the Open vSwitch VM (the bridge will only have one MAC address).

Is this a limitation with VirtualBox and "internal networks"? To confirm if my Open vSwitch bridge works, I bridged some of the virtual network adapters to physical adapters and connected some real PCs and the network connectivity worked fine. I also tried using a bridge in a MikroTik VM (essentially making MikroTik into a switch) and this worked too. It's only when I create and use a network bridge (within a VM) and "internal networks" that things seem to stop working. I have tried this on Mac OS and Windows VirtualBox hosts with the same results (i.e. bridges within VMs work when bridged to physical adapters, but doesn't work when trying between "internal networks").

Any ideas?

VirtualBox ver: 5.2.22
Hosts: Mac OS Majave/Windows 10
mpack
Site Moderator
Posts: 39134
Joined: 4. Sep 2008, 17:09
Primary OS: MS Windows 10
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: Mostly XP

Re: Problems when creating a network bridge within a VM and trying to bridge between "internal netwo

Post by mpack »

The bridge feature doesn't bridge networks, it bridges network adapters. Specifically it bridges the virtual network card of a given VM to a physical network adapter installed in the host.
foo_
Posts: 19
Joined: 12. May 2018, 15:18

Re: Problems when creating a network bridge within a VM and trying to bridge between "internal netwo

Post by foo_ »

mpack wrote:The bridge feature doesn't bridge networks, it bridges network adapters. Specifically it bridges the virtual network card of a given VM to a physical network adapter installed in the host.
I'm aware of this.

The problem I'm having is when I try to bridge two VirtualBox "internal networks" with a VM with multiple network cards that are configured as a bridge within the VM.

I'm currently using wireshark to try and get an idea of what is going on, however I'm not that familiar with wireshark.
foo_
Posts: 19
Joined: 12. May 2018, 15:18

Re: Problems when creating a network bridge within a VM and trying to bridge between "internal netwo

Post by foo_ »

How does the "internal" network setting in VirtualBox work at the layer 2 level? I can't really find any further info on this. I'm wondering if the problem with bridged adapters not working (within a VM) is related to the bridge adapters within the VM only using the MAC address of the bridge and not the MAC address assigned to the NIC by VirtualBox (in the VM network settings).

I've also tried enabling promiscuous mode on all the adapters but it doesn't seem to make a difference.
Post Reply