A while back I discussed reasons for setting up a home FreeNAS server. After setting up FreeNAS, copying (and verifying) close to 2TB of user data to it, and hooking FreeNAS into the MacOSX Lion Server LDAP, turns out that the MacOSX clients weren't entirely happy with home folders served from it using the FreeNAS Apple Filer Protocol (AFP) clone, netatalk. Some apps would run painfully slowly while others just wouldn't run at all. After some research, I decided to dive deeper into the abyss and set up a Storage Area Network (SAN) in the house: FreeNAS would serve home folders as block devices via iSCSI to the MacOSX Lion Server, which would in turn serve home folders via AFP using the official Apple AFP implementation built into MacOSX Lion. While this may sound like so much gibberish, I became a man possessed.

The first step was kind of simple. FreeNAS with ZFS supports the creation of block devices that can be served up via the iSCSI protocol (all built into FreeNAS!). Easy peasy!

The second step got tricky: there's no free lunch for the client side (formally known as the initiator) of iSCSI for the Mac. Having already decided that I was "all in" on this solution, I purchased the Globalsan Initiator. That turned out to be money well spent. Installation was easy, and it...is...rock...solid! The beautiful thing about iSCSI is that the initiator mounts the block device from the server and it appears as though it's a standard drive with a native MacOSX file system. Perfect!

I initially thought each Mac could mount the user's home folder via iSCSI, but soon realized that this is what is known as a bad idea and causes lots of problems. Turns out that it's not a good idea to concurrently mount the same block device from multiple machines...who knew? At this point and after much research, I settled on the idea of using iSCSI between the FreeNAS and the MacOSX Lion Server, and from there distributing home folders to the Macs using AFP. The hard work of setting up iSCSI was already done, distributing those via AFP is a normal MacOSX Server thing to do and is therefore pretty simple with the Server tools.

So, does it work? Well, my kids and I can log in on any machine and have fully functional access to our home folders. Spotlight seems to be working normally. Performance of iBank is now back to normal. In fact, I'm getting 60-80MBps performance which is pretty good considering all of these hops over a 1Gbit ethernet backbone. The data is still hosted on ZFS partitions on the FreeNAS server with all of its attendant reliability features.

All in all, I'm pretty happy at this point. Time to find another challenge.