Configuring iSCSI port binding with multiple NICs in one vSwitch for VMware ESXi
search cancel

Configuring iSCSI port binding with multiple NICs in one vSwitch for VMware ESXi

book

Article ID: 323116

calendar_today

Updated On:

Products

VMware vSphere ESXi

Issue/Introduction

This article provides information on setting up the correct NIC teaming policies to allow iSCSI port binding.

Port binding is used in iSCSI when multiple VMkernel ports for iSCSI reside in the same broadcast domain and IP subnet to allow multiple paths to an iSCSI array that broadcasts a single IP address..

Port binding is required for iSCSI vmkernels when they are in the same subnet. For example, you might assign an IP address of ##.##.156.## to the vmkernel adapter you want to use for iSCSI. The routing table then contains an entry for the ##.##.156.## network for this adapter. If you then set up a second adapter for iSCSI and assign it an IP address of ##.##.156.25, the routing table contains a new entry for the ##.##.156.25 network for the second adapter. However, when the TCP/IP stack reads the routing table, it never reaches the second entry, because the first entry satisfies all routes to both adapters. Therefore, no traffic ever goes out on the second iSCSI vmkernel adapter, and all IP storage traffic goes out on the first iSCSI vmkernel adapter.

Note: Since the ESXi host receives a routing table entry automatically for each vmkernel on the host, it is not recommended to override the default gateway on the vmkernel unless layer 3 connectivity is required. 

Symptoms:
Multiple NICs within the same vSwitch disallow port binding due to the default NIC teaming policies.

Please refer : Considerations for using software iSCSI port binding in ESXi

Environment

VMware vSphere ESXi 6.x
VMware vSphere ESXi 7.x
VMware vSphere ESXi 8.x

Resolution

To set up a teaming policy that is compatible with iSCSI port binding, you need 2 or more vmkernel ports in the vSwitch, and an equivalent amount of physical adapters to bind them to. Each vmkernel port is bound to a physical adapter and then attached to the software iSCSI adapter.
 
To set up the correct teaming policy to allow iSCSI port binding using the vSphere Web Client:
  1. Under vCenter Home, click Hosts and Clusters.
  2. Click on the host.
  3. Click Configure > Networking > Virtual Switches.
  4. Click the vSwitch that has your iSCSI vmkernel port group.
  5. Select the vmkernel port group and click on the three dots.
  6. Click the Edit Settings menu and modify the vmkernel portgroup properties.
  7. Open the Teaming and Failover section.
  8. Under Failover order check the Override check box.
  9. Select all VMnic adapters except the one you want to bind and click the Move Down arrow to move all other NIC adapters to the Unused Adapters list.
  10. Repeat steps 5-9 for each iSCSI vmkernel port to ensure each vmkernel port has a unique active adapter.
    For example:
    • 2 vmkernel portgroups: Storage 1 and Storage 2
    • 2 physical adapters: vmnic0 and vmnic1
    • In portgroup Storage 1, vmnic0 is active and vmnic1 is unused
    • In portgroup Storage 2, vmnic1 is active and vmnic0 is unused
  11. In the host Configure tab, click Storage Adapters
  12. Select iSCSI Software Adapter vmhba.
  13. In the adapter details pane click the Network Port Binding tab.
  14. Click ADD to bring up a list of eligible adapters.
    Note: There should be no adapters in the list at this point.
  15. Check the box beside Port Group and click OK.
  16. Click the Rescan Adapter icon to rescan the iSCSI Software Adapter.



Additional Information

See Setting Up Network for iSCSI and iSER with ESXi for additional details.