Dnia 2010-08-07, o godz. 11:48:34
Florian Philipp <li...@f_philipp.fastmail.net> napisał(a):
> Hi list!
>
> I'm building a new Gentoo system (notebook) and want to rearrange a
> few things. I thought it would be good to have the following layout:
>
> - boot on a normal partition
> - root on a normal partition
> - one big encrypted partition (dmcrypt / LUKS)
> - on that partition an LVM volume group
> - on that volume group all stuff not necessary for booting: home,
> var, tmp, etc.
>
> AFAIK, the Gentoo boot process is organized so that LVM gets stated
> before dmcrypt is started. I would need it vice versa.
>
> Is that possible with baselayout-1? Do I need to switch to
> baselayout-2?
>
> Thanks in advance!
> Florian Philipp
>
I've made my own initramfs to boot.
/boot is a separate partition with ext2, grub, bzImage and
initramfs
/ is ext4 on logical volume on encrypted container
[ext4:lvm:luks:sda2]
swap is on another logical volume, next to /
I used two links as hints to build it:
http://jootamam.net/howto-initramfs-image.htm
http://jootamam.net/howto-basic-cryptsetup.htm
It's important to have all libraries copied to initramfs or to make all
binaries static (ldd). Some time ago I had dropbear in initramfs to
help booting headless server. Watch out for pivot_root restriction of
PID == 1.
--
Kacper Kopczyński