TL;DR; This Document contains the necessary steps to setup RAID, ENCRYPTION and LVM before installing ubuntu.
OS: Ubuntu 14.04.1 LTS
Installation Date: 22. January 2015
Some additional links I used during the installation:
Create raid: http://archive.is/gij6M
Configuration: http://archive.is/UPDKc
LVM: http://archive.is/xhDme
Encryption: http://archive.is/ykimV
Choose No when asked if you want to encrypt your homedirectory.
When asked about the partitioning method choose manual:

If there are any partitions, volume groups or raids just delete theem (I hope you know what you’re doing)
I just see two disk with 1.0 TB free space each
Partitioning
Select first harddrive and press enter. if you are asked whether you want to create a partition table: agree. Otherwise choose “Create a new partition”
- Size: 1.0GB
- Location: Beginning
- Type: primary
Partition Settings:
Use as: “physical volume for RAID”
Bootable flag: on
Create second partition with the rest of the space.
- choose the line with “FREE SPACE” and press enter
- Create a new partition
- use the rest of your disk as partition size (999.2 GB in my case)
- Type: primary
Settings:
Use as: “physical volume for RAID”
Bootable flag: off
Do the exact same steps for the second harddisk.
You should now have two partitions per harddisk. Both partitions are primary and the first partition (the smaller one) has the bootable flag set to on.
RAID configuration
You should now be at the “Partition disks” screen. Below you see all partitions and on top there’s the menu.
- in the menu open “Configure software RAID”
- when asked if you want to write the changes down to the disks say Yes
- “Create MD device”
- choose the RAID type. i want redundancy, so RAID1
- Number of active devices for the RAID1 array: 2 (we don’t have mor disks anyway…)
- Number of sparce devices for the RAID 1 array: 0
- Mark the two partitions that belong to this MD device.
- we’ll use the first MD device to boot, so:
- mark the two smaller (1GB) partitions
- (probably /dev/sda1 and /dev/sdb1)
- when back in the software RAID menu continue the steps above and create a MD device for the bigger partition
- Finish the software RAID configuration and return to the partitioning menu
LVM and boot partion
We are now back in the partitioning menu. you should now see something like this:
- the two disks with its two partition
- a line RAID1 device #0
- a second RAID1 line device #1
Boot partition
- choose the first RAID1 device (the smaller one)
- set “Use as” to EXT4
- set “Mount point” to /boot
- “Done setting up the partition”
LVM
- choose the second RAID1 device
- set “Use as” to “physical volume for LVM”
- “Done setting up the partition”
Configure LVM
we’re now back in the partition menu again. one raid device is now set to mount to /boot and the other one is set to “lvm”
- open the “Configure the Logical Volume Manager” menu
- allow the partitioner to write the changes to disk
- “Create volume group”
- Choose a Volume group name. I chose the systems hostname (“micro”)
- Select the device that should be used for this volume group. In our case that’s the bigger one (/dev/md1 in my case)
- Back at the “LVM configuration” menu choose “Create logical volume”
- choose the previously created volume group
- enter a volume name. I’ll use this volume for swap, so I chose “swap”
- choose the size of your swap partition. I chose 4GB
- we’re now back in the “LVM configuration” menu again. once more “Create logical volume”
- choose the previously created volume group
- choose a name. we’ll install the root filesystem here, so I chose “root”
- use all remaining space for this volume (so, just press enter)
- Finish the “LVM configuration” and return to the partitioning screen
Encryption
So far we’ve created the partitions, setup a RAID1 and create two LVM volumes. “swap” for the swap partition and “root” for the rootfs. As a last step well setup the encryption. rootfs will be encrypted with a password that you choose. swap will be encrypted with a random key at every boot (it’s overwritten anyway).
prepare swap volume for encryption
- choose the smaller LVM volume (the one with 4GB in my case. in my case it has the name “swap”)
- set “Use as” to “physical volume for encryption”
- set “Encryption key” to “Random key”
- “Done setting up the partition”
prepare the “root” volume for encryption
- choose the other LVM volume (in my case it’s named “root”)
- set “Use as” to “physical volume for encryption”
- make sure that “Encryption key” is set to “Passphrase”
- Done setting up the partition
configure encryption
we’re again back in the partitioning menu. by now we should have two lines marked with “crypto” and “not active”.
- open “Configure encrypted volumes” in the menu
- “Create encrypted volumes”
- chose the two devices that we want to encrypt (in my case micro-root and micro-swap with “micro” being the volume group name and “root” / “swap” being the volume names)
- Back at the encrypted volumes configuration screen choose “Finish”
- You are now asked for the encryption password. This is the password that you’ll need to enter at every boot. Make sure you type it right and that it’s safe enough.
- you’re now back in the partitioner. the comment “not active” should now longer be shown as a comment for the “crypto” devices
set mountpoint for rootfs
- choose the bigger encrypted device
- set “Use as” to EXT4
- set “Mount point” to
- “Done setting up the partition
enable swap
- choose the smaller encrypted volume (in my case it has the name micro-swap_crypt)
- set “Use as” to “swap area”
- “Done setting up the partition”
Verify the configurations
We are now back in the partitioner. By now you should have:
- an encrypted volume with ext4 and mountpoint to /
- an encrypted volume that will be used for swap
- RAID1 device with ext4 and mountpoint /boot
- and all the other lines (the physical partitions, the disks, the second raid device for the LVM)
If everything looks find and all mountpoints are set choose “Finish partitioning and write changes to disk” at the bottom of the screen. Agree to write the changes to the disks.
continue with the installation