LVM Install Guide
This page is currently a work in progress
This tutorial will show you how to install Funtoo, including the rootfs, on logical volumes. This guide is meant to complement the regular Funtoo Installation Guide. It is recommended to open it in another tab, window ect.. and follow along with it as we will only be documenting the steps that are different or in addition to the regular guide.
Introduction to LVM
LVM (Logical Volume Management) offers a much more flexible way of managing your storage devices. Not only does it allow you to resize your volumes while the system is still up, it also frees you from having to decide exactly how many or how big volumes need to be at the time of installation.
For a detailed tour and introduction to LVM please consult the LVM Fun page.
Please read the Live CD section in the regular guide. The only thing you need in addition to the requirements it mentions is the sys-fs/lvm2 package or equivalent. If you use System Rescue CD, it includes the lvm2 package.
Prepare Hard Disk
Preparing the hard disk for an LVM install isn't much different from a normal install except that we won't be creating a bunch of partitions as we are going to use logical volumes instead. All we need is a /boot partition, if your using gpt, you'll need the GRUB partition, and the rest of the space will just be one big partition which we'll create our logical volumes out of.
We're using the previous mentioned setup to keep things simple in this guide. We are also assuming your only using one hard disk though LVM supports adding multiple hard disks and partitions to a volume group. Please adapt these instructions to suit your needs
The regular install guide does a good job explaining MRB, GPT, and gdisk/fdisk so we won't be repeating that here. Read through the Prepare Hard Disk section and create the previous mentioned partitions. If your following our setup your partition table should look like the following when completed:
GPT partition table
Command (? for help): p Disk /dev/sda: 83886080 sectors, 40.0 GiB Logical sector size: 512 bytes Disk identifier (GUID): A4E5208A-CED3-4263-BB25-7147DC426931 Partition table holds up to 128 entries First usable sector is 34, last usable sector is 83886046 Partitions will be aligned on 2048-sector boundaries Total free space is 2014 sectors (1007.0 KiB) Number Start (sector) End (sector) Size Code Name 1 2048 1026047 500.0 MiB 8300 Linux filesystem 2 1026048 1091583 32.0 MiB EF02 BIOS boot partition 3 1091584 83886046 39.5 GiB 8300 Linux filesystem
MRB partition table
Command (? for help): p Disk /dev/sda: 42.9 GB, 42949672960 bytes, 83886080 sectors Units = sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0x6919e82c Device Boot Start End Blocks Id System /dev/sda1 2048 1026047 512000 83 Linux /dev/sda2 1026048 83886079 41430016 83 Linux