xfs
[Top] [All Lists]

Re: mkinitrd, ramdisk failure?

Subject: Re: mkinitrd, ramdisk failure?
From: "D. Stimits" <stimits@xxxxxxxxxx>
Date: Wed, 13 Jun 2001 21:49:56 -0600
Cc: "XFS: linux-xfs@xxxxxxxxxxx" <linux-xfs@xxxxxxxxxxx>
References: <Pine.LNX.4.33.0106131222080.5609-100000@xxxxxxxxxxxxxxxxxxxxx> <3B26C626.24EC0F20@xxxxxxxxxx> <3B26CC5E.6050804@xxxxxxxxxx> <3B26D839.E6C58E3E@xxxxxxxxxx> <3B26DCBB.2289C8FC@xxxxxxxxxxxxxxxx> <3B26E3DF.1B22B76A@xxxxxxxxxx> <3B26EFD1.723327FA@xxxxxxxxxxx> <3B27E2B5.CB5E4CF6@xxxxxxxxxx> <3B281A78.5000809@xxxxxxxxxx> <3B281DE1.EE4AFC33@xxxxxxxxxx> <3B2822F8.4010608@xxxxxxxxxx>
Reply-to: stimits@xxxxxxxxxx
Sender: owner-linux-xfs@xxxxxxxxxxx
To summarize, things are still failing. When I use modules for scsi, it
is apparent that no ramdisk is being used at all. I have tried
variations of using original mkinitrd, as well as mkinitrd.xfs. I
definitely have a ramdisk that contains the required modules, it just
ignores it. Here is the most recent mkinitrd command:
mkinitrd \
 -v \
 -f \
 --preload pagebuf \
 --preload xfs_support \
 --preload xfs \
 --with=scsi_mod \
 --with=sd_mod \
 --with=aic7xxx \
 /boot/ir-2.4.6-p1-xfs-3.img \
 2.4.6-pre1-xfs-3

Here is the output:
Using modules:  ./kernel/fs/pagebuf/pagebuf.o
./kernel/fs/xfs_support/xfs_support.o ./kernel/fs/xfs/xfs.o
./kernel/drivers/scsi/scsi_mod.o ./kernel/drivers/scsi/sd_mod.o
./kernel/drivers/scsi/aic7xxx/aic7xxx.o
Using loopback device /dev/loop0
/sbin/nash -> /tmp/initrd.sXOMy4/bin/nash
/sbin/insmod.static -> /tmp/initrd.sXOMy4/bin/insmod
`/lib/modules/2.4.6-pre1-xfs-3/./kernel/fs/pagebuf/pagebuf.o' ->
`/tmp/initrd.sXOMy4/lib/pagebuf.o'
`/lib/modules/2.4.6-pre1-xfs-3/./kernel/fs/xfs_support/xfs_support.o' ->
`/tmp/initrd.sXOMy4/lib/xfs_support.o'
`/lib/modules/2.4.6-pre1-xfs-3/./kernel/fs/xfs/xfs.o' ->
`/tmp/initrd.sXOMy4/lib/xfs.o'
`/lib/modules/2.4.6-pre1-xfs-3/./kernel/drivers/scsi/scsi_mod.o' ->
`/tmp/initrd.sXOMy4/lib/scsi_mod.o'
`/lib/modules/2.4.6-pre1-xfs-3/./kernel/drivers/scsi/sd_mod.o' ->
`/tmp/initrd.sXOMy4/lib/sd_mod.o'
`/lib/modules/2.4.6-pre1-xfs-3/./kernel/drivers/scsi/aic7xxx/aic7xxx.o'
-> `/tmp/initrd.sXOMy4/lib/aic7xxx.o'
Loading module pagebuf with options 
Loading module xfs_support with options 
Loading module xfs with options 
Loading module scsi_mod with options 
Loading module sd_mod with options 
Loading module aic7xxx with options 


Here is my lilo.conf for that (note that the -2 works and has scsi and
xfs compiled in, while the -3 version is all modules for scsi and xfs; I
shortened the name of the ramdisk file hoping it was just too long
before, but it did not help):

boot=/dev/sda
map=/boot/map
install=/boot/boot.b
prompt
timeout=50
message=/boot/message
linear
vga=0x030c
default=2.4.6-p1-xfs-2
backup=boot.backup.when-2.4.6-pre1-xfs-3

# FAILS, uses modules.
image=/boot/vmlinuz-2.4.6-pre1-xfs-3
        label=2.4.6-p1-xfs-3
        initrd=/boot/ir-2.4.6-p1-xfs-3.img
        read-only
        root=/dev/sda6
        append="noapic ramdisk_size=16000"

# works, no modules.
image=/boot/vmlinuz-2.4.6-pre1-xfs-2
        label=2.4.6-p1-xfs-2
        initrd=/boot/initrd-2.4.6-pre1-xfs-2.img
        read-only
        root=/dev/sda6
        append="noapic"


Here lilo explicitly names the ramdisk as 1304 sectors for the -3
version that is in question. Unfortunately, it lies, it is ignoring the
ramdisk, and loads nothing from it. The output of lilo -v -v:

# lilo -v -v
LILO version 21.4-4, Copyright (C) 1992-1998 Werner Almesberger
'lba32' extensions Copyright (C) 1999,2000 John Coffman

Reading boot sector from /dev/sda
Merging with /boot/boot.b
Secondary loader: 11 sectors.
Mapping message file /boot/message
Message: 46 sectors.
Boot image: /boot/vmlinuz-2.4.6-pre1-xfs-3
Setup length is 9 sectors.
Mapped 1607 sectors.
Mapping RAM disk /boot/ir-2.4.6-p1-xfs-3.img
RAM disk: 1304 sectors.
Added 2.4.6-p1-xfs-3
Boot image: /boot/vmlinuz-2.4.6-pre1-xfs-2
Setup length is 9 sectors.
Mapped 2274 sectors.
Mapping RAM disk /boot/initrd-2.4.6-pre1-xfs-2.img
RAM disk: 500 sectors.
Added 2.4.6-p1-xfs-2 *
boot.backup.when-2.4.6-pre1-xfs-3 exists - no backup copy made.
Map file size: 34304 bytes.
Writing boot sector.


Apparently it requires setting up a serial console to a second machine
in order to use kdb, so I am not able to do that at this time.

Since it is possible to mount a ramdisk image via loopback, is it also
possible to do something similar with a file created from dd of MBR, and
debug what it is doing one line at a time? I assume this is too far from
human readable to do any good. I'm down to the point where I think I
might need to give up on modules, or else ship off dd images of my MBR
and initrd for someone to analyze. Very depressing.

D. Stimits, stimits@xxxxxxxxxx

<Prev in Thread] Current Thread [Next in Thread>