Wednesday, November 4, 2020

VMware Multiple Bridged Adapter

Using the VMware Workstation program, we can create the Virtual Computer or Virtual Machine. In this machine, we can add one or more virtual NIC card or network adapter as per our requirements. In the VMware Workstation program, there are multiple network modes available to working with these virtual network adapter or virtual network interfaces. If we have two network adapters attached with our virtual machine, then we can configure one adapter to work with "Bridge" mode and the other one we can configure to work with "NAT" mode. It is possible to configure both of the network adapters to work with the "Bridge" mode. 

Please consider the below diagram to working with this tutorial.


According to the above diagram, we have two network cards attached to our host machine. The name of these network adapters is respectively "Host NIC-1" and "Host NIC-2". Those two network cards are connected with two different networks. 

Then we have created a virtual machine on this host computer. This virtual machine has also two virtual network interfaces. Respectively they are named "V-NIC-1" and "V-NIC-2". These virtual network interfaces should be bridged with the host network interfaces. The virtual network interface "V-NIC-1" should be bridged with the host network interface "Host NIC-1". And in the same way the virtual network interface "V-NIC-2" should be bridged with the host network interface "Host NIC-2".

In this tutorial, we will learn how to bridge multiple virtual network adapters or multiple virtual network interfaces with multiple physical network interfaces or host network adapters using VMware.

As per our diagram, we have attached two virtual network interfaces with our virtual machine. Now we want to bridge between "V-NIC-1" and "Host NIC-1". In the same way, we will do bridge between "V-NIC-2" and "Host NIC-2".

If we select the network mode as "Bridged" for our virtual "V-NIC-1" adapter, then VMware will select the host network adapter automatically to work with "V-NIC-1". In the same manner, if the "Bridged" mode is selected for "V-NIC-2", then the host network adapter will be selected automatically. Because of this automatic selection process, we can't control which host network adapter should be bridged to which virtual network adapter. That's why we have to stop this auto-selection process. And also we have to manually select the interface to work with our virtual network adapter.

To manually select the physical network interface or host network interface which should be bridged with a virtual network adapter or virtual network interface, we have to work with "Virtual Network Editor". There we have to modify the network configuration.

To open the "Virtual Network Editor", please go to the "Edit" menu from the VMware Workstation menu bar.


After opening the "Virtual Network Editor" tool, go to the "VMnet Information" section. Here you will find all the network information which is available on this VMware Workstation Program. Our first network "VMnet0" is pre-configured with the "Automatic" value for the "Bridge to" field.


Now change this "Automatic" value with your desired network interface card. Simply click on the drop-down menu and select your network card.


Here "ASIX AX88179 USB" interface is representing our host network interface "Host NIC-1". From now on "VMnet0" network will be bridged with that host interface.

In the same way, we will do it again for our second virtual network. If we already have an available network to configure for "V-NIC-2", then we can modify that network or we can add a new virtual network.

To add a new virtual network just click on "Add Network" on the "Virtual Network Editor" tool.


Now select the available network from the drop-down list. In this example, we will select VMnet3. You can choose it whatever you want.


After the click on the "OK" button, the network will be added to the list and will be displayed.


Now we will bridge this network with our "Host NIC-2" network adapter. For that, just select the "VMnet3" from the list and then select the host network interface from the "Bridge to" field.


Here "Realtek PCI" network adapter is representing our "Host NIC-2" network adapter.

Our network configuration is done. From now on the virtual network VMnet0 is responsible to transfer all the traffics to ASIX AX88 means Host NIC-1 adapter and at the same time, the virtual network VMnet3 is responsible to transfer all the traffics to "Realtek PCI" means Host NIC-2 adapter.

Now we will associate these virtual networks with our virtual network interfaces or NIC cards. To do that open your virtual machine settings and click on your virtual network adapter. 


Now click on your first network adapter (V-NIC-1) and select custom mode. From the drop-down list select the VMnet0 network.

From now on this interface will be associated with the Host NIC-1. We have to configure an IP address for this virtual network adapter similar to the Host NIC-1 IP range.
 
In the same way, now click on your second network adapter (V-NIC-2) and select the custom mode. Select the "VMnet3" virtual network from the drop-down list.


From now on this interface will be associated with the Host NIC-2. We have to configure an IP address for this virtual network adapter similar to the Host NIC-2 IP range.

All the configuration is done to bridge traffics between the virtual and host network adapters. The communication should be successful now.


No comments:

Post a Comment