How to Build vSphere Infrastructure on Windows Server 2008 R2 vStorage -Part4

How to Build vSphere Infrastructure on Windows Server 2008 R2 vStorage

In this article, I’m going to show you How to Build vSphere Infrastructure on Windows Server 2008 R2 vStorage. In my previous posts, I explained that how to make domain controller, vCenter Server and Install vCenter Server. Once we’ve done those steps then it’s time to build virtual storage to store our data and VMs on the shared storage.

What’s vStorage?

vStorage is a virtual storage that you can store your data inside in Virtual Environment. In fact, it’s shared storage among your ESXi hosts which is really good for high availability, fault tolerance, redundancy and vMotion. When you create vStorage and you share it with you All ESXi hosts. When one of the ESXi host shutdown or breakdown then all your VMs automatically transfer to your another ESXi host by the help of High Availability. If you don’t have HA feature on your vSphere Server, then the transfer process won’t work.

For the sake of this demonstration, I’ll use iSCSI target software to build up a shared storage so you can use lefthand, UberVSA or OpenFiler.

How to Build vSphere Infrastructure on Windows Server 2008 R2 vStorage

Data Store Diagram

Let’s get started to create vStorage on our vCenter server. Follow the guide step by step to avoid any error or mistakes.

Note: Do not start your VMs yet especially ESXi hosts.

Build vSphere Infrastructure on Windows Server 2008 R2 vStorage

Before you start your VMs add a new Hard Disk (minimum 200GB) to your VC VM. Also, add 1 network Adapters on your VC machine.

Step #1. Go to your VC VM Setting and click on Add. Select the Hard Drive and click Next.

How to Build vSphere Infrastructure on Windows Server 2008 R2 vStorage

Add new Hard Drive to VC VM

Step #2. Select SCSI > Create a new virtual disk > Store virtual disk as a single file > Finish.

How to Build vSphere Infrastructure on Windows Server 2008 R2 vStorage

Adding New HDD to vCenter Server

Step #3. Now add a new network adapter to your VC virtual machine. Follow the same process as you added a new hard drive but this time select Network Adapter from Hardware Type. Your network Adapter should be VMnet3.

How to Build vSphere Infrastructure on Windows Server 2008 R2 vStorage

Add Network Adapter to VC VM

Initialize New Hard Drive

Initialization is a very easy process. When you add a new hard drive to your PC or VM then by default it doesn’t show up on your file explorer so you need to initialize it.

Assign IP Address

In step #3. You’ve added three network Adapter so you need to Rename vmnet3 to iSCSI and assign an IPV4 address. If you’re following my labs, then you should assign 10.0.1.3/24 IP address to the iSCSI network adapter.

How to Build vSphere Infrastructure on Windows Server 2008 R2 vStorage

Assign IP Address to iSCSI Network Adapter

Download & Install Microsoft iSCSI Software Target

Once everything is done up to this stage then it’s time to Download and install Microsoft iSCSI software target. Once you’ve downloaded the software, drag and drop it into your vCenter VM.

Step #1. Extract it and navigate to X64/iscsitarget_public.msi. Double click on iscsitarget_public and install the software. Set everything to default and just click Next and Next.

How to Build vSphere Infrastructure on Windows Server 2008 R2 vStorage

Extract iSCSI Software Target

How to Build vSphere Infrastructure on Windows Server 2008 R2 vStorage

Install iSCSI Software Target

How to Build vSphere Infrastructure on Windows Server 2008 R2 vStorage

Install Microsoft iSCSI Software Target

Step #2. Open the Microsoft iSCSI Software target console.

How to Build vSphere Infrastructure on Windows Server 2008 R2 vStorage

Open iSCSI Target Console

Right-click on Microsoft iSCSI software target and select Properties. Enable only IP 10.0.1.3 to listen for iSCSI sessions.  This ensures we only use the dedicated iSCSI network (VMnet3).

How to Build vSphere Infrastructure on Windows Server 2008 R2 vStorage

iSCSI Target Properties

