Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 674486 - kernels built with lvm2-2.02.183 by genkernel-next fails to boot
Summary: kernels built with lvm2-2.02.183 by genkernel-next fails to boot
Status: RESOLVED WONTFIX
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: AMD64 Linux
: Normal normal (vote)
Assignee: Ettore Di Giacinto (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-01-04 10:34 UTC by Mariusz Ceier
Modified: 2021-02-01 16:25 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Mariusz Ceier 2019-01-04 10:34:40 UTC
All kernels built by genkernel-next with lvm2-2.02.183 installed stop at:

    random: lvm: uninitialized urandom read (4 bytes read)
    random: crng init done


Kernels built with lvm2-2.02.145-r2 installed, boot normally:

    random: lvm: uninitialized urandom read (4 bytes read)
    random: lvm: uninitialized urandom read (2 bytes read)
    random: crng init done
    EXT4-fs (dm-1): mounted filesystem with ordered data mode. Opts: (null)
    ...


Tested with kernels >=4.20.0 (released as well as git versions)

I think it's critical issue - it prevents system from booting unless someone has  many kernels installed.


Reproducible: Always

Steps to Reproduce:
1. Install =sys-fs/lvm2-2.02.183
2. Use genkernel-next to build the kernel, e.g.: genkernel --makeopts=-j8 --menuconfig --firmware --lvm --busybox all
3. Add kernel to the bootloader and reboot computer - system hangs during boot

4. Install =sys-fs/lvm2-2.02.145-r2
5. Use genkernel-next to build the kernel, e.g.: genkernel --makeopts=-j8 --menuconfig --firmware --lvm --busybox all
6. Add kernel to the bootloader and reboot computer - system boots normally
Actual Results:  
Hang during boot - looks like kernel tries to run the initramfs and initramfs has trouble mounting root filesystem. There are no error messages.



Expected Results:  
System should boot without issues - initramfs should mount root filesystem and start systemd.



Portage 2.3.53 (python 2.7.15-final-0, default/linux/amd64/17.0/systemd, gcc-8.1.0, glibc-2.28-r4, 4.20.0 x86_64)
=================================================================
System uname: Linux-4.20.0-x86_64-Intel-R-_Core-TM-_i5-6600_CPU_@_3.30GHz-with-gentoo-2.6
KiB Mem:    32893236 total,  30803764 free
KiB Swap:   16519164 total,  16519164 free
Timestamp of repository gentoo: Wed, 02 Jan 2019 11:30:01 +0000
Head commit of repository gentoo: 3df596d62c4acc8e63139433ac8241b93931bd8a
sh bash 4.4_p23
ld GNU ld (Gentoo 2.31.1 p5) 2.31.1
app-shells/bash:          4.4_p23::gentoo
dev-java/java-config:     2.2.0-r4::gentoo
dev-lang/perl:            5.26.2::gentoo
dev-lang/python:          2.7.15::gentoo, 3.6.6::gentoo
dev-util/cmake:           3.13.2::gentoo
dev-util/pkgconfig:       0.29.2::gentoo
sys-apps/baselayout:      2.6-r1::gentoo
sys-apps/sandbox:         2.14::gentoo
sys-devel/autoconf:       2.13-r1::gentoo, 2.69-r4::gentoo
sys-devel/automake:       1.16.1-r1::gentoo
sys-devel/binutils:       2.31.1-r3::gentoo
sys-devel/gcc:            8.1.0-r3::gentoo, 8.2.0-r6::gentoo
sys-devel/gcc-config:     2.0::gentoo
sys-devel/libtool:        2.4.6-r5::gentoo
sys-devel/make:           4.2.1-r4::gentoo
sys-kernel/linux-headers: 4.20::gentoo (virtual/os-headers)
sys-libs/glibc:           2.28-r4::gentoo
Repositories:

gentoo
    location: /usr/portage
    sync-type: rsync
    sync-uri: rsync://192.168.0.9/gentoo-portage
    priority: -1000
    sync-rsync-verify-jobs: 1
    sync-rsync-verify-metamanifest: yes
    sync-rsync-extra-opts: 
    sync-rsync-verify-max-age: 24

haskell
    location: /var/lib/layman/haskell
    masters: gentoo
    priority: 50

rust
    location: /var/lib/layman/rust
    masters: gentoo
    priority: 50

steam-overlay
    location: /var/lib/layman/steam-overlay
    masters: gentoo
    priority: 50

x11
    location: /var/lib/layman/x11
    masters: gentoo
    priority: 50

local
    location: /usr/local/portage
    masters: gentoo
    priority: 80

ACCEPT_KEYWORDS="amd64 ~amd64"
ACCEPT_LICENSE="* -@EULA"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-march=native -O3 -pipe -g -ggdb"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/lib64/libreoffice/program/sofficerc /usr/share/easy-rsa /usr/share/gnupg/qualified.txt"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/dconf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/php/apache2-php7.2/ext-active/ /etc/php/cgi-php7.2/ext-active/ /etc/php/cli-php7.2/ext-active/ /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo /etc/texmf/language.dat.d /etc/texmf/language.def.d /etc/texmf/updmap.d /etc/texmf/web2c"
CXXFLAGS="-march=native -O3 -pipe -g -ggdb"
DISTDIR="/usr/portage/distfiles"
ENV_UNSET="DBUS_SESSION_BUS_ADDRESS DISPLAY GOBIN PERL5LIB PERL5OPT PERLPREFIX PERL_CORE PERL_MB_OPT PERL_MM_OPT XAUTHORITY XDG_CACHE_HOME XDG_CONFIG_HOME XDG_DATA_HOME XDG_RUNTIME_DIR"
FCFLAGS="-O2 -pipe"
FEATURES="assume-digests binpkg-docompress binpkg-dostrip binpkg-logs config-protect-if-modified distlocks ebuild-locks fail-clean fixlafiles ipc-sandbox merge-sync multilib-strict network-sandbox news parallel-fetch preserve-libs protect-owned sandbox sfperms split-log splitdebug strict strict-keepdir unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync xattr"
FFLAGS="-O2 -pipe"
GENTOO_MIRRORS="http://distfiles.gentoo.org"
LANG="pl_PL.utf8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
LINGUAS="pl en"
MAKEOPTS="-j8"
PKGDIR="/usr/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --omit-dir-times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages --exclude=/.git"
PORTAGE_TMPDIR="/var/tmp"
USE="X acl adns alsa amd64 audio avx avx2 berkdb bluetooth bzip2 caps clang cli clutter crypt cups cxx dbus dri dri3 drm egl emacs ffmpeg fortran fpm fuse gadu gbm gdbm git glade gles glib gnutls gold gstreamer hardened iconv icu idn inotify ipv6 jack jpeg libdrm libtirpc llvm mmx mono mtp multilib multitarget ncurses net45 nls nptl opengl openmp openrc pam pcre perl pgf pkcs pkcs11 pkcs12 png policykit pulseaudio python readline samba sasl seccomp socks socks4 socks5 sound sqlite sqlite3 sse sse2 sse3 sse4 sse4_1 sse4_2 ssl ssse3 startup-notification syslog system-sqlite systemd tcpd theora threads truetype udev unicode v4l2 vaapi valgrind vdpau video vim vpx wayland wifi x265 xattr xcb xft zlib" ABI_X86="64 32" ALSA_CARDS="ca0132" APACHE2_MODULES="authn_core authz_core socache_shmcb unixd actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" CALLIGRA_FEATURES="karbon plan sheets words" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" CPU_FLAGS_X86="aes avx avx2 fma3 mmx mmxext popcnt sse sse2 sse3 sse4_1 sse4_2 ssse3" CURL_SSL="gnutls" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock isync itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf skytraq superstar2 timing tsip tripmate tnt ublox ubx" INPUT_DEVICES="libinput" KERNEL="linux" L10N="pl en" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php7-2" POSTGRES_TARGETS="postgres9_5 postgres10" PYTHON_SINGLE_TARGET="python3_6" PYTHON_TARGETS="python2_7 python3_6" RUBY_TARGETS="ruby25" USERLAND="GNU" VIDEO_CARDS="amdgpu radeonsi" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account"
Unset:  CC, CPPFLAGS, CTARGET, CXX, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LC_ALL, PORTAGE_BINHOST, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS
Comment 1 Mariusz Ceier 2019-01-19 23:10:02 UTC
Today I moved to sys-kernel/genkernel and it works with current version of lvm2... 

I heard that genkernel-next is not maintained - and rots slowly judging by the problem with lvm2 - if thats the case its name is at least misleading.

When I was asking about sys-kernel/genkernel on irc, some people thought it's not compatible with systemd which I'm using and I believed this until I tried genkernel today (I was using previous version of lvm2 with genkernel-next as a workaround until today) - it booted without problem.

Given above shouldn't genkernel-next be removed from the tree ?
Comment 2 José Pekkarinen 2020-10-11 06:21:49 UTC
Hi,

Is this not happening anymore in new versions? I just tried to build
a kernel 5.8.14 with genkernel 2.02.187-r2, and I observe the initrd
doesn't include the tools to populate lvm volumes. Config of the kernel
is refurbished from my 5.7.12 that I am still using, so for what the boot
respects, it should be fine, and genkernel is configured to put these
in genkernel.conf:

# Add LVM support
LVM="yes"

# Add LUKS support
LUKS="yes"

Thanks!

José.
Comment 3 José Pekkarinen 2020-10-11 06:24:25 UTC
Sorry, genkernel is 4.1.2-r3, lvm2 is 2.02.187-r2, kernel 5.8.14,
cryptsetup 2.3.2.

$ emerge info
Portage 3.0.4 (python 3.7.8-final-0, default/linux/amd64/17.1/desktop/plasma, gcc-9.3.0, glibc-2.31-r6, 5.7.12-x86_64 x86_64)
=================================================================
System uname: Linux-5.7.12-x86_64-x86_64-AMD_Ryzen_7_2700U_with_Radeon_Vega_Mobile_Gfx-with-gentoo-2.7
KiB Mem:     6871408 total,   3919952 free
KiB Swap:   16777212 total,  16777212 free
Timestamp of repository gentoo: Fri, 09 Oct 2020 15:30:01 +0000
Head commit of repository gentoo: eb51e7d7f6a5c30fc67e3fe13df25681d329a5d6
Timestamp of repository kde: Fri, 09 Oct 2020 14:05:10 +0000
Head commit of repository kde: 7d2f323b5d7eb56f75d7addb1240ec07406f0fd8

sh bash 5.0_p18
ld GNU ld (Gentoo 2.34 p6) 2.34.0
app-shells/bash:          5.0_p18::gentoo
dev-lang/perl:            5.30.3::gentoo
dev-lang/python:          2.7.18-r4::gentoo, 3.7.8-r2::gentoo, 3.8.5::gentoo
dev-util/cmake:           3.17.4-r1::gentoo
sys-apps/baselayout:      2.7::gentoo
sys-apps/openrc:          0.42.1::gentoo
sys-apps/sandbox:         2.18::gentoo
sys-devel/autoconf:       2.13-r1::gentoo, 2.69-r5::gentoo
sys-devel/automake:       1.13.4-r2::gentoo, 1.16.1-r1::gentoo
sys-devel/binutils:       2.34-r2::gentoo
sys-devel/gcc:            9.3.0-r1::gentoo
sys-devel/gcc-config:     2.3.1::gentoo
sys-devel/libtool:        2.4.6-r6::gentoo
sys-devel/make:           4.2.1-r4::gentoo
sys-kernel/linux-headers: 5.4-r1::gentoo (virtual/os-headers)
sys-libs/glibc:           2.31-r6::gentoo
Repositories:

gentoo
    location: /var/db/repos/gentoo
    sync-type: rsync
    sync-uri: rsync://rsync.gentoo.org/gentoo-portage
    priority: -1000
    sync-rsync-verify-metamanifest: yes
    sync-rsync-extra-opts: 
    sync-rsync-verify-jobs: 1
    sync-rsync-verify-max-age: 24

kde
    location: /var/db/repos/kde
    sync-type: git
    sync-uri: https://github.com/gentoo-mirror/kde.git
    masters: gentoo

steam-overlay
    location: /var/lib/layman/steam-overlay
    masters: gentoo
    priority: 50

ACCEPT_KEYWORDS="amd64"
ACCEPT_LICENSE="@FREE"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-O2 -march=znver1 -mtune=znver1 -fomit-frame-pointer -pipe"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/lib64/libreoffice/program/sofficerc /usr/share/config /usr/share/gnupg/qualified.txt"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/dconf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/php/apache2-php7.4/ext-active/ /etc/php/cgi-php7.4/ext-active/ /etc/php/cli-php7.4/ext-active/ /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo"
CXXFLAGS="-O2 -march=znver1 -mtune=znver1 -fomit-frame-pointer -pipe"
DISTDIR="/var/cache/distfiles"
ENV_UNSET="CARGO_HOME DBUS_SESSION_BUS_ADDRESS DISPLAY GOBIN GOPATH PERL5LIB PERL5OPT PERLPREFIX PERL_CORE PERL_MB_OPT PERL_MM_OPT XAUTHORITY XDG_CACHE_HOME XDG_CONFIG_HOME XDG_DATA_HOME XDG_RUNTIME_DIR"
FCFLAGS="-O2 -march=znver1 -mtune=znver1 -fomit-frame-pointer -pipe"
FEATURES="assume-digests binpkg-docompress binpkg-dostrip binpkg-logs config-protect-if-modified distlocks ebuild-locks fixlafiles ipc-sandbox merge-sync multilib-strict network-sandbox news parallel-fetch pid-sandbox preserve-libs protect-owned qa-unresolved-soname-deps sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync xattr"
FFLAGS="-O2 -march=znver1 -mtune=znver1 -fomit-frame-pointer -pipe"
GENTOO_MIRRORS="http://distfiles.gentoo.org"
LANG="C.utf8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
MAKEOPTS="-j4"
PKGDIR="/var/cache/binpkgs"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --omit-dir-times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages --exclude=/.git"
PORTAGE_TMPDIR="/var/tmp"
USE="X a52 aac acl acpi activities alsa amd64 berkdb bluetooth branding bzip2 cairo cdda cdr clang cli crypt cups dbus declarative dri dts dvd dvdr elogind emboss encode exif flac fortran gdbm gif gles gles2 gpm gui iconv icu ipv6 jack jpeg kde kipi kwallet lcms libglvnd libnotify libtirpc mad mng mp3 mp4 mpeg multilib ncurses nls nptl ogg opencl opengl openmp pam pango pcre pdf phonon php plasma png policykit ppds qml qt5 readline sdl seccomp semantic-desktop spell split-usr ssl startup-notification svg tcpd tiff truetype udev udisks unicode upower usb vorbis vulkan wayland widgets wxwidgets x264 xattr xcb xml xv xvid zlib" ABI_X86="64" ADA_TARGET="gnat_2018" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" APACHE2_MODULES="authn_core authz_core socache_shmcb unixd actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" CALLIGRA_FEATURES="karbon sheets words" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" CPU_FLAGS_X86="mmx mmxext sse sse2" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock greis isync itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf skytraq superstar2 timing tsip tripmate tnt ublox ubx" INPUT_DEVICES="libinput" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php7-2 php7-3 php7-4" POSTGRES_TARGETS="postgres10 postgres11" PYTHON_SINGLE_TARGET="python3_7" PYTHON_TARGETS="python2_7 python3_7" QEMU_SOFTMMU_TARGETS="x86_64 aarch64 arm riscv64 riscv32" RUBY_TARGETS="ruby25 ruby26" USERLAND="GNU" VIDEO_CARDS="radeonsi amdgpu" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account"
Unset:  CC, CPPFLAGS, CTARGET, CXX, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LC_ALL, LINGUAS, PORTAGE_BINHOST, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS
Comment 4 José Pekkarinen 2020-10-11 09:47:26 UTC
Mine seems to be a different beast, lvm gets in, and it's
possible to see the volumes in the shell, it's the devices
under /dev/mapper/ like /dev/mapper/vg0-root-volume what it
doesn't come up. Any hints what can cause this problem is
appreciated.

Thanks!

José.
Comment 5 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2021-02-01 16:25:53 UTC
genkernel-next was removed.