Bug 181983 - default initrd for kernels > 2.6.15-1.1826.2.10_FC5 don't include sd_mod.ko
default initrd for kernels > 2.6.15-1.1826.2.10_FC5 don't include sd_mod.ko
Status: CLOSED RAWHIDE
Product: Fedora
Classification: Fedora
Component: mkinitrd (Show other bugs)
5
All Linux
medium Severity medium
: ---
: ---
Assigned To: Peter Jones
David Lawrence
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2006-02-18 06:01 EST by Kamal Shaker
Modified: 2007-11-30 17:11 EST (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2006-02-22 21:21:52 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Kamal Shaker 2006-02-18 06:01:10 EST
Description of problem:

After installing FC5 test 2 on machine with only sata disks, default kernel
2.6.15-1.1826.2.10_FC5 works fine, any of the updated kernels since then fail
with can't mount /dev/root

Remaking initrd with something like: 

mkinitrd --with=sd_mod.ko /boot/initrd-2.6.15-1.1955_FC5.img 2.6.15-1.1955_FC5

This is an x86_64 bit machine if that makes any difference.

Allows machine to boot correctly.

Version-Release number of selected component (if applicable):

Fedora Core release 4.91 (Pre-FC5), all kernels after 1826 (that I have checked)

How reproducible:

Very.

Steps to Reproduce:
1. Update kernel on machine with sata 
2. Reboot, kernel will panic, saying it can't mount /dev/root
3.
  
Actual results:


Expected results:


Additional info:
Comment 1 Dave Jones 2006-02-18 22:09:46 EST
hmm.  it's present in the initrd's I just checked.
Can you attach the output of lsmod and /etc/modprobe.conf ?
Could be that whatever sata driver you use doesn't have a dependancy for some
reason.
Comment 2 Kamal Shaker 2006-02-19 04:44:45 EST
It doesn't look like a dependancy is listed with lsmod, or modprobe.conf, but it
"just worked" in 1826.

initrd-2.6.15-1.1826.2.10_FC5.img is the initrd that came with the rpm
initrd-2.6.15-1.1955_FC5.img-dist is the initrd that came with the rpm
initrd-2.6.15-1.1955_FC5.img is the one I made using mkinitrd

b3:~% uname -a
Linux b3 2.6.15-1.1955_FC5 #1 SMP Wed Feb 15 15:45:28 EST 2006 x86_64 x86_64
x86_64 GNU/Linux
b3:~% ls -l /etc/modprobe.conf
-rw-r--r-- 1 root root 150 Jan 29 17:10 /etc/modprobe.conf
b3:~% cat /etc/modprobe.conf
options snd-intel8x0 index=0
remove snd-intel8x0 { /usr/sbin/alsactl store 0 >/dev/null 2>&1 || : ; };
/sbin/modprobe -r --ignore-remove
 snd-intel8x0
b3:~% lsmod
Module                  Size  Used by
ppdev                  42569  0
autofs4                55369  1
it87                   58085  0
hwmon_vid              35777  1 it87
hwmon                  36553  1 it87
eeprom                 41297  0
i2c_isa                39233  1 it87
rfcomm                105057  0
l2cap                  91841  5 rfcomm
bluetooth             117189  2 rfcomm,l2cap
sunrpc                192265  1
reiserfs              270793  1
dm_mirror              54721  0
dm_mod                 90385  1 dm_mirror
video                  50633  0
button                 40673  0
battery                43464  0
ac                     38601  0
ipv6                  399073  12
usb_storage           104097  0
lp                     47761  0
parport_pc             62825  0
parport                74189  3 ppdev,lp,parport_pc
floppy                100745  0
nvram                  42569  0
ohci1394               68120  0
ieee1394              392025  1 ohci1394
ehci_hcd               65357  0
ohci_hcd               55005  0
sg                     69225  0
snd_intel8x0           68329  1
snd_ac97_codec        136217  1 snd_intel8x0
snd_ac97_bus           35905  1 snd_ac97_codec
snd_seq_dummy          37189  0
snd_seq_oss            66369  0
snd_seq_midi_event     41281  1 snd_seq_oss
snd_seq                89953  5 snd_seq_dummy,snd_seq_oss,snd_seq_midi_event
snd_seq_device         42961  3 snd_seq_dummy,snd_seq_oss,snd_seq
snd_pcm_oss            85713  0
snd_mixer_oss          51009  1 snd_pcm_oss
nvidia               4893104  8
snd_pcm               126537  3 snd_intel8x0,snd_ac97_codec,snd_pcm_oss
i2c_nforce2            40897  0
sunhme                 56061  0
i2c_core               57537  4 it87,eeprom,i2c_isa,i2c_nforce2
sky2                   73797  0
qla1280               151633  0
snd_timer              59593  2 snd_seq,snd_pcm
snd                    97129  11
snd_intel8x0,snd_ac97_codec,snd_seq_oss,snd_seq,snd_seq_device,snd_pcm_oss
,snd_mixer_oss,snd_pcm,snd_timer
soundcore              44257  1 snd
snd_page_alloc         44625  2 snd_intel8x0,snd_pcm
sata_sil24             45381  0
forcedeth              57925  0
sd_mod                 50881  9
sata_nv                43589  7
libata                 93913  2 sata_sil24,sata_nv
scsi_mod              180753  6 usb_storage,sg,qla1280,sata_sil24,sd_mod,libata
ext3                  164177  4
jbd                    93673  1 ext3
b3:~% cd /boot
b3:/boot% zcat initrd-2.6.15-1.1955_FC5.img | cpio -it
sys
sysroot
init
sbin
lib
lib/jbd.ko
lib/scsi_mod.ko
lib/ext3.ko
lib/libata.ko
lib/sata_nv.ko
lib/sd_mod.ko
etc
proc
bin
bin/insmod
bin/modprobe
bin/nash
dev
dev/ttyS2
dev/ptmx
dev/mapper
dev/tty1
dev/tty12
dev/tty
dev/rtc
dev/tty10
dev/tty11
dev/tty3
dev/ttyS3
dev/ttyS0
dev/tty9
dev/console
dev/ttyS1
dev/ram1
dev/tty5
dev/zero
dev/tty6
dev/tty4
dev/tty2
dev/null
dev/tty8
dev/tty0
dev/tty7
dev/systty
dev/ram0
5391 blocks
b3:/boot% zcat initrd-2.6.15-1.1955_FC5.img-dist | cpio -it
sys
sysroot
init
sbin
lib
lib/jbd.ko
lib/scsi_mod.ko
lib/ext3.ko
lib/libata.ko
lib/sata_nv.ko
etc
proc
bin
bin/insmod
bin/modprobe
bin/nash
dev
dev/ttyS2
dev/ptmx
dev/mapper
dev/tty1
dev/tty12
dev/tty
dev/rtc
dev/tty10
dev/tty11
dev/tty3
dev/ttyS3
dev/ttyS0
dev/tty9
dev/console
dev/ttyS1
dev/ram1
dev/tty5
dev/zero
dev/tty6
dev/tty4
dev/tty2
dev/null
dev/tty8
dev/tty0
dev/tty7
dev/systty
dev/ram0
5272 blocks
b3:/boot% zcat initrd-2.6.15-1.1826.2.10_FC5.img | cpio -it
sys
sysroot
init
sbin
lib
lib/jbd.ko
lib/scsi_mod.ko
lib/ext3.ko
lib/libata.ko
lib/sata_nv.ko
lib/sd_mod.ko
etc
proc
bin
bin/insmod
bin/hotplug
bin/modprobe
bin/nash
dev
dev/ttyS2
dev/mapper
dev/tty1
dev/tty12
dev/tty
dev/rtc
dev/tty10
dev/tty11
dev/tty3
dev/ttyS3
dev/ttyS0
dev/tty9
dev/ram0
5272 blocks
b3:/boot% zcat initrd-2.6.15-1.1826.2.10_FC5.img | cpio -it
sys
sysroot
init
sbin
lib
lib/jbd.ko
lib/scsi_mod.ko
lib/ext3.ko
lib/libata.ko
lib/sata_nv.ko
lib/sd_mod.ko
etc
proc
bin
bin/insmod
bin/hotplug
bin/modprobe
bin/nash
dev
dev/ttyS2
dev/mapper
dev/tty1
dev/tty12
dev/tty
dev/rtc
dev/tty10
dev/tty11
dev/tty3
dev/ttyS3
dev/ttyS0
dev/tty9
dev/console
dev/ttyS1
dev/tty5
dev/zero
dev/ram
dev/tty6
dev/tty4
dev/tty2
dev/null
dev/tty8
dev/tty0
dev/tty7
dev/systty
4927 blocks
Comment 3 Dave Jones 2006-02-19 15:53:04 EST
your /etc/modprobe.conf is broken.
You should have at least one 'alias scsi_hostadapter...' line in there.

Hmm, Bill, it seems kudzu has stopped detecting sata controllers.

(15:38:59:davej@nwo:~)$ cat /etc/modprobe.conf
alias eth0 e1000
alias scsi_hostadapter ata_piix
alias snd-card-0 snd-emu10k1
options snd-card-0 index=0
options snd-emu10k1 index=0
remove snd-emu10k1 { /usr/sbin/alsactl store 0 >/dev/null 2>&1 || : ; };
/sbin/modprobe -r --ignore-remove snd-emu10k1
alias snd-card-1 snd-intel8x0
options snd-card-1 index=1
options snd-intel8x0 index=1
remove snd-intel8x0 { /usr/sbin/alsactl store 1 >/dev/null 2>&1 || : ; };
/sbin/modprobe -r --ignore-remove snd-intel8x0
(15:40:17:davej@nwo:~)$ sudo bash
(15:40:59:root@nwo:~)# mv /etc/sysconfig/hwconf /etc/sysconfig/hwconf.broken
(15:40:59:root@nwo:~)# mv /etc/modprobe.conf /etc/modprobe.conf.broken
(15:40:59:root@nwo:~)# kudzu
(15:41:01:root@nwo:~)# diff -u /etc/modprobe.conf.broken /etc/modprobe.conf
--- /etc/modprobe.conf.broken   2006-02-14 21:46:34.000000000 -0500
+++ /etc/modprobe.conf  2006-02-19 15:41:01.000000000 -0500
@@ -1,5 +1,4 @@
 alias eth0 e1000
-alias scsi_hostadapter ata_piix
 alias snd-card-0 snd-emu10k1
 options snd-card-0 index=0
 options snd-emu10k1 index=0

That's not good(TM).
Comment 4 Kamal Shaker 2006-02-19 17:59:07 EST
Aha, that links in the the other problem I'm having (but didn't bother me too
much since I hadn't installed any new hardware, oh how I've learnt!), kudzu is
seg faulting, both at boot :

