To all SuSe gurus, I am trying to compile a new kernal on SuSe8 and I am having a few problems understanding what to do when I get to : mk_initrd . I want mk_initrd to use boot/vmlinuz-james that I created and not boot/vmlinuz.suse I am enclosing a HowTo that I wrote. Any comments or info would be appreciated... ######### START ######### # HowToCreateNewSuSE8 Kernal # Install kernel-source from SuSe CD's # Check for the required packages rpm -q kernel-source ncurses-devel gcc make # Expected results # kernel-source-2.4.18.SuSE-35 # ncurses-devel-5.2-283 # gcc-2.95.3-216 # make-3.79.1-292 # if not present - install them with ap-get # e.g. apt-get install ncurses-devel # Copy suse kernal to /usr/src/linux cp -p /boot/vmlinuz.suse /usr/src/linux # Create new kernal "-james" for Athlon using the commande "make menuconfig" make menuconfig # Chose the correct Processor old: (X) 586/K5/5x86/6x86/6x86MX new: (X) Athlon/Duron/K7 # Modify File System Support # Added : <*> DOS FAT fs support <*> MSDOS fs support <*> UMSDOS: Unix-like file system on top of standard MSDOS fs <*> VFAT (Windows-95) fs support # Save Configuration to an Alternate File Name : vmlinuz-james # Do you wish to save your new kernel configuration? Yes # The end of the menuconfig log sayes ... # *** End of Linux kernel configuration. # *** Check the top-level Makefile for alilo.conf.bakdditional configuration. # *** Next, you may run 'make bzImage', 'make bzdisk', or 'make install'. # Check for new Makefile ls -trl /usr/src/linux/Makefile cp Makefile Makefile.bak vi Makefile # Modified EXTRAVERSION old:EXTRAVERSION = new: EXTRAVERSION =james Saved and exited # Run make bzImage make bzImage linux:/usr/src/linux/arch/i386/boot # ls -trl bzImage -rw-r--r-- 1 root root 1012346 Oct 19 23:56 bzImage linux:/boot # ls -trl /usr/src/linux/arch/i386/boot/bzImage -rw-r--r-- 1 root root # Copy to /boot cp -p /usr/src/linux/arch/i386/boot/bzImage /boot/vmlinuz-james cp -p /usr/src/linux/System.map /boot/System.map-james # Run modules_install cd /usr/src/linux make modules_install # Run mk_initrd # -k "kernel list" list of kernel images for which initrd files # are created (relativ to boot_dir) # defaults to "vmlinuz vmlinuz.suse" # cd /boot # Execute the commande : mk_initrd / -k initrd-james.img vmlinuz-james linux:/boot # mk_initrd / -k initrd-james.img vmlinuz-james using "/dev/hda2" as root device (mounted on "/" as "reiserfs") creating initrd "//boot/initrd" for kernel "//boot/vmlinuz" (2.4.18-4GB) module reiserfs is "/lib/modules/2.4.18-4GB/kernel/fs/reiserfs/reiserfs.o" -> insmod reiserfs module ide-scsi is "/lib/modules/2.4.18-4GB/kernel/drivers/scsi/ide-scsi.o" -> insmod ide-scsi Concatenating splash picture size 800x600 to initrd... done. creating initrd "//boot/initrd.suse" for kernel "//boot/vmlinuz.suse" (2.4.18-4GB) module reiserfs is "/lib/modules/2.4.18-4GB/kernel/fs/reiserfs/reiserfs.o" -> insmod reiserfs module ide-scsi is "/lib/modules/2.4.18-4GB/kernel/drivers/scsi/ide-scsi.o" -> insmod ide-scsi Concatenating splash picture size 800x600 to initrd... done. If you're using lilo as bootmanager, you may want to run 'lilo' now. ######### END ######### Question 1 I want the command mk_initrd to use boot/vmlinuz-james and not boot/vmlinuz.suse How do I do this..? Question 2 I figure that I need to change the following lines in lilo.config so that my new kernal will load... image = /boot/vmlinuz image = /boot/vmlinuz.suse initrd = /boot/initrd.suse This this correct? Here is a vi of my lilo.conf vi /etc/lilo.conf boot = /dev/hda change-rules reset read-only menu-scheme = Wg:kw:Wg:Wg lba32 prompt timeout = 80 message = /boot/message image = /boot/vmlinuz label = linux root = /dev/hda2 vga = 788 initrd = /boot/initrd append = " hdc=ide-scsi" image = /boot/vmlinuz.suse label = failsafe root = /dev/hda2 vga = 788 initrd = /boot/initrd.suse append = "ide=nodma apm=off acpi=off hdc=ide-scsi" optional image = /boot/memtest.bin label = memtest86 TIA Ciao James Pearson E mail (mai) : james.pearson@wanadoo.fr E mail (bur) : james.pearson@wanadoo.com Web page: http://perso.wanadoo.fr/j.pearson/ What you make of your life is up to you. You have all the tools and resources you need.
On Sun, 20 Oct 2002 12:33:55 +0200
"jpearson3"
To all SuSe gurus,
I am trying to compile a new kernal on SuSe8 and I am having a few problems understanding what to do when I get to : mk_initrd . I want mk_initrd to use boot/vmlinuz-james that I created and not boot/vmlinuz.suse
Use the -k option of mk_initrd. Do a "mk_initrd -h" , there is no man page. -- use Perl; #powerful programmable prestidigitation
Hi , AFAICS ther is no "make modules" in your write up which needs to be done before modules_install Am Sonntag, 20. Oktober 2002 12:33 schrieb jpearson3:
To all SuSe gurus,
I am trying to compile a new kernal on SuSe8 and I am having a few problems understanding what to do when I get to : mk_initrd . I want mk_initrd to use boot/vmlinuz-james that I created and not boot/vmlinuz.suse
I am enclosing a HowTo that I wrote. Any comments or info would be appreciated...
######### START ######### # HowToCreateNewSuSE8 Kernal # Install kernel-source from SuSe CD's
# Check for the required packages rpm -q kernel-source ncurses-devel gcc make
# Expected results # kernel-source-2.4.18.SuSE-35 # ncurses-devel-5.2-283 # gcc-2.95.3-216 # make-3.79.1-292 # if not present - install them with ap-get # e.g. apt-get install ncurses-devel
# Copy suse kernal to /usr/src/linux cp -p /boot/vmlinuz.suse /usr/src/linux
# Create new kernal "-james" for Athlon using the commande "make menuconfig" make menuconfig
# Chose the correct Processor old: (X) 586/K5/5x86/6x86/6x86MX new: (X) Athlon/Duron/K7
# Modify File System Support # Added : <*> DOS FAT fs support <*> MSDOS fs support <*> UMSDOS: Unix-like file system on top of standard MSDOS fs <*> VFAT (Windows-95) fs support # Save Configuration to an Alternate File Name : vmlinuz-james # Do you wish to save your new kernel configuration? Yes
# The end of the menuconfig log sayes ... # *** End of Linux kernel configuration. # *** Check the top-level Makefile for alilo.conf.bakdditional configuration. # *** Next, you may run 'make bzImage', 'make bzdisk', or 'make install'.
# Check for new Makefile ls -trl /usr/src/linux/Makefile cp Makefile Makefile.bak
vi Makefile # Modified EXTRAVERSION old:EXTRAVERSION = new: EXTRAVERSION =james Saved and exited
# Run make bzImage make bzImage
linux:/usr/src/linux/arch/i386/boot # ls -trl bzImage -rw-r--r-- 1 root root 1012346 Oct 19 23:56 bzImage linux:/boot # ls -trl /usr/src/linux/arch/i386/boot/bzImage -rw-r--r-- 1 root root
# Copy to /boot cp -p /usr/src/linux/arch/i386/boot/bzImage /boot/vmlinuz-james cp -p /usr/src/linux/System.map /boot/System.map-james
# Run modules_install cd /usr/src/linux make modules_install
# Run mk_initrd # -k "kernel list" list of kernel images for which initrd files # are created (relativ to boot_dir) # defaults to "vmlinuz vmlinuz.suse" # cd /boot # Execute the commande : mk_initrd / -k initrd-james.img vmlinuz-james
linux:/boot # mk_initrd / -k initrd-james.img vmlinuz-james using "/dev/hda2" as root device (mounted on "/" as "reiserfs") creating initrd "//boot/initrd" for kernel "//boot/vmlinuz" (2.4.18-4GB) module reiserfs is "/lib/modules/2.4.18-4GB/kernel/fs/reiserfs/reiserfs.o" -> insmod reiserfs module ide-scsi is "/lib/modules/2.4.18-4GB/kernel/drivers/scsi/ide-scsi.o" -> insmod ide-scsi Concatenating splash picture size 800x600 to initrd... done. creating initrd "//boot/initrd.suse" for kernel "//boot/vmlinuz.suse" (2.4.18-4GB) module reiserfs is "/lib/modules/2.4.18-4GB/kernel/fs/reiserfs/reiserfs.o" -> insmod reiserfs module ide-scsi is "/lib/modules/2.4.18-4GB/kernel/drivers/scsi/ide-scsi.o" -> insmod ide-scsi Concatenating splash picture size 800x600 to initrd... done.
If you're using lilo as bootmanager, you may want to run 'lilo' now. ######### END #########
Question 1 I want the command mk_initrd to use boot/vmlinuz-james and not boot/vmlinuz.suse How do I do this..?
Question 2 I figure that I need to change the following lines in lilo.config so that my new kernal will load... image = /boot/vmlinuz image = /boot/vmlinuz.suse initrd = /boot/initrd.suse This this correct? Here is a vi of my lilo.conf vi /etc/lilo.conf boot = /dev/hda change-rules reset read-only menu-scheme = Wg:kw:Wg:Wg lba32 prompt timeout = 80 message = /boot/message image = /boot/vmlinuz label = linux root = /dev/hda2 vga = 788 initrd = /boot/initrd append = " hdc=ide-scsi" image = /boot/vmlinuz.suse label = failsafe root = /dev/hda2 vga = 788 initrd = /boot/initrd.suse append = "ide=nodma apm=off acpi=off hdc=ide-scsi" optional image = /boot/memtest.bin label = memtest86
TIA Ciao James Pearson E mail (mai) : james.pearson@wanadoo.fr E mail (bur) : james.pearson@wanadoo.com Web page: http://perso.wanadoo.fr/j.pearson/
What you make of your life is up to you. You have all the tools and resources you need.
Sent: Tuesday, October 22, 2002 3:50 PM Subject: Re: [SLE] HowToCreateNewSuSE8 Kernal (incomplete) AFAICS ther is no "make modules" in your write up which needs to be done before modules_install Yes, I know. It was the first of several attempts. I am getting closer. Here is my last one. It still needs some work though. # HowToCreateNewSuSE8 Kernal # Install kernel-source from SuSe CD's # Check for the required packages rpm -q kernel-source ncurses-devel gcc make # Expected results # kernel-source-2.4.18.SuSE-35 # ncurses-devel-5.2-283 # gcc-2.95.3-216 # make-3.79.1-292 # if not present - install them with ap-get # e.g. apt-get install ncurses-devel # Copy suse kernal to /usr/src/linux cp -p /boot/vmlinuz.suse /usr/src/linux cd /usr/src/linux make mrproper # Create new kernal "-james1" for Athlon using make menuconfig make menuconfig # Chose the correct Processor old: (X) 586/K5/5x86/6x86/6x86MX new: (X) Athlon/Duron/K7 # Modifed File System Support # Added : <*> DOS FAT fs support <*> MSDOS fs support <*> UMSDOS: Unix-like file system on top of standard MSDOS fs <*> VFAT (Windows-95) fs support # Save Configuration to an Alternate File Name : vmlinuz-james1 # Do you wish to save your new kernel configuration? Yes *** End of Linux kernel configuration. *** Check the top-level Makefile for additional configuration. *** Next, you must run 'make dep'. make dep make[1]: Entering directory `/usr/src/linux-2.4.18.SuSE' /usr/src/linux-2.4.18.SuSE/include/linux/modversions.h was updated make[1]: Leaving directory `/usr/src/linux-2.4.18.SuSE' make clean # Check for new Makefile ls -trl /usr/src/linux/Makefile cp Makefile Makefile.bak vi Makefile # Modified EXTRAVERSION old:EXTRAVERSION = new: EXTRAVERSION =james1 Saved and exited # Run make bzImage make bzImage # The end of the log sayes objcopy -O binary -R .note -R .comment -S compressed/bvmlinux compressed/bvmlinux.out tools/build -b bbootsect bsetup compressed/bvmlinux.out CURRENT > bzImage Root device is (3, 2) Boot sector 512 bytes. Setup is 4776 bytes. System is 962 kB warning: kernel is too big for standalone boot from floppy make[1]: Leaving directory `/usr/src/linux-2.4.18.SuSE/arch/i386/boot' ls -trl /usr/src/linux/arch/i386/boot/bzImage linux:/usr/src/linux # ls -trl /usr/src/linux/arch/i386/boot/bzImage -rw-r--r-- 1 root root 990834 Oct 21 22:46 /usr/src/linux/arch/i386/boot/bzImage # Copy to /boot cp -p /usr/src/linux/arch/i386/boot/bzImage /boot/vmlinuz-james1 cp -p /usr/src/linux/System.map /boot/System.map-james1 cd /usr/src/linux # Run make modules make modules make[1]: Entering directory `/usr/src/linux-2.4.18.SuSE/arch/i386/lib' make[1]: Nothing to be done for `modules'. make[1]: Leaving directory `/usr/src/linux-2.4.18.SuSE/arch/i386/lib' # Run modules_install make modules_install # The end of the log sayes cd /lib/modules/2.4.18james1-4GB; \ mkdir -p pcmcia; \ find kernel -path '*/pcmcia/*' -name '*.o' | xargs -i -r ln -sf ../{} pcmcia if [ -r System.map ]; then /sbin/depmod -ae -F System.map 2.4.18james1-4GB; fi # Run mk_initrd cd /boot # Execute the commande : mk_initrd / -h initrd-james1.img vmlinuz-james1 mk_initrd / -h "vmlinuz-james1" -i "initrd-james1" -s auto # The new module options ("vmlinuz-james1" and "initrd-james1"" not taken into account. # It is still the name "vmlinuz-james" cd /usr/src/linux mk_initrd / -h "vmlinuz-james1" -i "initrd-james1" -s auto # The end of the log sayes using "/dev/hda2" as root device (mounted on "/" as "reiserfs") creating initrd "//boot/initrd" for kernel "//boot/vmlinuz" (2.4.18james-4GB) module reiserfs is "/lib/modules/2.4.18james-4GB/kernel/fs/reiserfs/reiserfs.o" -> insmod reiserfs module ide-scsi is "/lib/modules/2.4.18james-4GB/kernel/drivers/scsi/ide-scsi.o" -> insmod ide-scsi Concatenating splash picture size 800x600 to initrd... done. creating initrd "//boot/initrd.suse" for kernel "//boot/vmlinuz.suse" (2.4.18-4GB) module reiserfs is "/lib/modules/2.4.18-4GB/kernel/fs/reiserfs/reiserfs.o" -> insmod reiserfs module ide-scsi is "/lib/modules/2.4.18-4GB/kernel/drivers/scsi/ide-scsi.o" -> insmod ide-scsi Concatenating splash picture size 800x600 to initrd... done. If you're using lilo as bootmanager, you may want to run 'lilo' now. # Modified lilo - one of several attempts # Added another new entry to lilo # image = /boot/vmlinuz" (2.4.18james-4GB) # label = failsafe # root = /dev/hda2 # vga = 788 # initrd = /boot/initrd # append = "ide=nodma apm=off acpi=off hdc=ide-scsi" # optional # Updated lilo /sbin/lilo -C /etc/lilo.conf # The end of the log sayes Warning: Int 0x13 function 8 and function 0x48 return different head/sector geometries for BIOS drive 0x80 Added linux * Added failsafe Added memtest86 # Reboot shutdown -r now
On Wednesday 23 October 2002 00.26, jpearson3 wrote:
# Copy to /boot # Run mk_initrd cd /boot # Execute the commande : mk_initrd / -h initrd-james1.img vmlinuz-james1 mk_initrd / -h "vmlinuz-james1" -i "initrd-james1" -s auto
This should be /sbin/mk_initrd -k vmlinuz-james1 -i initrd-james1 -s auto
# Modified lilo - one of several attempts # Added another new entry to lilo # image = /boot/vmlinuz" (2.4.18james-4GB)
You probably want to add an "image = /boot/vmlinuz-james1" as well
# label = failsafe # root = /dev/hda2 # vga = 788 # initrd = /boot/initrd
and an "initrd = /boot/initrd-james1" Anders
participants (4)
-
Anders Johansson
-
Dan Am
-
jpearson3
-
zentara