I have lvm2 in my system compiled w/o USE=static, so when genkernel create an initramfs for me it compiles lvm2 from sources and then uses cached binary. Recently I've discovered the following lines in /usr/share/genkernel/gen_initramfs.sh: 290 mv ${TEMP}/initramfs-lvm-temp/sbin/lvm.static ${TEMP}/initramfs-lvm-temp/bin/lvm || 291 gen_die 'LVM error: Could not move lvm.static to lvm!' 292 # See bug 382555 293 mv ${TEMP}/initramfs-lvm-temp/sbin/dmsetup.static ${TEMP}/initramfs-lvm-temp/bin/dmsetup || 294 gen_die 'LVM error: Could not move dmsetup.static to dmsetup!' 295 rm -rf ${TEMP}/initramfs-lvm-temp/{lib,share,man,include,{s,}bin/{lvm,dmsetup}} i.e. at line 295 lvm and dmsetup binaries (just moved from ${TEMP}/initramfs-lvm-temp/sbin/*.static) *would be removed* from ${TEMP}/initramfs-lvm-temp/bin/ directory!! so, final initramfs wouldn't contains that binaries at all and we'll get a unbootable system finally... The correct line should be: 295 rm -rf ${TEMP}/initramfs-lvm-temp/{lib,share,man,include,sbin/{lvm,dmsetup}} as it was in genkernel 3.4.30 Reproducible: Always Steps to Reproduce: 1.genkernel initramfs 2. 3. Actual Results: final initramfs have no /bin/lvm Expected Results: it must be there!
Confirmed. I am really lucky to always have a previous kernel+initrd around because current genkernel created an initrd for me that complains about missing vgscan and vgchange and results in an unbootable system.
Sh***, you're right: http://git.overlays.gentoo.org/gitweb/?p=proj/genkernel.git;a=commitdiff;h=9f36ecc125bf2c20bd28c0ad513577a858140a77
This should help: http://git.overlays.gentoo.org/gitweb/?p=proj/genkernel.git;a=commitdiff;h=9743f8b39c6050746d7ff1949fc98999a847c4f9 +*genkernel-3.4.32 (14 May 2012) + + 14 May 2012; Sebastian Pipping <sping@gentoo.org> -genkernel-3.4.30.ebuild, + -genkernel-3.4.31.ebuild, +genkernel-3.4.32.ebuild: + Bump to 3.4.32 (bug #415697), remove broken 3.4.30 and 3.4.31 + Sorry for the trouble. Please re-open as needed.
Problem persists, since helper symlinks (i.e. vgscan and vgchange) actually end up in /sbin, and those symlinks link to 'lvm', without path. Solutions might include: a) copy/symlink /bin/lvm to /sbin/lvm b) move /sbin/* lvm symlinks to /bin c) update symlinks to link to /bin/lvm To check that, build initramfs and then mount image somewhere.
(In reply to comment #4) > Problem persists, since helper symlinks (i.e. vgscan and vgchange) actually > end up in /sbin, and those symlinks link to 'lvm', without path. I don't see any symlinks for vgscan/vgchange nor any use of these in latest genkernel. Please let me know how and where you found it. Also, you can find me as "sping" on freenode IRC right now if you like.
Forget that, my mistake. Seems like I had to clean /var/cache/genkernel before assuming a bug.