VMware ESX(i) 4.0 (vSphere) -Connecting to an iSCSI Storage Target.

VMware

With a complete re-write of the iSCSI portion of the code, ESX 4(vSphere) provides better performance and useful features such as Jumbo Frame support and TCP Segmentation Offload (TSO).  There is more reason than ever to consider iSCSI based share storage to house your VMs.

There are many low cost iSCSI storage solutions available such as OpenFiler of which I have written a configuration article here.

Here is a quick guide to assist you on your way to connecting your ESX(i) 4.0 host to an iSCSI source.  Many of these screenshots are self explanatory so I will keep my descriptions to a minimum.

Initially you will most likely only have a ‘Management’ and a ‘Virtual Machine Network’ as you’ll need to have a dedicated network connection for the iSCSI traffic (between the ESX host and the iSCSI target) then…

VMware ESX 4 vSphere iSCSI 

… from the ‘Configuration’ –> ‘Networking’ screen select ‘Add Networking’.

VMware ESX 4 vSphere iSCSI

Select ‘VMkernel’ as the ‘Connection Type’.

VMware ESX 4 vSphere iSCSI

Select the NIC(s) you want to use for your iSCSI VMKernel connection (ensure that it has network connectivity through to your iSCSI target ideally on its own separate network segment – this is strongly advised).

VMware ESX 4 vSphere iSCSI

Type in a meaningful ‘Network Label’ none of the other options are required so leave them unchecked.

VMware ESX 4 vSphere iSCSI

Give your new iSCSI network connection a IP address.  As a dedicated network is strongly recommended for iSCSI traffic ensure that it is given a unique IP address on the same subnet as your iSCSI target.  As this traffic will not be leaving this dedicated network then there no need in this example to specify a new gateway.

VMware ESX 4 vSphere iSCSI

After configuring this new iSCSI VMKernel port you will now see it displayed in the ‘Networking’ area of the ‘Configuration’ section.  As you can see I am only using a single NIC meaning that this is potentially a single point of failure.  If you are considering using iSCSI in a production environment then you would ideally want to use multiple NICs for extra resilience.

 VMware ESX 4 vSphere iSCSI 

Now select ‘Storage Adapters’ from the ‘Configuration’ menu.

VMWare ESX vSphere Configuration

Storage Adapters VMWare ESX 4 vSphere

As outlined in the screen shot below select the ‘iSCSI Software Adapter’ and then click on ‘Properties’.

VMWare ESX 4 vSphere iSCSI Storage Adapters

You’ll notice that by default the status of the ESX iSCSI software initiator is set to ‘Disabled’.  We want to change this.. (see steps below)

VMWare ESX 4 vSphere iSCSI initiator

You’ll notice that when you enable the iSCSI initiator a rather long name will be auto generated in the ‘iSCSI Name’ field.  This is a unique name that only your ESX host will have.  It can be changed to something else of your choosing though just make sure that it is unique.  I personally always leave them with the auto generated iSCSI name.

VMWare ESX 4 vSphere iSCSI Properties

Now select the ‘Dynamic Discovery’ tab and press the ‘Add’ button as we now want to tell our ESX host where to find the iSCSI target.  In the ‘iSCSI Server’ field enter in the IP address of your iSCSI target – you shouldn’t have to change the default port number.

Depending on the level of security set on your iSCSI target you may have to enter in the ‘CHAP’ authentication details.  Talk to the person who configured your iSCSI target to see if you need to do this..

VMWare ESX 4 vSphere iSCSI Target

Once you’ve added in the details of your iSCSI target you’ll see it’s IP address appear in the ‘Send Targets’ list.

VMWare ESX 4 vSphere iSCSI Send Targets

You’ll also be prompted to rescan the Host Bus Adapter (HBA).  Select ‘Yes’ as you want your ESX host to go and try to connect to your specified iSCSI target.

VMWare ESX 4 vSphere Rescan the Adapter

Everything going to plan and you should now see your iSCSI target (in this case my OpenFiler) appear in the ‘Storage Adapters’ configuration screen.  This means that it has connected through successfully.

VMWare ESX 4 vSphere iSCSI

This next step will vary depending on whether your iSCSI storage has VMFS applied to it already or not.  If it hasn’t and this is fresh new disk presented to the ESX host then you’ll want to format it with VMFS to allow VMs to be stored on it.  Else if it has already been configured with VMFS then this iSCSI storage will automatically appear for use to your ESX host (see below).

 VMWare ESX 4 vSphere iSCSI

