Would you like to learn how to configure a VLAN trunk between Vmware ESXi and an HP Switch? In this tutorial, we are going to show you all the steps required to create VLANs and configure a trunk.

This tutorial was tested on Vmware ESXi 6.5

This tutorial was tested on Vmware ESXi 6.7

This tutorial was tested on an HP Switch 1910.

The video above shows how to configure VLAN using older versions of Vmware ESXi 6, 5.5 and 5

Vmware ESXi Playlist:

On this page, we offer quick access to a list of videos related to Vmware ESXi.

Don't forget to subscribe to our youtube channel named FKIT.

Tutorial - HP Switch Trunk Configuration

First, you need to create a list of VLANS.

Open a browser software, enter the IP address of your Switch and access the HP Switch web interface.

HP Switch Login

On the prompt screen, enter the administrative login information.

Factory default access information:
Username: admin
Password: (no password)

After a successful login, the administrative menu will be displayed.

Access the Network menu, and select the VLAN option.

hp switch vlan menu

On the VLAN screen, select the Create tab on the top of the screen.

To create a new VLAN, enter the desired identification number and click on the Create button.

hp switch create vlan

In our example, the following VLANS were created:  100 and 200.

The VLAN 1 already exists by default on an HP Switch.

After finishing the VLAN creation, you need to configure a switch port as a trunk.

On the VLAN screen, select the Modify Port tab on the top of the screen.

To configure a switch port as a trunk, you will need to:

• Select the desired port.

• Select the Link Type option.

• Select the Trunk mode.

In our example, we configured the switch port 10 in trunk mode.

hp-switch-trunk-link-type

After configuring the switch port as a trunk, you need to associate a list of authorized VLANS.

To configure the list of authorized VLANS you need to:

• Select the desired port.

• Select the tagged membership type.

• Enter the ID of the desired VLAN or VLANS.

In our example, we authorized VLANS 100 and 200 to use this trunk.

hp switch trunk add vlan

Now, you need to set the default VLAN of the trunk.

To configure the trunk's default VLAN you need to:

• Select the desired port.

• Select the untagged membership type.

• Enter the ID of the desired VLAN

In our example, we configured VLAN 1 as the default VLAN to this trunk.

Every time this switch port receives a packet without any VLAN identification it will assume that the packet belongs to the default VLAN 1.

hp switch trunk default vlan

In the end, packets from VLAN 1, 100 and 200 are authorized to use this trunk.

You have successfully configured a switch port as a trunk.

Don’t forget to save your switch configuration.

Tutorial - Vmware ESXi Trunk Configuration

First, you need to access the Vmware web interface.

Open a browser software, enter the IP address of your Vmware ESXi server and access web interface.

vmware web interface

On the prompt screen, enter the administrative login information.

After a successful login, the Vmware dashboard will be displayed.

Vmware web export virtual machine

On the Vmware Dashboard, Access the Networking Menu.

Access the Port Groups tab.

Click on the Add port group option.

Vmware ESXi Vlan Add

On the next screen, you need to configure the following items:

• Name - Enter an identification to your Vlan.
• VLAN ID - Enter the VLAN identification number.

After finishing your configuration, click on the Add button.

Vmware Vlan Configuration

If you need to add another VLAN, click again on the Ad port group option.

Perform the same configuration to the second VLAN.

Vmware ESXi Vlan configuration

Don't forget to save your configuration.

To verify your configuration, access the Networking menu.

Access the Virtual Switches tab.

Click on the Virtual Switch.

Vmware trunk virtual switch

On the right part of the screen, you are able to see the trunk configuration.

In our example, we can see that VLANS 100, 200 and 0 are able to pass through the VMNIC1 interface.

Vmware Trunk native vlan

Keep in mind that the Vmware interface VMNIC1 needs to be connected to a switch port previously configured as a trunk.

In our example, the Vmware interface VMNIC1 needs to be connected to the HP Switch port 10.

The HP switch port 10 was configured to allow the traffic of VLANS 1, 100 and 200.

Any packet that arrives at the switch port without VLAN tags will be considered a member of the native VLAN.

In our example, The VLAN 1 was configured as the HP Switch Native VLAN.

Congratulations! You have successfully configured a VLAN trunk between Vmware ESXi and an HP Switch.

Tutorial - Vmware Virtual Machine VLAN Configuration

Now, we are going to teach you how to assign a virtual machine to a specific VLAN.

Access the Vmware Dashboard.

Vmware web export virtual machine

On the Vmware Dashboard, Access the Virtual Machines menu Menu.

Select the desired virtual machine.

Click on the Actions button and select the option named Edit settings.

Vmware Virtual Machine Settings

On the virtual machine properties screen, you need to perform the following configuration:

• Locate the desired network adapter
• Select the desired VLAN

After finishing your configuration, click on the Save button.

Vmware VM VLAN

In our example, the network interface of a virtual machine was assigned to the VLAN 100.

Don't forget to save your configuration.

Congratulations! You have successfully configured a virtual machine as a VLAN member using Vmware ESXi.