# strace -fv /sbin/kudzu
....
7059  open("/proc/ide/amd74xx/media", O_RDONLY) = -1 ENOTDIR (Not a directory)
7059  getdents(7, {}, 8192)             = 0
7059  close(7)                          = 0
7059  readlink("/proc/self/fd/0", "/dev/pts/3", 4096) = 10
7059  readlink("/proc/self/fd/1", "/dev/pts/3", 4096) = 10
7059  readlink("/proc/self/fd/2", "/dev/pts/3", 4096) = 10
7059  open("/dev/console", O_RDWR)      = 7
7059  ioctl(7, TIOCLINUX, 0x7fffff95d11f) = 6
7059  open("/dev/zero", O_RDWR)         = 14
7059  mmap(0x10000, 262144, PROT_READ|PROT_WRITE|PROT_EXEC,
MAP_SHARED|MAP_FIXED, 14, 0) = 0x10000
7059  close(14)                         = 0
7059  open("/dev/mem", O_RDWR)          = 14
7059  mmap(NULL, 1282, PROT_READ|PROT_WRITE|PROT_EXEC, MAP_SHARED|MAP_FIXED, 14,
0) = 0
7059  mmap(0xa0000, 393216, PROT_READ|PROT_WRITE, MAP_SHARED|MAP_FIXED, 14,
0xa0000) = 0xa0000
7059  close(14)                         = 0
7059  iopl(0x3)                         = 0
7059  ioperm(0, 0x400, 0x1)             = 0
7059  iopl(0x3)                         = 0
7059  ioperm(0, 0x400, 0x1)             = 0
7059  --- SIGSEGV (Segmentation fault) @ 0 (0) ---
7059  +++ killed by SIGSEGV +++

