Also, I only created the swap in case I need it sometime and btrfs does not support swapfiles. Disk 1 has the same, but no boot partition. The remaining Disk 0 space is divided between 2 partitions which are later used for the MD arrays that become "/" and "/swap". The bootloader is then installed here so the OS can start and then mount the RAID. During installation I told the installer this was to be mounted at "/boot" and I set the bootable flag. Disk 0 has a 500mb primary partition of ext3fs. Though I don't see this in a quick scan of the ubuntu 14.04 instructions, I had to create an additional primary partition that is NOT part of my raid arrays. I can tell you that my "hdd" (hehe) lights go nuts for 10-20 minutes when the weekly cron job runs but the OS responsiveness is almost completely unaffected. I use the second.ĭoes it matter? Supposedly, the online discard (using the mount option) is not wonderfully implemented and is slow so it's "not recommended". The difference between doing this and running it via cron is that the first will trim/discard on-the-fly and the second will do it in a lump on a schedule. It's arguably unnecessary thanks to overprovisioningġ4.04 is the first release to enable TRIM support out-of-the-box but it's trivial to enable on previous distributions, provided you are using kernel 2.6.33+.ĭepending on your chosen filesystem, you can enable trim/discard by editing your fstab and setting the appropriate mount option. Fdisk will lie about alignment.įurther reading: I think Btrfs can even create its own raid arrays.
You can do this from a command prompt within the installer or from a live usb/disc before you attempt installation. You must also manually align partitions (on any multi-partition setup, raid or not) on the SSDs BEFORE booting to the installer because depending on the page size of your SSD, only the first partition will be properly aligned (it took me a while to catch it) and this can severely impact drive lifespan.
The 3.8 kernel is required if you want to use compress=no as a Btrfs mount option and may also be required for use of fstrim, the manual trim command used for scheduled trim. My extra Btrfs mount options from fstab: defaults,ssd,ssd_spread,space_cache,compress=no,noatime I'm running Ubuntu 12.04.5 with the 3.8 kernel on an MD RAID0 configuration and the SSD-friendly Btrfs filesystem. Following here are some important gotchas and details I had to discover the hard way, through personal experience: Instructions for RAID configuration on 12.04.x are identical, but this tutorial using 9.10 has pictures. The short answer to "Can I RAID SSDs and boot from them" is "Yes!".
I know I'm being a Johnny-come-lately to this question but I'd like to see if I can shed some light on this for anyone searching.