Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

where is Mandriva 2008.1 hiding "load module amd74xx"????

0 views
Skip to first unread message

David Mathog

unread,
Dec 5, 2008, 3:45:08 PM12/5/08
to
I have 19 systems with Tyan S2466 motherboards and 1 with a Gigabyte
motherboard. These are otherwise fairly similar AMD Athlon systems.
Anyway, an image from a Tyan system will not boot on the Gigabyte
system. It blows up while the kernel is loading, where if a serial
console is attached, one sees this:

Loading ide-disk module
Loading amd74xx module
No resume device specified
Trying userspace resume from suspend.conf file
No resume device in suspend.conf
Trying suspend2 resume
Trying tuxonice resume
Creating root device.
Mounting root filesystem.
mount: error mounting /dev/root on /sysroot as ext3: No such device or
address
Setting up other filesystems.
Setting up new root fs
setuproot: moving /dev failed: No such file or directory
no fstab.sys, mounting internal defaults
setuproot: error mounting /proc: No such file or directory
setuproot: error mounting /sys: No such file or directory
Switching to new root and running init.
unmounting old /dev
unmounting old /proc
unmounting old /sys
switchroot: mount failed: No such file or directory
Booting has failed.


The problem is apparently the amd74xx, which is wrong for the Gigabyte,
which uses a via entry instead.

So, in desperation I made a minimal install of 2008.1 on the Gigabyte
system. Rebooted it a couple of times, and it came up fine, not using
the amd74xx device. (I can't actually use that, the image has a lot of
modifications from a default install.) The /boot directory was
identical (same kernel version). Copied /etc to another partition,
reimaged the "/" and "/boot" partitions, booted a PLD rescue OS, and
copied from the saved /etc

modprobe.conf
modprobe.preload
udev (replaced the entire directory structury)

Looked at /etc/lilo.conf, it was the same on the two versions. In fact:

rgrep -ir amd74 /etc

When run on one of the S2466 systems, only finds it in
/etc/modprobe.conf and /etc/sysconfig/hardrake2/previous_hw.
(The latter is a possibility I suppose, but the boot never gets to
the init stage, so it would have to be wired into the kernel. I'll
check that after lunch.)

Rebooted, same problem as above. Something, somewhere seems to be
telling the kernel to load the wrong module.

Where in the H### is Mandriva hiding this???

More generally, is there some magic kernel "reconfigure" parameter which
will let a Mandriva kernel boot on new hardware?

Thanks,

David Mathog

David Mathog

unread,
Dec 5, 2008, 5:42:35 PM12/5/08
to
David Mathog wrote:
> Where in the H### is Mandriva hiding this???

I deleted the "previous_hw" file, rebooted, and nothing changed, it
still loaded amd74xx for no reason. I'll probably have to unpack the
initrd and dig through it to figure out where this thing is hidden.
That's a major PITA.

So I gave up for now and fell back to Mandriva 2007.1 on this system.
At least doing that was easy:
1. boot boel and clone /boot and / from the master 2007.1 image
2. boot PLD rescue via PXE, replace with the Gigabyte
specific versions:
/etc/modprobe.conf
/etc/sysconfig/lm_sensors
/etc/sensors.conf
/usr/local/sbin/sensor_monitor.sh (my own script)
3. (still in PLD rescue) rerun lilo
4. reboot

It came right up, with no amd74xx vs via82cxxx confusion. Total time,
about 15 minutes.

Regards,

David Mathog

David Mathog

unread,
Dec 8, 2008, 2:32:39 PM12/8/08
to
David Mathog wrote:
> I have 19 systems with Tyan S2466 motherboards and 1 with a Gigabyte
> motherboard. These are otherwise fairly similar AMD Athlon systems.
> Anyway, an image from a Tyan system will not boot on the Gigabyte
> system. It blows up while the kernel is loading...

Found it. There has been a major change in the way the initrd is
organized in Mandriva. Under 2007.1 the initrd unpacked was only 824Kb,
whereas in 2008.1 it is 4.78M. More to the point for this thread, the
"init" file in the top level of 2007.1 was simple and very general
purpose, it would probably work on any machine.

(FYI, here is how to unpack a current initrd, which are compressed cpio
archives:
mkdir /tmp/foo
cd /tmp/foo
gunzip -c </boot/initrdSPECIFIC_VERSION.img \
| cpio -i --make-directories
)

This is the init from 2007.1:

cat init
#!/bin/nash

