Document Actions
EVMS Notes
Notes on converting to EVMS on Gentoo Linux
Goals
- data assurance (RAID-1 mirroring)
- flexibility (resizing without reformatting)
Main resources
My configuration
- Shuttle XPC SK41G with AMD Athlon
- Gentoo Linux 2.6.14-r2
- Two internal hard drives, 250GB and 160GB, respectively
Desired partitions
- /dev/evms/boot
- 64MB, RAID-1
- /dev/evms/swap
- 2GB, RAID-0
- /dev/evms/root
- 80GB, RAID-1
- /dev/evms/home
- 230GB, Linear-RAID (backed up externally and remotely), consisting of the remaining space on both disks
Required steps
Emerge the following packages:
emerge evms
Then compile the kernel using genkernel. Be sure to compile MD and RAID support into the kernel:
genkernel --no-clean --menuconfig --gensplash=livecd-2005.1 --evms2 --bootloader=grub --install all
Device Drivers > Multi-device support (RAID and LVM)
[*] Multiple devices driver support (RAID and LVM)
<*> RAID
<*> Linear
<*> RAID-0
<*> RAID-1
<*> RAID-4/5
...
<*> Device mapper support
Finally, rebuild any affected modules:
module-rebuild rebuild
Notes
I had to set up the above-mentioned partitions incrementally so I could copy the existing data back and forth. I used the evmsgui for setting up the partitions.
- Convert /etc/fstab to EVMS based on existing partitions
- Create segments on new 250GB disk
- On the new disk, create Linear-RAID region with LVM2 container for /dev/evms/home (we will add the remaining segment on the old disk to this region later)
- Copy everything on the old disk to /dev/evms/home
- Reboot using /dev/evms/home as root in grub.conf
- Create fresh segments on old 160GB disk
- Set up the remaining three regions
- Populate /dev/evms/boot and /dev/evms/root
- Adjust /etc/fstab
- Reboot using /dev/evms/root as root in grub.conf
- Add the remaining segment on the old disk to the Linear-RAID region