You will now be all set to go. Enjoy!

Cool - You've Finished!

Technorati Tags: ,,,,,,,,,

No related posts.

You can leave a response, or trackback from your own site.

18 Responses to “VMware ESX(i) 4.0 (vSphere) -Connecting to an iSCSI Storage Target.”

  1. [...] has this covered here. If your ESX VM is not finding the iSCSI targets, [...]

  2. A Mikkelsen says:

    Keep up the good work.
    Nice and simple guides :-)

  3. [...] up iSCSI on vSphere (ESX 4.x) you might want to take a look at this guide from teachhead.co.uk http://www.techhead.co.uk/vmware-esxi-4-0-vsphere-connecting-to-an-iscsi-storage-target ESX, ESXi esx, esx 4, iscsi, [...]

  4. [...] reading the bible on getting ESXi and Openfiler talking, decided to turn those babies into Openfiler NAS devices. [...]

  5. [...] has this covered here. If your ESX VM is not finding the iSCSI targets, [...]

  6. Frank says:

    Thanx for the easy-to-understand-guide! You made my day! Keep up the excellent work :-)

  7. Glossimer says:

    Pipers Parlor…

    I saw this really great post today….

  8. Michael says:

    Hi! Thanks for the post!
    It really helps me alot!

    I have a follow up question;
    Why when i try to connect my 4TB iscsi target it’s not giving the full 4TB capacity? But it’s giving me a less than 2TB space.
    Is this one of the vsphere limitation? btw, I’m using esx 4 vsphere.

    Thank you so much.

  9. george says:

    This was great. I used freenas as my Iscsi server and I was up with you guide in a few minutes. Thank you.

  10. Chris K says:

    Hi there

    Fab tutorial! I’ve followed it to the letter but there are no targets to format right at the end. Everything up until that point appears fine. Any ideas what I’m doing wrong?

    Best wishes
    Chris

  11. [...] drive which is setup with RAID 5 and and 3.6TB of available space. Using instructions from ” http://www.techhead.co.uk/vmware-esxi-4-0-vsphere-connecting-to-an-iscsi-storage-target ” I was able to add the device to the ESXi host. Unfortunately it was only allowing me to use [...]

  12. L-E-G-O says:

    thank you! Great tutorial ;-)

  13. [...] drive which is setup with RAID 5 and and 3.6TB of available space. Using instructions from ” http://www.techhead.co.uk/vmware-esxi-4-0-vsphere-connecting-to-an-iscsi-storage-target ” I was able to add the device to the ESXi host. Unfortunately it was only allowing me to use [...]

  14. Steve says:

    Michael,
    There is a 2TB limit on LUNs for ESX. You need to be really careful here. If you extend a LUN beyond 2TB after connecting it to ESX, you will have to restore from tape or blow away the LUN as it will be unavailable. Good luck.

  15. Michael says:

    Hi Steve!!

    Thanks for the info!
    I just split the 4TB into two 2TB iscsi targets.
    That’s the only solution i think of.
    For now i’m running my esx smoothly..

    Have a nice day!

  16. Platypus says:

    So do you have any comments on what page 11 of VMware’s “Setup for Failover Clyustering and Microsoft Cluster Service” says:

    “The following environments and functions are not supported for MCSC setups with this release of vSphere:
    - Clustering on iSCSI, FCoE, and NFS disks.”

    This is for both vSphere v4.0 and v4.1.

    I am trying to implement a SQL Server 2008R2 failover cluster using vSphere v4.1 and and EMC CX4-240 SAN.

  17. efrain says:

    how would i get one of my existing VMs to see the iSCSI network label?

  18. Aron K says:

    Hi this seems like a good guide havent tried the instructions yet. What I want to know is will this guide help present the storageto the ESX hosts via iSCSI? if so good stuff those that have more info mail me arryquest@gmail.com

Leave a Reply

Powered by Sweet Captcha
Verify your real existence,
Drag the sticks to the drum
  • captcha
  • captcha
  • captcha
  • captcha

VMware vSphere Recommended Reads
TechHead Needs You - Top 25 Blog Sites
TrainSignal - vSphere Pro
AppAssure
Veeam #1
Trilead
StarWind Software