installer
installer copied to clipboard
Cannot boot from BTRFS subvolume
Describe the bug
I tried installing RC3 with BTRFS on SSD disk, but it failed to boot. The boot loader could not find files under /boot/ folder.
To Reproduce
- Run the installer and create custom partition
- A 512 MB FAT32 partition at the beginning of the disk
- Remaining disk as a BTRFS partition
- Follow the remaining installation steps, but shut down before it restarts to create the first user
- Boot again with the installation media and use it in demo mode
- Mount BTRFS partition somewhere in the demo session
- Create subvolumes
@,@home, and@swap - Move all the files into
@subvolume - Create a swapfile under
@swapsubvolume and set necessary flags so that BTRFS can treat it as a swap file - Modify the
/etc/fstabfrom the@subvolume so that/boot/efiis mounted to the FAT32 drive and/,/home, and/swapare mounted to their respective BTRFS subvolumes (with suitable options) - Create
/swapfolder under the@subvolume as a mount point for the swapfile under@swapsubvolume - Run
update-initramfs - Reboot the machine to complete the first user creation (this is where system fails to go any further from the boot screen)
Am I doing anything wrong? What am I missing? Do I need to manually reinstall GRUB or something?
Yes. You need manual grub install. http://logan.tw/posts/2015/05/17/grub-install-and-btrfs-root-file-system/
@queeup thanks. I was able to resolve the issue that day after a few tries. That said, it would be really cool if the installer could have better integrated support for BTRFS subvolumes to make the process more seamless. Without subvolumes, using BTRFS is not really all that useful. Moreover, the swapfile needs a different set of configs to behave properly, without polluting the history of the journaling file system.