Recently I bought a Dell T320 to be used as a Home-NAS (on steroids 😜 ). The plan was to run TrueNAS on it and as the T320 I bought on eBay already came with a Dell H310 RAID-controller…well, you know what happened, because that’s why you are here 🧐
How I started?
I knew that TrueNAS and ZFS work best with HBA’s and don’t like RAID-controllers as the redundancy etc. is handled by the filesystem. And in addition I knew that there are ways to crossflash a RAID-controller to IT-mode. You can buy cheap and used H310 cards on eBay and with a small extra also flashed to IT-mode – but if you already have a card or want to do it on your own…here we go 😃
Why flashing a RAID-controller?
For those who don’t know, a very short description. A hardware RAID-controller usually manages the different disks and the read/write operations onto the disks (e.g. mirror and/or split data to different disks). ZFS does this in software and works best if the operating system (in my case TrueNAS) has direct access to the disks without any interference. A hardware RAID-controllers in it’s original configuration would do such an „interference“ – but some can be flashed with a different firmware to just run as a HBA (Host-Bus-Adapter).
So the hardware RAID-controllers are shipped with a firmware for IR-mode where the drives itself are usually not exposed separately to the OS. We want to flash it to IT-mode (Initiator Target) which disables the RAID-functionality and just passed the drives through to the OS. The IT-mode firmware is the one from the chip-manufacturer (LSI).
Which one to choose…
One „famous“ card is the Dell H310 which uses the LSI 9211-8i Chip. There are also other which use the same chip like the IBM M1015 or the IBM M1115, but some are more or less supported by the community with tutorials how to reflash the cards and e.g. in my case also the hardware layout was one reason to go for the H310.
…and why?
The H310 has the ports at the end of the card and the IBM cards usually have them at the beginning – as I did not want to buy new cables which are long enough I went for the H310.
So how do I do it now?
I did some research and found some websites, tutorials, forums and downloads – I will link them at the end for reference.
In general it’s quite easy. On one of the forums a user named „Fireball3“ has put together a package which serves you with all what is required and in addition invested some time in providing some scripts which do everything what is required. Link below.
Overall there are some preparations required (create a bootable FreeDOS USB-stick), then copy the package with the script to that USB-stick and then boot from it and follow the instructions provided in the package. The provided ReadMe covers everything you need, that’s why I will not repeat everything here (If you still want to know what’s done in detail take a look at the scripts or there are also many discussions on the web). Once you have executed all 6 scripts, you are ready to go (assuming everything succeeded 🎉🤞).
A few remarks
- When you boot FreeDOS from the USB-stick, it will ask you if you want to install it or just want to continue in DOS-mode. Select the option to continue in DOS-mode, that’s fine.
- I have used version 4 (hope the link still works, otherwise check out the link at the end for the forum post, there you might find an even newer update) of the mentioned package. In script #2 (2.bat) I received a message that ‚product id and vendor id do not match‘ but that was fine in my case. In addition I had to manually re-assign the SAS address – but that is documented in the ReadMe and also mentioned in script #6 (6.bat). So all in all it took me about 15-20 minutes and most time was waiting and one necessary reboot.
- If you want to boot from a disk connected to the controller you need the BIOS on the card (requires a manual change in one of the scripts).
- If you don’t want to boot from one of the disks connected to the controller you can speed up the boot time of your machine by just not flashing a BIOS to the card – works fine, but you will not see any disk in the mainboard BIOS and boot selection.
Forum post by Fireball3 with the links to the Flash-Package download
Detailed info about flashing a H310 card and some additional details (German)