Hi experts, may I ask someone to take a look at the steps below I did to compile new kernel and let me know whether it looks ok before I reboot my PC? I've done this first time so I'm not very certain I did not miss anything and be able to boot old kernel in case new one does not work. Thx, Martin 1. uname -r to find out my current kernel version 2. install kernel source rpm 3. cp /boot/vmlinuz-$(uname -r) /boot/vmlinuz.old 4. cp /boot/initrd-$(uname -r) /boot/initrd.old 5. cd /usr/src/linux 6. zcat /boot/config > .config 7. make oldconfig 8. make xconfig - I did my changes here 9. make clean bzImage 10. make modules 11. INSTALL_PATH=/boot make install 12. make modules_install 13. vim /boot/grub.menu.lst to add title Linux-old kernel (hd0,1)/boot/vmlinuz.old root=/dev/hda2 vga=0x314 splash=silent apm=on acpi=off desktop resume=/dev/hda1 showopts initrd (hd0,1)/boot/initrd 14. my /boot looks like this now: drwxr-xr-x 3 root root 664 2005-04-10 13:39 . drwxr-xr-x 21 root root 488 2005-04-09 05:50 .. -rw-r--r-- 1 root root 512 2004-08-26 17:16 backup_mbr lrwxrwxrwx 1 root root 1 2005-02-21 15:45 boot -> . -rw-r--r-- 1 root root 57530 2004-12-22 07:51 config-2.6.8-24.10-default drwxr-xr-x 2 root root 512 2005-04-10 18:44 grub lrwxrwxrwx 1 root root 26 2005-04-10 13:39 initrd -> initrd-2.6.8-24.10-default -rw-r--r-- 1 root root 1181888 2005-04-10 13:39 initrd-2.6.8-24.10-default -rw-r--r-- 1 root root 1178088 2005-04-09 23:17 initrd.old -rw-r--r-- 1 root root 107008 2004-12-17 11:37 message -rw-r--r-- 1 root root 79151 2004-12-22 07:51 symvers-2.6.8-24.10-i386-default.gz -rw-r--r-- 1 root root 747406 2005-04-10 13:39 System.map-2.6.8-24.10-default -rw-r--r-- 1 root root 739824 2004-12-22 07:40 System.map-2.6.8-24.10-default.old -rw-r--r-- 1 root root 1857373 2004-12-22 07:51 vmlinux-2.6.8-24.10-default.gz lrwxrwxrwx 1 root root 27 2005-04-10 13:39 vmlinuz -> vmlinuz-2.6.8-24.10-default -rw-r--r-- 1 root root 1595169 2005-04-10 13:39 vmlinuz-2.6.8-24.10-default -rw-r--r-- 1 root root 1556643 2004-12-22 07:40 vmlinuz-2.6.8-24.10-default.old -rw-r--r-- 1 root root 1556643 2005-04-09 23:16 vmlinuz.old __________________________________ Do you Yahoo!? Yahoo! Small Business - Try our new resources site! http://smallbusiness.yahoo.com/resources/
On Sun, 2005-04-10 at 18:49 -0700, Martin wrote:
Hi experts,
may I ask someone to take a look at the steps below I did to compile new kernel and let me know whether it looks ok before I reboot my PC? I've done this first time so I'm not very certain I did not miss anything and be able to boot old kernel in case new one does not work.
Thx, Martin
1. uname -r to find out my current kernel version 2. install kernel source rpm 3. cp /boot/vmlinuz-$(uname -r) /boot/vmlinuz.old 4. cp /boot/initrd-$(uname -r) /boot/initrd.old 5. cd /usr/src/linux 6. zcat /boot/config > .config 7. make oldconfig 8. make xconfig - I did my changes here 9. make clean bzImage 10. make modules 11. INSTALL_PATH=/boot make install 12. make modules_install
What about the old kernel modules, make sure they are still around. -- Ken Schneider UNIX since 1989, linux since 1994, SuSE since 1998 "The day Microsoft makes something that doesn't suck is probably the day they start making vacuum cleaners." -Ernst Jan Plugge
On Monday 11 April 2005 03:49, Martin wrote:
Hi experts,
may I ask someone to take a look at the steps below I did to compile new kernel and let me know whether it looks ok before I reboot my PC? I've done this first time so I'm not very certain I did not miss anything and be able to boot old kernel in case new one does not work.
Thx, Martin
Martin I have done this quite a lot and the SuSE kernel make process is not quite standard. The following works for SuSe 9.2 but not 9.1. My steps are : 1 install kernel sources 2 do an update from a SuSe update server (make sure that kernel sources match installed kernel which may have already been updated.) 3 cd /usr/src/linux 4 make cloneconfig (copies the .config file from /proc/config.gz which is the config file that is guaranteed to correspond to the currently booted kernel) 5 make menuconfig ( Use the menus to set the processor type. Change the localversion name in the General setup options menu to 'local') Some may tell you to change the configuration name in the build setup submenu from 'default' to 'local'. I used to do this on previous versions of SuSe and RedHat but on 9.2 it seems to confuse the rest of the make process. 6 make 7 make modules_install must be before 'make install' 8 make install (This also builds the initrd file correctly which is why it has to be *after* the 'make modules_install' step) 9 you now should have 3 files in /boot initrd-.....defaultlocal vmlinuz-....defaultlocal System.map.....defaultlocal 10 Execute cd /boot ln -s vmlinuz....defaultlocal vmlinuz.local ln -s initrd....defaultlocal initrd.local rm vmlinuz;ln -s vmlinuz....default vmlinuz rm initrd; ln -s initrd.....default initrd where .... is the version of the kernel. 11 Edit /boot/grub/menu.lst and add a stanza identical to the default stanza but referring to vmlinuz.local and initrd.local. You can now still boot the original kernel if things have gone awry but the new kernel can be booted by selecting the correct boot menu option. PaulH -- _____________________________________________________________________ / Painting, n.: The art of protecting flat surfaces from the weather, \ \ and exposing them to the critic. -- Ambrose Bierce / --------------------------------------------------------------------- \ ^__^ \ (==)\_______ (__)\ )\/\ ||----w | || || -- Paul Hewlett (Linux #359543) Tel: +27 21 852 8812 Cel: +27 72 719 2725 Fax: +27 86 672 0563 --
participants (3)
-
Ken Schneider
-
Martin
-
Paul Hewlett