Mini-HOWTO: Disks and Partitions larger than 2TB under LINUX
using an Adaptec 2820SE RAID card 

Tilo Sloboda, March 2007

If you're just looking for information on creating large partitions >2TB under LINUX, then please skip to the second part.

Outline:


I built a couple of systems which use an Adaptec 2820SE 8-channel SATA card, and which use eight 750 GB SATA drives. Nice hardware, but how to configure it properly so that LINUX can handle partitions larger than 2TB? Some of the LINUX tools like "fdisk" or the native partitioning tools on Fedora Core or RedHat won't even work on a drive larger than 2TB..

RAID Card Firmware/BIOS

First I would recommend to upgrade your RAID controller to the latest firmware. In my case for the Adaptec 2820SE , that's BIOS V5.2-0 build number 11564.
Check the manufacturer's web-site and compare against what you have.

Kernel Driver for your RAID Card

Second, please double check if the manufacturer of your RAID card supports the LINUX distribution which you are using.. you may have to compile a driver yourself, and for that you will have to install the kernel-sources. e.g. the manufacturer does not support the Adaptec 2820SE card for Fedora Core.

I installed several Adaptec 2820SE cards on Fedora Core: FC4, FC5 and FC6.

On FC6 you don't need a special driver - the one coming with the distribution works.

For FC4 and FC5 I experienced that the systems hang randomly and without any error message if the system comes under load. The remedy is to install / compile the correct driver.

The kernel driver installation procedure for the Adaptec 2820SE is:

    1. download latest version of Dynamic Kernel Module Source Code from:
            http://www.adaptec.com/en-US/speed/raid/aac/linux/aacraid-dkms-1_1_5-2433_tgz.htm

    2. cd /tmp;
      mkdir aacraid-dkms-1.1.5-2433;
      cd aacraid-dkms-1.1.5-2433 ;
      tar -zxf ../aacraid-dkms-1.1.5-2433.tgz

    3. rpm -Uhv *.rpm

         NOTE: the source rpm places driver source contents in /usr/src/aacraid-1.1.5.2433
               in case manual build intervention is required.

    4. make sure the kernel sources are installed , e.g. "yum install kernel-devel"

    5. Use the various dkms commands to Build and install a driver:
      1. dkms add -m aacraid -v 1.1.5.2433
      2. dkms build -m aacraid -v 1.1.5.2433
      3. dkms install -m aacraid -v 1.1.5.2433

        Running module version sanity check.

        aacraid.ko:
         - Original module
           - Found /lib/modules/2.6.17-1.2142_FC4smp/kernel/drivers/scsi/aacraid//aacraid.ko
           - Storing in /var/lib/dkms/aacraid/original_module/2.6.17-1.2142_FC4smp/x86_64/
           - Archiving for uninstallation purposes
         - Installation
           - Installing to /lib/modules/2.6.17-1.2142_FC4smp/kernel/drivers/scsi/aacraid//

        depmod.....

        Saving old initrd as /boot/initrd-2.6.17-1.2142_FC4smp_old.img
        Making new initrd as /boot/initrd-2.6.17-1.2142_FC4smp.img
        (If next boot fails, revert to the _old initrd image)
        mkinitrd......

        DKMS: install Completed.


        this keeps backup copies of the old driver and the old initrd, in case something goes wrong you can revert.
    6. reboot!

LINUX with Partitions >2TB

Partitioning anything larger than 2TB is very problematic with the standard tools.

Although the kernels of FC4, FC5, FC6 all come pre-compiled and pre-configured with support for >2TB drives and partitions, a couple of system components have a 2TB limit:
The following system components do not have the 2TB limit:
So with a little planning and trickery you can create and use >2TB partitions.

Once you have your system running with the correct firmware/BIOS and the correct drivers, you need to decide if you want to use Software or Hardware RAID, and then you need to create and carve out the logical disk drives for your system, so you can install your OS and the data partitions

Carving out Logical Drives

I chose to use Hardware RAID6 on my Adaptec 2820SE, because it has a battery backup for it's cache, which gives it an advantage over using software RAID6, besides that the hardware RAID is also faster.

What worked best for me was to set-up all the Logical Drives as RAID6, distributed over the maximum number of physical drives (max spindles).