I can't debug it since it's been stripped (? why, for a test version), and I
can't compile the srpm, it gives a bunch of undefined PCI structures etc.

/sbin/kudzu -s works fine but doesn't modify /etc/modules.conf or
/etc/sysconfig/hwconf

Although I get a bit further if I do this:
b3:/etc/sysconfig# rm hwconf ../modprobe.conf
b3:/etc/sysconfig# kudzu -s
b3:/etc/sysconfig# cat ../modprobe.conf
alias dev30686 sunhme
alias eth0 forcedeth
alias eth2 sky2
alias snd-card-0 snd-intel8x0
options snd-card-0 index=0
options snd-intel8x0 index=0
remove snd-intel8x0 { /usr/sbin/alsactl store 0 >/dev/null 2>&1 || : ; };
/sbin/modprobe -r --ignore-remove snd-intel8x0

syslog logs this:

Feb 19 22:24:57 b3 kernel: kudzu[1773]: segfault at 000000000000ffcb rip
0000000000422522 rsp 00007fffffc340e0 error 4
Comment 5 Bill Nottingham 2006-02-20 13:09:50 EST
kudzu doesn't write scsi_hostadapter aliases any more - they're not needed.
mkinitrd should pick it up just fine without it. Kamal - the segfault is
entirely unrelated - see bug 181467.
Comment 6 Dave Jones 2006-02-20 14:01:19 EST
then I'm at a loss to explain why sd_mod isn't ending up in the initrd.
Peter ?
Comment 7 Peter Jones 2006-02-22 18:05:30 EST
No other modules depend on sd_mod, so it doesn't get pulled in unless we see
that we're using scsi -- of course we check for scsi_hostadapter to find that. 
I'll switch it to looking for scsi_mod and/or libata ...
Comment 8 Kamal Shaker 2006-03-06 17:15:21 EST
Have you managed to fix this, I'm still seeing the problem in all kernels up to
2.6.15-1.2009.4.2_FC5.
Comment 9 Dave Jones 2006-03-06 18:33:32 EST
with the latest mkinitrd package installed ?

Note You need to log in before you can comment on or make changes to this bug.