Vous êtes sur la page 1sur 11

Openfiler connection to VMware ESX Server

Part 1: Configuration of Openfiler.


I wanted to test an Openfiler as a solution for HA and vMotion with ESX Server and vCenter. Using Openfiler is a great way to save some money on expensive SANs and for home lab testing and learning, this choice is just great. I did not have 3 physical boxes (2 for ESX hosts and one for Openfiler) so I opted for a hybrid solution, where Im actually running one ESX server inside of VMware workstation. See the schema below. I was trying to do a step-by-step guide on how-to configure and run a successfull iSCSI connection with ESX Server.

There is box 1: In this box I will run ESX Server. It's a hardware compatible PC with Inte VT compatible Core 2 duo processor and local SATA drive. One NIC network card. 1 Gigabyte of RAM And box 2: Where I will run 2008 Server x64 with 8gigs of RAM and where I run VMware Workstation. Inside of WMware Workstation I will run Openfiler and a Second ESX server. Also there is a VM running 2003 DC as a DNS server. Like this I'll 'save' on one more physical box on which I would otherwise installed the second ESX Server. I've posted an article before which was based on a whitepaper from Xtravirt, about how-to run ESX Server on VMware Workstation., which is explaining what to do and how to create the ESX VM.

For an Openfiler I'll be using VMware Virtual Appliance that you can download here (x86 VMware Virtual appliance). If you want another version (like x64) or ISO image just go to this url and choose the version you need. I'll be using VMware Workstation to actually run the Openfiler Virtual Machine. I know the performances will not be excellent but to test all this stuff it'll be just fine. There is some good documentation about the actual architecture of Openfiler you can have look here.

Published by Vladan SEGET at www.vladan.fr

1.Add Second virtual hard disk to your VM


Before you first start your Openfiler VM, add a second virtual hard disk (as an SCSI hard disk). Like this Openfiler will detect this disk at startup and then you'll be able to use this disk for your data.

2. Start Openfiler VM
Then log In remotely via web browser to the ip address which was assigned via DHCP. You will see an image like this. Login with a "Openfiler" as a login and with "password" as a password.

Published by Vladan SEGET at www.vladan.fr

3. Then you need to configure Openfiler as a iSCSI target. What's this? Basicaly that Openfiler will be acting as a server.

First create physical volume. Go to Volumes and click on the link (see image below).

Then create a partition on this volume. Clic on /dev/sdb

Published by Vladan SEGET at www.vladan.fr

You will get onto a page which looks like this one... Click on the button Create. (if you are curious you can click to see on the drop down box...)

Then Create a Volume Group. Give it some name and click the button Add Volume Group

Published by Vladan SEGET at www.vladan.fr

Then add a volume at Volumes, then Add Volume.

You will then be directed to the page where you can fill the name for your iSCSI volume and also Description. You then must pull the button indicated with the slider bar to the right to specify how big the volume should be. Don't forgot to use the drop down box to select iSCSI as a type of volume.

4. Go to General Tab and edit the properties of the volume.


Just go to general tab and click on Network Setup. Now, fill in the IP adress of Openfiler VM, set the subnet mask, select Share, and then click on the button Update.

Published by Vladan SEGET at www.vladan.fr

5. Go and enable the iSCSI target


To be able to do that you must go to Services and click on a link to enable the iSCSI target.

Published by Vladan SEGET at www.vladan.fr

Part 2: How-to connect ESX Server to Openfiler iSCSI NAS.


Now that we are in the ESX 4 era we can test it in a lab environement with a iSCSI NAS freeware solution Openfiler. In the first part - how to configure OpenFiler iSCSI Storage for use with VMware ESX. You learned the hard part. That blogpost was a step-by-step procedure for a new persons coming to learn stuff about ESX Virtual environments and Openfiler is a great Linux distribution to play with as a storage for ESX Server. In the blogpost youll learn about the Openfiler configuration. Now there is the part when youll need to configure your freshly installed ESX/ESXi 4, or vSphere 4 if you like), to reach the shared storage where the openfiler is. 01.) Fire up the vCenter and go to Inventory > Configuration > Networking and in Networking click on Add Networking. You must add VMkerel to handle features like vMotion and HA.

02.) Use vSwitch0 for the test connection. If you have more than one NIC you can use another vSwitch. I had only one nic in my lab

As you can see there is a warning message saying that its Highly recommended to have separate VMKernel Port group and physical NIC. But nevermind, just go on For your lab its OK.

03.) Check the box Use this port group for Fault Tolerance logging and VMotion.

Published by Vladan SEGET at www.vladan.fr

04.) Set an IP adress for the VMkernel (Just choose a free IP in the same network) and fill the Default Gateway IP adress.

05.) Go to Configuration TAB and click on Storage Adapters.

06.) When you click on Properties, then you open firs the General TAB and enable the software initiator checkbox.

Published by Vladan SEGET at www.vladan.fr

07.) Then click on Dynamic Discovery TAB and add your Openfiler IP adress. In my case 192.168.0.16

08.) Then go to Configuration TAB > Storage > Add Disk/LUN. Published by Vladan SEGET at www.vladan.fr 9

09.) Your Openfiler NAS should already appear in the list.

10.) Check the box to maximize capacity of this storage.

11.) And you can browse the Datastore, copy paste files to and from -:)

You can subscribe to the news on the website and stay updated via RSS. Do want to learn some more about ESX Server? Do it the easy way (smart way) with Train Signal and their great video learning course. Get the best training course on ESX Server today. You can follow me on Twitter. or see me at Facebook.

Published by Vladan SEGET at www.vladan.fr

10

Published by Vladan SEGET at www.vladan.fr

11

Vous aimerez peut-être aussi