Notes for my system:
- I couldn't get legacy boot to work. Only UEFI (using an EFI System Partition aka EPS).
- The EPS can't be on the RAID0. You must allocate ~200 megabytes to the EPS.
- KUbuntu installer was so buggy that I couldn't use it. Use Ubuntu to set up the system and then install
kubuntu-desktop
package. - When chrooting the EPS must be mounted on
/boot/efi
. - I recommend using Ubuntu 16.04 inside of virtualbox to create a startup boot disk on USB of Ubuntu 16.04 ISO. At first a tried using an earlier version of KUbuntu and it took a lot of trial/error to discover I shouldn't have done that.
Resources:
- http://askubuntu.com/questions/628258/unable-to-set-up-raid-during-kubuntu-15-04-installation
- http://askubuntu.com/questions/660023/how-to-install-ubuntu-14-04-64-bit-with-a-dual-boot-raid-1-partition-on-an-uefi
Boot the live disk and open a terminal; login to root
.
apt install mdadm grub-efi-amd64-signed
I'm using 4 SSD drives with device names sda, sdb, sdc, sdd.
Clear the partition tables.
for x in a b c d;do sgdisk -z /dev/sd${x};done
Configure sda
with partitions and copy the partitions to the rest of the devices.
sgdisk -n 1:0:+30M -t 1:ef00 -c 1:"EFI System" /dev/sda
sgdisk -N 2 -t 2:fd00 -c 2:"Linux RAID" /dev/sda
for x in b c d;do sgdisk /dev/sda -R /dev/sd${x} -G;done
Note: Sometimes when changing the partitions you may need to use
partprobe
to notify the kernel or reboot.
Create RAID0 array from disks. (from 4th partition on all disks)
mdadm --create /dev/md0 --level=0 --raid-disks=4 /dev/sd[abcd]2
Partition the RAID device.
sgdisk -z /dev/md0
sgdisk -N 1 -t 1:8300 -c 1:"Linux filesystem" /dev/md0
I found the installer unreliable unless I ran it as root.
sudo ubiquity -b
Choose manual partition during installation and...
- Set
/dev/sda1
to be EFI. /dev/md0p1
to be the/
partition formatted to EXT4 filesystem.- Boot Loader
/dev/sda
. - Reformat
/dev/sd[bcd]1
to be EXT4 rather than EPS so that there's only one EPS partition for the installation.
To keep it simple no advanced configurations such as LVM or disk encryption were used. That doesn't mean you can't.
Your installation needs at a minimum mdadm
package installed. Without it the system can't boot.
chroot
in:
mount /dev/md0p1 /mnt
mount /dev/sda1 /mnt/boot/efi
mount -o bind /dev /mnt/dev
mount -o bind /dev/pts /mnt/dev/pts
mount -o bind /sys /mnt/sys
mount -o bind /proc /mnt/proc
cp /etc/resolv.conf /mnt/etc/resolv.conf
chroot /mnt
Install missing packages inside of chroot.
apt install mdadm grub-efi-amd64-signed
Modify /etc/mdadm/mdadm.conf
and remove label references.
Reboot and enjoy.
KDE Neon
This is the latest up-to-date process for KDE Neon install (should also work for Ubuntu 18.04).
Some notes:
grub-install
the bootloader. It crashes because of thegrub-install
failure due to missing packages required for RAID.High level:
mdadm -As
/dev/md0p1
to be the/
drive of the install.mdadm grub-efi-amd64-signed
packagesgrub-install /dev/sdb
or whatever drive the EFI partition is located while inside of the chroot.Create RAID setup
Follow https://gist.github.com/samrocketman/9677ca29e0fbaab8f8e55ebc3039172a#gistcomment-1783179
Delete the duplicate EFI partitions
The EFI partition must be formatted (in this example
/dev/sda1
is the EFI partition).Reboot
Reboot the system and boot back into the live disk. After rebooting re-assemble the RAID array. As root, run the following.
Run through installer
But don't forget to chroot, install the packages, and the run
update-grub2
andgrub-install /dev/sda
.GRUB Recovery
Documented in How to Rescue a Non-booting GRUB 2 on Linux.
Getting a grub prompt but no Linux boot. Run the following commands to recover from the
grub>
prompt.List the known drives.
Check and verify the right disk.
Boot from grub (tab complete available)