Step #3. Right click on Devices and select Create Virtual Disk.

How to Build vSphere Infrastructure on Windows Server 2008 R2 vStorage

Create Virtual Disk

Step #4. If you remember we’ve added a new hard drive to our VC VM and initialized with letter E: so now you’ve to point your data storage to that drive. Simply type E:\iSCSI\DataStore1.vhd and it’ll create a storage by the name of DataStore1.

How to Build vSphere Infrastructure on Windows Server 2008 R2 vStorage

Choose Virtual Disk Path

Step #5. Your hard drive should have around 200GB so you need to split it in half. Just type 95000 (95 GB) and click next.

How to Build vSphere Infrastructure on Windows Server 2008 R2 vStorage

Specify Disk Size

Create a second virtual disk and name it Datastore2.vhd. Repeat step #4 and #5 and create another data store.

How to Build vSphere Infrastructure on Windows Server 2008 R2 vStorage

Virtual Hard Disk is Created

Connect ESXi Host to vStorage

Step #1. If you’ve already started your ESXi hosts then you need to shut down all and Add 2 Network Adapters to each. Put your network adapters on VMnet3 to communicate with your iSCSI storage.

How to Build vSphere Infrastructure on Windows Server 2008 R2 vStorage

Add Network Adapter to ESXi Hosts

Step #2. Power on the ESXi1 and ESXi2 hosts. Open your vSphere Client and select ESXi1. Go to Configuration> Networking and click Add Networking to add a new switch. Select VMKernel as the type and click Next.

How to Build vSphere Infrastructure on Windows Server 2008 R2 vStorage

Create a New VMkernel

Step #3. Under “Create a vSphere standard switch” select vmnic2 & vmnic3 and click Next.

How to Build vSphere Infrastructure on Windows Server 2008 R2 vStorage

Create new VMKernel

 

Step #4. Name it iSCSI_1 and click Next.

How to Build vSphere Infrastructure on Windows Server 2008 R2 vStorage

Name iSCSI_1

Step #5. Use the IP 10.0.1.10 with the subnet mask of 255.255.255.0. Click Next and Finish.

How to Build vSphere Infrastructure on Windows Server 2008 R2 vStorage

Set IP Address

Step #6. Open the Properties of Swtich1 and select Add.  Select VMkernel and click Next.

How to Build vSphere Infrastructure on Windows Server 2008 R2 vStorage

Switch1 Properties

Step #7. Now we’re creating another VMkernel to our switch1 and this time name it iSCSI_2.

How to Build vSphere Infrastructure on Windows Server 2008 R2 vStorage

Name iSCSI_2

Step #8. Use the IP 10.0.1.11 with the subnet mask of 255.255.255.0.

How to Build vSphere Infrastructure on Windows Server 2008 R2 vStorage

Assign IP Address

Step #9. Change the NIC Teaming Failover order of both iSCSI_1 & iSCSI_2.  Set vmnic2 active for iSCSI_1 where vmnic3 becomes unused.  Change it the other way around for iSCSI_2.

How to Build vSphere Infrastructure on Windows Server 2008 R2 vStorage

override Switch Failover Order

Step #10. On your ESXi1 host under Configuration tab > Storage Adapters add a new storage Adapter.

How to Build vSphere Infrastructure on Windows Server 2008 R2 vStorage

Add Storage Adapter to ESXi Host

Tip: if you are using ESXi4 then the iSCSI adapter is already added and you need to enable it under Properties.

Step #11. Go to the newly added iSCSI HBA (vmbha33) and click Properties. Copy the iSCSI Name (you can change this name to something more readable if you want).

How to Build vSphere Infrastructure on Windows Server 2008 R2 vStorage

Copy the IQN Name

Step #12. Get back to the Microsoft iSCSI Software Target console. Right click on iSCSI Target and select Create iSCSI Target.

How to Build vSphere Infrastructure on Windows Server 2008 R2 vStorage

Create iSCSI Target

Step #13. Name it ESXi1.wikigain.com (you can select your domain) and click Next. Now Paste IQN Identifier that you copied in step #11.