echo "Loading jbd.ko module"
insmod /lib/jbd.ko
echo "Loading ext3.ko module"
insmod /lib/ext3.ko
echo Mounting /proc filesystem
mount -t proc /proc /proc
echo Mounting sysfs
mount -t sysfs none /sys
echo Creating device files
mountdev size=32M,mode=0755
echo -n /sbin/hotplug > /proc/sys/kernel/hotplug
mkdir /dev/.udevdb
mkdevices /dev
echo Creating root device
mkrootdev /dev/root
resume
echo > /proc/suspend2/do_resume
echo Mounting root filesystem /dev/root
mount -o defaults --ro -t ext3 /dev/root /sysroot
echo Switching to new root
switchroot --movedev /sysroot
echo Initrd finished


Whereas for 2008.1 the init file is much larger and much more machine
specific. It is likely that it will only work on an identical machine
to the original. Even minor changes could throw it. For instance, if
you had two identical machines, except that one had a PATA disk, and the
other a SATA, I suspect that if you swapped the system disks neither
would boot. Here is the "init" from an S2466 machine:

#!/bin/nash

mount -t proc /proc /proc
setquiet
echo Mounting proc filesystem
echo Mounting sysfs filesystem
mount -t sysfs /sys /sys
echo Creating /dev
mount -o mode=0755 -t tmpfs /dev /dev
mkdir /dev/pts
mount -t devpts -o gid=5,mode=620 /dev/pts /dev/pts
mkdir /dev/shm
mkdir /dev/mapper
echo Creating initial device nodes
mknod /dev/null c 1 3
mknod /dev/zero c 1 5
mknod /dev/systty c 4 0
mknod /dev/tty c 5 0
mknod /dev/console c 5 1
mknod /dev/ptmx c 5 2
mknod /dev/tty0 c 4 0
mknod /dev/tty1 c 4 1
mknod /dev/tty2 c 4 2
mknod /dev/tty3 c 4 3
mknod /dev/tty4 c 4 4
mknod /dev/tty5 c 4 5
mknod /dev/tty6 c 4 6
mknod /dev/tty7 c 4 7
mknod /dev/tty8 c 4 8
mknod /dev/tty9 c 4 9
mknod /dev/tty10 c 4 10
mknod /dev/tty11 c 4 11
mknod /dev/tty12 c 4 12
mknod /dev/ttyS0 c 4 64
mknod /dev/ttyS1 c 4 65
mknod /dev/ttyS2 c 4 66
mknod /dev/ttyS3 c 4 67
echo Setting up hotplug.
hotplug
echo Creating block device nodes.
mkblkdevs
echo "Loading ehci-hcd module"
modprobe -q ehci-hcd
echo "Loading ohci-hcd module"
modprobe -q ohci-hcd
echo "Loading uhci-hcd module"
modprobe -q uhci-hcd
mount -t usbfs /proc/bus/usb /proc/bus/usb
echo "Loading ext3 module"
modprobe -q ext3
echo "Loading ide-core module"
modprobe -q ide-core
echo "Loading ide-disk module"
modprobe -q ide-disk
echo "Loading amd74xx module"
modprobe -q amd74xx
mkblkdevs
nash-resume
echo Creating root device.
mkrootdev -t ext3 -o relatime,ro /dev/hda3
echo Mounting root filesystem.
mount /sysroot
echo Setting up other filesystems.
setuproot
loadpolicy
echo Switching to new root and running init.
switchroot
echo Booting has failed.
sleep -1

There are a few things to note here. First of all, 2008.1 is loading
those modules from a copy WITHIN the initrd (not from the hard disk copies):

ls lib/modules/2.6.24.7-desktop-2mnb/
amd74xx.ko.gz ide-core.ko.gz modules.alias modules.ieee1394map
modules.ofmap modules.symbols uhci-hcd.ko.gz
ehci-hcd.ko.gz ide-disk.ko.gz modules.ccwmap modules.inputmap
modules.pcimap modules.usbmap usbcore.ko.gz
ext3.ko.gz jbd.ko.gz modules.dep modules.isapnpmap
modules.seriomap ohci-hcd.ko.gz

whereas 2007.1 only used ext3.ko and jbd.ko, which it loaded from /lib,
not /lib/modules/2.6.24.7-desktop-2mnb/. There was nothing else in /lib
for 2007.1, whereas for 2008.1 there are a lot of .so libraries.

Just for yucks I had a look at an initrd from Ubuntu 8.04.1, and it was
bigger still, at 25.7M, but also very general. It had a huge number of
modules in the initrd, but could use them to boot on various hardware
(apparently, not tested).

I'll try to see if I can make an initrd for 2008.1 which is general
purpose again, like the one from 2007.1. (Odd that they used all those
explicit mknod commands instead of running mkdevices as in 2007.1, as
mkdevices is still built into nash, however it seems to have lost
mountdev, which may have required this change.)


Regards,

David Mathog

David Mathog

unread,
Dec 8, 2008, 2:46:30 PM12/8/08
to
This seems to be the same issue:

https://qa.mandriva.com/show_bug.cgi?id=39358

Regards,

David Mathog

0 new messages