From 10ac5c60e51125d45f3923edd1dd1f560ad0df1f Mon Sep 17 00:00:00 2001 From: dann frazier Date: Sun, 14 Dec 2008 19:24:11 +0100 Subject: Fix MODULES=dep for cciss devices A coworker reported a lenny install failure today. Turns out he had asked the installer to run mkinitramfs w/ MODULES=dep, which I'd never tried before: dl380g5:/home/dannf# mkinitramfs-kpkg -o /boot/initrd.img-2.6.26-1-686 2.6.26-1-686 mkinitramfs: missing cciss/c0d0p root /dev/cciss/c0d0p1 /sys entry mkinitramfs: workaround is MODULES=most mkinitramfs: Error please report the bug dep_add_modules() expects to find a /sys/block/cciss/c0d0p file, but it should be trying /sys/block/cciss!c0d0: (closes: #507619) --- hook-functions | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/hook-functions b/hook-functions index 53867da..d8875b7 100644 --- a/hook-functions +++ b/hook-functions @@ -269,6 +269,10 @@ dep_add_modules() root=${root#/dev/} block=$(awk "/^${root}/{print substr(\$5, 1, 3); exit}" \ /proc/mdstat) + # cciss device + elif [ "${root#/dev/cciss/}" != "${root}" ]; then + block=${root#/dev/cciss/*} + block="cciss!${block%p*}" # classical root device else block=${root#/dev/} -- cgit v1.2.3