1 |
On Thu, Aug 29 2013, Canek Peláez Valdés wrote: |
2 |
|
3 |
> As James said, the docs are being reorganized. However, I did a |
4 |
> systemd+LVM installation (just because I was getting tired of not |
5 |
> knowing what the fuss was all about), and (in my experience) there are |
6 |
> almost no changes from the regular installation in the handbook. |
7 |
> |
8 |
> I put everything in LVM (/, /boot, everything). |
9 |
|
10 |
I am not so ambitious. /+/boot+/usr one ext4 partition not on lvm |
11 |
|
12 |
> From my notes, the only changes are: |
13 |
> |
14 |
>>From the livecd: |
15 |
> 1. Use partitions, not whole disks (GRUB2 got confused when I tried to |
16 |
> use whole disks). |
17 |
> 2. Set the partition type as LVM (8e in fdisk). |
18 |
> 3. Create the Physical Volume, the Volume Group, and the Logical |
19 |
> Volumes as desired. |
20 |
> 4. Continue the normal installation, just using /dev/vg0/lvolX (or |
21 |
> whatever names you choose). |
22 |
|
23 |
There is a little more (activating or something the LVs) especially if |
24 |
you shutdown in the middle of the installation and resume it later. |
25 |
|
26 |
> After the chroot and emerging the kernel package: |
27 |
> 1. Se the LVM options in the kernel. Compile, install it. |
28 |
> 2. Emerge systemd. |
29 |
> 3. Emerge dracut (USE="device-mapper", DRACUT_MODULES="systemd lvm", at least). |
30 |
> 4. Set add_dracutmodules="systemd" in /etc/dracut.conf. |
31 |
> 5. Weirdly, set lvmconf="no" in /etc/dracut.conf. I didn't even |
32 |
> touched /etc/lvm/lvm.conf, so I think leaving it out makes dracut to |
33 |
> autoconfigure it. If I put lvmconf="yes", the boot hangs. Didn't |
34 |
> investigated why. |
35 |
> 6. Emerge GRUB2 (USE="device-mapper mount"); I don't know if GRUB |
36 |
> works with LVM, but GRUB2 does, so I used that. |
37 |
> 7. Set GRUB_PRELOAD_MODULES="lvm", |
38 |
> GRUB_CMDLINE_LINUX="init=/usr/lib/systemd/systemd", in |
39 |
> /etc/default/grub. |
40 |
> 8. Generate initramfs, generate /boot/grub2/grub.cfg, install GRUB2 |
41 |
> with grub2-install. |
42 |
> 9. Reboot. Everything works. |
43 |
> |
44 |
> GRUB2 handles LVM just fine, I believe, but my LVM setup was dead |
45 |
> simple (the VG was just the only partition of all my disks). |
46 |
> dracut+systemd takes care of everything else; I didn't even had to do |
47 |
> something special in fstab, since I used labels. |
48 |
> |
49 |
> To extend/reduce your Logical Volumes you will need a livecd, or a |
50 |
> more complex initramfs, though. |
51 |
> |
52 |
> Regards. |
53 |
|
54 |
I have experience with LVM, but not systemd or dracut or initramfs |
55 |
|
56 |
* both grub and grub2 support lvm |
57 |
* Never did 2,3,4,5,7, or the initramfs part of 8 |
58 |
|
59 |
My goal is to have this system (an older laptop) setup like my current |
60 |
laptop (grub2, openrc, root+/usr, etc). Then I will convert OLD to |
61 |
systemd. Once I have done this and moved my work from CURRENT to OLD, I |
62 |
will convert CURRENT to systemd and move back. |
63 |
|
64 |
thanks to you and james for your helpful comments. |
65 |
|
66 |
allan |