Setting up an iSCSI Target using open source software

By | March 14, 2009

Found out something interesting today that might apply to other brands
of RAID cards but I am talking about the 3Ware 9650 series here, I am
using this one – 3Ware 9650SE-8LPML, so for info, just in case you have
this function on your card and didn’t know about it.

These are multilane controllers which are pretty cool, less cables,
anyways, I was setting one up last week and I did the usual way. 8
ports available, usually you would do

2 x hdd for one RAID 1 for O/S
5 x HDD for one RAID 5 for data
1 Hotspare

I am using WD 750gb HDD, so I would have

750 gb for O/S (a complete waste of space) and about 3Tb for data.

Before you ask, yeah I could have used smaller drives but I needed to
use the Western Digital drives for a reason, they never get hot ! These
are the new Green Drives, they are truly amazing, and I had a bunch of
750Gb drives to use, so thats why I also used them for the O/S in RAID

Or if you were really greedy, a box we setup a few weeks back we did 10 x HDD inside one box

2 x 750Gb for O/S in software RAID attached to main board
7 x 750Gb RAID5 on 3Ware card for data – about 4.5Tb
1 x global Hotspare on RAID card.

Anyways, have been playing with this

the idea to make a box with 8 x 750Gb HDD into a big iSCSI device to attach to our Microsoft DPM backup box which is out of HDD space and out of PCI slots, it already has 2 RAID cards in it 🙂

I was looking on the forums at Openfiler and saw lots of references to the "boot volume" functionality in 3Ware cards, I remembered seeing this in the RAID setup but didn’t know what it was, so went back and set it all up again the right way, here is how it works.

Using 8 x 750Gb HDD either create 1 x RAID 5 or 1 x RAID 6 array, I used RAID 6 as it can support 2 dead drives and still work.

8 x 750 in RAID 6 = about 4.5Tb

At the end of setting up the single array you define the size of a "boot volume" I chose 50Gb, then what it does is it creates 2 logical volumes on the one RAID array, one of 50Gb which any O/S will see as sda or hd0 and the rest for data, 4.5Tb – 50gb = 4.45Tb. The advantage is obvious, your O/S is now on a RAID 6 volume as is your data, but using the same array, so in theory I can pull ANY 2 drives out of this array and it will keep working (will try that next week and let you know) I could have done my 10 drive system with 8 drives like this and got the same storage ! In fact I am going to rebuild it next week.

Then with Openfiler I set this up as an iSCSI target and connected to it from my Vista desktop to test. Vista has the MS iSCSI initiator built in, on Windows Server it is a free download and a cinch to install.

 Volume in drive G is iscsi1
 Volume Serial Number is 5019-9216

 Directory of G:\

14/03/2009  02:18 PM    <DIR>          test
               0 File(s)              0 bytes
               1 Dir(s)  4,445,864,783,872 bytes free

That’s a lot of bytes 🙂

So I now have a 4Tb volume that I can "attach" to any server (Windows or Linux) and to that server it will appear as a physical drive inside the machine I am attaching it to, much like the same way a SAN works, but much much cheaper 🙂 Openfiler does a lot more than this, it can be used NAS software as well. I tried FreeNAS but had issues with its iSCSI implementation.

The great thing about iSCSI is that there are clients for just about every O/S, I noticed when installing Centos last week it asked if you want to connect to any iSCSI targets during setup. Anyone knows of any other well tested open source iSCSI target software let me know, as far as I know Openfiler uses the open source Enterprise iSCSI Target Project software for the iSCSI part and is built on top of rPath Linux.

Leave a Reply