Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 149020 - genkernel'ed gentoo-sources-2.6.18 fail to boot
Summary: genkernel'ed gentoo-sources-2.6.18 fail to boot
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Hosted Projects
Classification: Unclassified
Component: genkernel (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Gentoo Genkernel Maintainers
URL:
Whiteboard:
Keywords: InVCS
Depends on:
Blocks:
 
Reported: 2006-09-25 01:00 UTC by f5d8fd51ed1e804c9e8d0357e8614e0493b06e96
Modified: 2007-01-04 09:21 UTC (History)
4 users (show)

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


Attachments
genkernel-3.4.4 gen_initrd.sh patch (gen_initrd.patch,1.42 KB, patch)
2006-12-14 05:07 UTC, François-Xavier Roure
Details | Diff
genkernel-3.4.4 generic/linuxrc patch (linuxrc.patch,490 bytes, patch)
2006-12-14 05:10 UTC, François-Xavier Roure
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description f5d8fd51ed1e804c9e8d0357e8614e0493b06e96 2006-09-25 01:00:38 UTC
>> activating mdev
/linuxrc: /linuxrc: 209: mdev: not found
>> Determing root device...
!! Block device /dev/hda3 is not a valid root device...
!! The root block device is unspecified or not detected.

Booting a genkernel'ed gentoo-sources-2.6.17-r7 kernel works just fine with the same setup.

used package versions:
  sys-fs/udev-100-r2
  sys-apps/baselayout-1.12.5
  sys-kernel/genkernel-3.4.1


magratea aaron # emerge --info
Portage 2.1.2_pre1-r2 (default-linux/x86/2006.0, gcc-4.1.1, glibc-2.4-r3, 2.6.17-gentoo-r7 i686)
=================================================================
System uname: 2.6.17-gentoo-r7 i686 AMD Athlon(tm) XP 3000+
Gentoo Base System version 1.12.5
Last Sync: Mon, 25 Sep 2006 06:20:01 +0000
app-admin/eselect-compiler: [Not Present]
dev-java/java-config: 1.3.6-r1, 2.0.29
dev-lang/python:     2.3.4-r1, 2.4.3-r3
dev-python/pycrypto: 2.0.1-r5
dev-util/ccache:     [Not Present]
dev-util/confcache:  [Not Present]
sys-apps/sandbox:    1.2.18.1
sys-devel/autoconf:  2.13, 2.60
sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2
sys-devel/binutils:  2.17
sys-devel/gcc-config: 1.3.13-r3
sys-devel/libtool:   1.5.22
virtual/os-headers:  2.6.17-r1
ACCEPT_KEYWORDS="x86 ~x86"
AUTOCLEAN="yes"
CBUILD="i686-pc-linux-gnu"
CFLAGS="-O2 -march=athlon-xp -fomit-frame-pointer"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /opt/jetty/etc /usr/kde/3.5/env /usr/kde/3.5/share/config /usr/kde/3.5/shutdown /usr/share/X11/xkb /usr/share/config"
CONFIG_PROTECT_MASK="/etc/env.d /etc/env.d/java/ /etc/gconf /etc/java-config/vms/ /etc/revdep-rebuild /etc/terminfo /etc/texmf/web2c"
CXXFLAGS="-O2 -mcpu=i686 -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoconfig distlocks fixpackages metadata-transfer parallel-fetch sandbox sfperms splitdebug strict"
GENTOO_MIRRORS="ftp://ftp.nyx.hu/gentoo http://gentoo.inode.at/ http://ftp-stud.fht-esslingen.de/pub/Mirrors/gentoo/"
LANG="de_DE.utf8"
LC_ALL="de_DE.utf8"
LINGUAS="de"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --delete-after --stats --timeout=180 --exclude='/distfiles' --exclude='/local' --exclude='/packages'"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
SYNC="rsync://rsync.de.gentoo.org/gentoo-portage"
USE="x86 16bit 3dnow 3dnowext X acpi alsa apache2 apm arts asf bash-completion berkdb bitmap-fonts browserplugin bzip2 bzlib c++ cairo cdio cjk cli cpudetection crypt ctype cups curl dba dbus divx dlloader doc dri dvd dvdr eds elibc_glibc emboss encode esd expat fam fbcon fbdev firefox flac font-server fontconfig foomaticdb fortran freetype gd gif gmedia gmp gpm gstreamer gtk gtk2 hal iconv idn imagemagick imap imlib input_devices_evdev input_devices_keyboard input_devices_mouse ipv6 isdnlog java javascript jpeg junit kde kdehiddenvisibility kerberos kernel_linux ldap libg++ libwww linguas_de logitech-mouse mad mhash mikmod mime mmx mmxext motif mozilla mp3 mpeg musicbrainz mysql ncurses nis nls no-seamonkey nptl nptlonly nsplugin nvidia ogg opengl oss pam pcre pdf pear perl php pic pie png ppds pppd python qt3 qt4 quicktime readline real reflection sasl sdl session speedo spell spl sqlite sse ssl stencil-buffer svga tcpd tidy tiff truetype truetype-fonts type1 type1-fonts udev unicode urandom usb userland_GNU userlocales video_cards_fbdev video_cards_nvidia video_cards_vesa vorbis win32codecs wmp xine xml xml2 xorg xscreensaver xsl xslt xv zeroconf zlib"
Unset:  CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LDFLAGS, PORTAGE_RSYNC_EXTRA_OPTS, PORTDIR_OVERLAY
Comment 1 Stephen Ulmer 2006-10-09 17:37:45 UTC
I have the identical problem with:

  lappy ulmer # genkernel --version
  3.4.1

I don't understand the root cause yet, but the proximal cause is that genkernel builds an initrd with an empty modules cpio archive:

  lappy cpio # pwd
  /usr/share/genkernel/pkg/x86/cpio
  lappy cpio # ls -l initramfs-modules-2.6.18.cpio.gz
  -rw-r--r-- 1 root root 843 Sep 28 00:00 initramfs-modules-2.6.18.cpio.gz
  lappy cpio #


This results in me not being able to mount /, since I've got mine on LVM2 and need dm-mod from the initrd.

This problem only occurs whem I'm trying to build kernel version 2.6.18. I've only tried vanilla-sources.
Comment 2 Stephen Ulmer 2006-10-13 07:17:27 UTC
I've confirmed that the same thing happens when building vanilla-sources-2.6.19_rc1.
Comment 3 Chris Gianelloni (RETIRED) gentoo-dev 2006-10-13 08:54:57 UTC
Exactly what commands are you using to build your kernel/initramfs?
Comment 4 Stephen Ulmer 2006-10-13 11:01:57 UTC
I've been using essentially:

  # genkernel  --lvm2 --kernel-config=/tmp/myconfig all

for many months. The kernel config I'm using is the same one I've had since the beginning.
Comment 5 f5d8fd51ed1e804c9e8d0357e8614e0493b06e96 2006-10-13 11:07:39 UTC
for me its the same 
 # genkernel all
I've been using all the time...
Comment 6 Stephen Ulmer 2006-10-13 11:14:12 UTC
Incidentally, bug #150697 contains the debug output from my actual genkernel run.

Also let me clarify that the kernel config I use is sometimes the output of a previous genkernel run (stored in /etc/kernels). Any changes in the config have been a side-effect of this.
Comment 7 François-Xavier Roure 2006-12-10 10:07:22 UTC
I have the same bug.

the problem come from the linuxrc file of genkernel which directly call
the mdev utilities of busybox. But mdev is not linked to the busybox executable in the gen_initrd.sh .
So we have to add mdev to the list of executable to link to busybox (in gen_initrd.sh) or call mdev by calling busybox we mdev as parameter (in linuxrc).

A second problem appears: mdev try to create to many nodes for the size of the current initrd. So i adjust the size of the ramdisk created and increase the number of inodes when creating the mke2fs (-N)
Comment 8 Bryan Kelley 2006-12-13 13:15:15 UTC
I was seeing the same reported error with genkernel 3.4.1 and 3.4.4.
Down graded genkernel to 3.3.11d and the problem is fixed.
this is using the same kernel level 2.6.18-r4 and the same .config file for all tests.


Bryan Kelley
Comment 9 François-Xavier Roure 2006-12-14 05:07:44 UTC
Created attachment 104037 [details, diff]
genkernel-3.4.4 gen_initrd.sh patch

Very simple patch to add the mdev tools in the initrd, and increase the RAMDISK size.

The value for the RAMDISK size (+2500 instead of 100) is surely too much.
The number of inodes on the RAMDISK (1000 instead of 500) is surely too much.
Comment 10 François-Xavier Roure 2006-12-14 05:10:26 UTC
Created attachment 104038 [details, diff]
genkernel-3.4.4 generic/linuxrc patch

I had to check for "linuxrc" instead of "/linuxrc" for $0, i don't know why ...
Comment 11 Chris Gianelloni (RETIRED) gentoo-dev 2006-12-14 08:35:56 UTC
I'm not sure I understand how initrd patches will help people using "genkernel all" which will default to initramfs (and not use the initrd code) on 2.6 kernels.

Can someone who can duplicate this problem please test these patches?
Comment 12 Stephen Ulmer 2006-12-14 19:10:36 UTC
Useful information!

I do not experience my original symptoms on amd64, only x86. That is on amd64 the modules cpio achive actually has modules in it. I don't understand why they're different, but it's a data point.
Comment 13 Bryan Kelley 2006-12-15 12:53:30 UTC
Tested the two patches with genkernel 3.4.4 and all works as expected with 2.6.18-r4 kernel.

Bryan Kelley 
Comment 14 François-Xavier Roure 2006-12-15 14:09:08 UTC
(In reply to comment #11)
> I'm not sure I understand how initrd patches will help people using "genkernel
> all" which will default to initramfs (and not use the initrd code) on 2.6
> kernels.
I just misused the --bootsplash instead of --gensplash so that why i hd problem with the initrd.
With the initramfs everything is ok so i don't know if my patch are really useful ...

thx for the help

Comment 15 Chris Gianelloni (RETIRED) gentoo-dev 2006-12-15 14:47:09 UTC
That explains that mystery.  ;]

I've got this slated to be added to subversion once the server comes back up.  It *does* need to be added for initrd builds, but I still don't get why it is fixing the problem for you guys running "genkernel all"...
Comment 16 Chris Gianelloni (RETIRED) gentoo-dev 2006-12-16 06:36:48 UTC
OK.  I've added this to SVN now.
Comment 17 Chris Gianelloni (RETIRED) gentoo-dev 2007-01-04 09:21:35 UTC
Fixed in 3.4.6