File server finally done

I was finally able to get all my drives into my file server and get the array fully upgraded. First, the results:

# df -h /dev/md0Filesystem            Size  Used Avail Use% Mounted on/dev/md0              1.8T  742G  1.1T  41% /mnt/storage# df -H /dev/md0Filesystem             Size   Used  Avail Use% Mounted on/dev/md0               2.0T   796G   1.2T  41% /mnt/storage

Yeah! 2TB!

Now: the process. I had previously mentioned that I was awaiting a 400G drive to return from RMA, well I received that one in the mail only to have a 250G drive fail. So I RMA'd that one and finally got it back yesterday.

I was able to find out (empirically) that my Silicon Image (SiI) 3132-based PCI-e support hot-swap. I was able to pull out the 250G drive and reinstall it without any problems. That's a good start.

The next step was to grow the raid array; this took about about 18 hours, but was done while the array was completely online, mounted, and being used. The command to perform this was very simple:

# mdadm --add /dev/md0 /dev/fake400G/lvol0# mdadm --grow /dev/md0 --raid-devices=6

The first line was to add the new device to the raid array as a spare, the second one expanded the number of members in the array from 5 to 6. The output of `cat /proc/mdstat` then showed that it was reshaping.

This morning I woke up to a reshaped array with 400G more space, but no more space in my filesystem. Another command takes care of this (also while online):

# resize2fs /dev/md0resize2fs 1.39 (29-May-2006)Filesystem at /dev/md0 is mounted on /mnt/storage; on-line resizing requiredPerforming an on-line resize of /dev/md0 to 488385920 (4k) blocks.The filesystem on /dev/md0 is now 488385920 blocks long.

This one appeared to have a little more impact on things accessing the array; I experienced some stuttering while I was watching live TV, but this part of the process only took about half an hour. It's neat to have a graph of your array growing in size without gaps.