How to Build vSphere Infrastructure on Windows Server 2008 R2 vStorage

Paste IQN Identifier Number

Step #14. Now that the Target is created, let’s assign our two LUNs to it.  Right-Click it and select Add Existing Virtual Disk to iSCSI Target. Select both Virtual Disks and click OK.

How to Build vSphere Infrastructure on Windows Server 2008 R2 vStorage

Add Existing Virtual Disk to iSCSI Target

Step #15. Now let’s go back to our vCenter and select iSCSI HBA (vmhba33) and click Properties. Under Network Configuration tab click Add.

How to Build vSphere Infrastructure on Windows Server 2008 R2 vStorage

HBA Properties

Step #16. Add both iSCSI_1 and iSCSI_2 to the HBA.

How to Build vSphere Infrastructure on Windows Server 2008 R2 vStorage

Add Virtual Disks to iSCSI Target

Disks are Added

Step #17. Once you’ve added iSCSI_1 and iSCSI_2 then go to Dynamic Discovery tab and click Add. Now add 10.0.1.3 as a new iSCSI Target.

How to Build vSphere Infrastructure on Windows Server 2008 R2 vStorage

Dynamic Discovery

Close the Window and Rescan the vmhba33 adapter. Your 2 LUNs should appear and it should be 4 paths meaning 2 per LUN.

How to Build vSphere Infrastructure on Windows Server 2008 R2 vStorage

HBA Properties

Step #18. Under ESXi1 host go to Configuration > Storage. Click Add Storage. Go according to the following settings.

  • Storage Type: Disk/LUN
  • Disk/LUN: MSF ISCSI Disk 0 / 1
  • File System: VMFS-5
  • Data Store name: iSCSI1
How to Build vSphere Infrastructure on Windows Server 2008 R2 vStorage

Ready to Complete Adding Storage

Note: Repeat this step once again and create another Storage and name it iSCS2.

Your Final work should look like the snapshot below.

How to Build vSphere Infrastructure on Windows Server 2008 R2 vStorage

vStorage is Created

Open the Properties of your Cluster and enable vSphere HA if it’s not enabled.

Tip: If you’ve got any error then your shared storage is not configured correctly.

Important Notice: We’ve only connected our ESXi1 to the shared storage and you should exactly followConnect ESXi Host to vStorage” steps to ESXi2. For ESXi2 use the following IP addresses and Name.

  • Step #5. IP Address: 10.0.1.20/24
  • Step #8. IP Address: 10.0.1.21/24
  • Step #13. ESXi2.wikigain.com
  • Step #17. Same IP of ESXi1 (10.0.1.3)
How to Build vSphere Infrastructure on Windows Server 2008 R2 vStorage

ESXi2

How to Build vSphere Infrastructure on Windows Server 2008 R2 vStorage

Create Virtual Disk ESXi2

Other steps are the same so do not skip any step including notes and tips because every step is very important.

Conclusion

In this guide, I’ve shown you how to Build vSphere Infrastructure on Windows Server 2008 R2 vStorage step by step with screenshots and for more clarification just see the following objectives.

  • Initialize a New Hard Drive
  • Assign IP Address to iSCSI Network Adapter
  • Download & install Microsoft iSCSI Software Target
  • Connected ESXi Hosts to vStorage

I hope you guys have learned something useful from this post and if you stuck at any step just let us know via comment section down below this post.

Next GuideHow to Build vSphere Infrastructure on Windows Server 2008 R2 VMs

blank

Mukhtar Jafari is the founder and CEO of wikigain.com. He is CISCO CCENT & CCNA Certified and has got his diploma in IT Networking from North Metro TAFE PERTH. He is currently working as a Help Desk Technician at DEEPTECH Perth Western Australia. In addition, he loves helping other tech enthusiasts so he is working part-time on wikigain.com. He shares his experience through this website for IT beginners.

Leave a Reply

Your email address will not be published.

This site uses Akismet to reduce spam. Learn how your comment data is processed.