[Techtalk] failing to customise install floppy SOLVED

Conor Daly conor.daly at oceanfree.net
Sun Jun 30 00:07:13 EST 2002


I was having some trouble building a Redhat install floppy to include a
module instead of having to use a seperate driver disk.  Peter Milne came
up with the answer to my problem which was about making the cpio archive
containing the modules.  The correct invocation to build the archive is to
use "cpio -o --format=crc".  The details of how it's done follow...

mount -o loop bootnet.img /mnt/bootnet
cp bootnet/initrd.img initrd.img.gz
gunzip initrd.img.gz
mount -o loop initrd.img initrd
cp initrd/modules/modules.cgz .
gunzip -c modules.cgz | cpio -t > modules-list
gunzip -c modules.cgz | cpio -i -d

I now have a directory 2.4.7-10BOOT containing the modules.

cp eexpress.o 2.4.7-10BOOT/
echo 2.4.7-10BOOT/eexpress.o >> modules-list
cpio -o --format=crc < modules.list | gzip -c -9 > modules.cgz
cp modules.cgz initrd/modules/

I edit initrd/modules/module-info to include the eexpress module in the
list.  There are no entries relating to the eexpress in either
initrd/modules/pcitable or initrd/modules/modules.dep or in the
corresponding files on the drvnet.img disk so no edits required there.

umount initrd
gzip -9 initrd.img
cp initrd.img.gz bootnet/initrd.img
umount bootnet.img

dd if=bootnet.img of=/dev/fd0

All happy now...

Conor

On Wed, May 08, 2002 at 05:17:33PM +0100 or so it is rumoured hereabouts, 
Conor Daly thought:
> Has anyone tried to customise a RH7.2 install floppy?  The only thing I haven't
> thought of yet is a problem with the installer.  Will go and search redhat
> for that...
> 
> I'm trying to modify a boot disk to add a module rather than having to
> follow with a driver disk.  I have 30 machines to roll out all with
> identical hardware.  I'm using the RH7.2 bootnet.img floppy image with a
> kickstart to install over NFS.  The machines all have EtherExpress NICs
> (module eexpress.o) but the eexpress.o module is not on the bootnet.img,
> instead it's on the drvnet.img driver disk.  I'm trying to add this
> module to the bootnet.img but I'm having problems.  When I boot with my
> modified floppy, I get "CPIO bad magic" errors when trying to insmod
> modules.  I figure it's something I'm doing wrong when making the CPIO
> archive.  I do the following...
> 
> mount -o loop bootnet.img /mnt/bootnet
> cp bootnet/initrd.img initrd.img.gz
> gunzip initrd.img.gz
> mount -o loop initrd.img initrd
> cp initrd/modules/modules.cgz .
> gunzip -c modules.cgz | cpio -t > modules-list
> gunzip -c modules.cgz | cpio -i -d
> 
> I now have a directory 2.4.7-10BOOT containing the modules.
> 
> cp eexpress.o 2.4.7-10BOOT/
> echo 2.4.7-10BOOT/eexpress.o >> modules-list
> cpio -o < modules.list | gzip -c -9 > modules.cgz
> cp modules.cgz initrd/modules/
> 
> I edit initrd/modules/module-info to include the eexpress module in the
> list.  There are no entries relating to the eexpress in either
> initrd/modules/pcitable or initrd/modules/modules.dep or in the
> corresponding files on the drvnet.img disk so no edits required there.
> 
> umount initrd
> gzip -9 initrd.img
> cp initrd.img.gz bootnet/initrd.img
> umount bootnet.img
> 
> dd if=bootnet.img of=/dev/fd0
> 
> When I boot from this floppy, the installer comes up, asks all the usual
> questions until it gets to the ehternet driver.  Here the eexpress module
> appears in the list but when chosen gives the error "unable to load
> eexpress.o"  This error applies for any module chosen.  An <ALT><F3>
> gives me the actual error message  "unable to load eexpress.o  cpio Bad
> Magic".  This error is repeated for any module load attempt (eg for vfat.o
> or for ext2.o).  It's not related specifically to the eexpress module but
> seems to relate to the cpio archive modules.cgz instead.
> 
> Is there some invocation I need to build the archive correctly?
> 
> I'll be back later looking for advice in general; this is my first big
> networking project and my first remote admin (sounds like the title of a
> kids book "My First Remote Admin" with big colourful pictures!) and this
> lot is going out to Africa where there'll be almost _no_ local expertise!
> 
> Thanks,
> 
> Conor

-- 
Conor Daly <conor.daly at oceanfree.net>

Domestic Sysadmin :-)
---------------------
Faenor.cod.ie
 12:05am  up 37 days,  9:22,  0 users,  load average: 0.00, 0.00, 0.00
Hobbiton.cod.ie
 11:58pm  up 10 days, 23:20,  1 user,  load average: 0.00, 0.01, 0.00



More information about the Techtalk mailing list