Search the VMware Knowledge Base (KB)
View by Article ID

Configuring and troubleshooting basic software iSCSI setup (1008083)

  • 78 Ratings

Symptoms

  • Targets are numbered out of sequence.
  • Targets do not appear in VMware Infrastructure vSphere Client or VirtualCenter.
  • Targets do not appear in vSphere Client or vCenter Server.

Purpose

This article provides steps about basic software iSCSI setup, configuration and troubleshooting.

Resolution

Configuration



In vSphere Client/VMware Infrastructure (VI) Client or vCenter Server:
  1. Ensure you have a separate vSwitch for iSCSI.
  2. Add a VMKernel and Service Console portgroup and give them appropriate IPs.

    Notes:
  3. Log in to the ESX host and ensure you ping the iSCSI array by running this command:

    # ping 10.1.10.100

    PING 10.1.10.100 (10.1.10.100) 56(84) bytes of data.
    64 bytes from 10.1.10.100: icmp_seq=0 ttl=64 time=0.766 ms

    Note: You do not need to use ping when working with ESX / ESXi 4.0 hosts.
  4. Log in to the ESX host and ensure you can vmkping the iSCSI array by running this command:

    # vmkping 10.1.10.100

    PING 10.1.10.100 (10.1.10.100): 56 data bytes
    64 bytes from 10.1.10.100: icmp_seq=0 ttl=64 time=0.940 ms

    If you are unable to ping or vmkping the array, you must correct your network connectivity issue before iSCSI works.

    Using netcat (nc) see if you can reach the iSCSI TCP port (default 3260) on the storage array from the host:

    # nc -z 10.1.10.100 3260
    Connection to 10.1.10.100 3260 port [tcp/http] succeeded!

    Note: The netcat command is available with ESX 4.x and ESXi 4.1 and later.

  5. Log in to vCenter Server, click on the ESX host, and click Configuration.
  6. Click Storage Adapters and click on the iSCSI Software Adapter.
  7. In the Details pane, click Properties.
  8.  
  9. In the General tab, click Configure, select Enabled.
  10. Click OK.

    Note: You notice that the Status is now enabled, and the iSCSI name has a valid IQN.
  11. Configure the iSCSI array to use the IQN you have just created. Generally, you must assign storage to the ESX host from the array.
  12. Click the Dynamic Discovery tab and click Add.
  13. In the Add Send Targets Server area, add the iSCSI array IP to the iSCSI Server field and click OK.
  14. After the iSCSI Server is added, click Close. This may take a significant amount of time.
  15. Rescan the ESX host storage in the Storage Adapters section.
  16. After the rescan has completed, click on the iSCSI initiator to see information about the SAN array, as well as one or more targets.

Troubleshooting

To troubleshoot your setup or re-number your targets for ESX 3.x:

  1. Ensure that the array, and possibly each Service Processor, has an entry in each of these files:

    • /etc/vmkiscsi.conf

      Syntax: DiscoveryAddress=<Array_IP>:<iSCSI Port On Array>

      For example, DiscoveryAddress=10.200.107.10:3260

    • /var/lib/iscsi/vmkbindings

      Syntax: 0 0 <Array_IQN>

      For example, 0 0 iqn.1992-08.com.company:sn.84259608

      Note: This file is rebuilt on rescan and should be recreated if iSCSI target numbers are not in sequence.

    • /var/lib/iscsi/vmkdiscovery

      Syntax: 0 0 <Array_IQN>

      For example, 0 0 iqn.1992-08.com.company:sn.84259608

      Note: This should be recreated if iSCSI target numbers are out sequence. The preceding commands do not apply to ESX 4.0.

  2. Reboot the ESX host to have the changes take effect.
Note: If the vswitch is using NIC teaming, as a troubleshooting step, try disabling the second NIC and see if iSCSI functions.
 
 
For ESX/ESXi 4.x to 6.x
 
The iSCSI daemon was updated significantly in ESX/ESXi 4.x and later and now uses a little database backend. For more information on ESX 4.0 iSCSI logging, see Verbose logging and information for the software iSCSI initiator in VMware ESX 4.x and ESXi 4.x / 5.x (1013283).
 
Notes:
  • If the iSCSI vSwitch is using NIC teaming, as a troubleshooting step, try disabling the second NIC to see if iSCSI functions.
  • If the configuration on both the host and the array have been checked and appear to be correct, engage your array hardware vendor to verify that the firmware on the array is up to date. Firmware upgrades have been noted to resolve iSCSI connectivity problems on certain types of arrays.
  • When there are multiple vmkernel port groups, as a best practice, place the second vmnic as unused instead of standby.
  • For example:
iSCSI 1 vmkernel port group Active NIC vmnic 1 / Unused vmnic 2
iSCSI 2 vmkernel port group Active NIC vmnic 2 / Unused vmnic 1

Additional Information

Tags

configuring-iscsi troubleshooting-iscsi

See Also

Update History

11/16/2012 - Updated products for ESXi 5.1.x and added link to KB 2038869 12/04/2013 - Added ESXi 5.5 to Products

Request a Product Feature

To request a new product feature or to provide feedback on a VMware product, please visit the Request a Product Feature page.

Feedback

  • 78 Ratings

Did this article help you?
This article resolved my issue.
This article did not resolve my issue.
This article helped but additional information was required to resolve my issue.

What can we do to improve this information? (4000 or fewer characters)




Please enter the Captcha code before clicking Submit.
  • 78 Ratings
Actions
KB: