Sponsored Content
Full Discussion: kernel recompilation
Operating Systems Linux kernel recompilation Post 55164 by TioTony on Saturday 4th of September 2004 05:09:48 PM
Old 09-04-2004
Here is my cheat-sheet for recompiling the linux kernel.

1. Install the kernel source "rpm -ivh kernel-source-<kernel_version>.i386.rpm" ".
2. cd /usr/src/linux-2.4 (or what ever version the /usr/src/linux-#.# dir is)
3. Run 'make mrproper'
4. Run 'make oldconfig'
5. Run 'TERM=vt100'
6. Run 'export TERM'
7. Run 'make menuconfig'. Change whatever you want to change at this point.
8. Run 'make dep'
9. Run 'make clean'
10. vi Makefile, update the version,call it something logical.
11. Run 'make bzImage'
12. Run 'make modules'
13. Run 'make modules_install'
14. Run 'make install'
15. Run 'mkinitrd /boot/initrd-<custom_version>.img <kernel version>' like this:
mkinitrd /boot/initrd-2.4.9-e.5LUN.img 2.4.9-e.5smp
16. (Do this only if you are using lilo) vi /etc/lilo.conf, create a new entry like this:

image=/boot/vmlinuz-2.4.20-8-custom
label=2.4.20-8-custom
initrd=/boot/initrd-2.4.20-8-custom.img
read-only
append="root=LABEL=/

Be sure to replace the version info with the custom version you created.
17. (Do this only if you are using lilo) If you are using lilo, run 'lilo'
18. (Do this only if you are using grub) vi /etc/grub.conf, create a new entry like this:

title Red Hat Linux (2.4.20-8-custom)
root (hd0,0)
kernel /boot/vmlinuz-2.4.20-8-custom ro root=LABEL=/
initrd /boot/initrd-2.4.20-8-custom.img

Be sure to replace the version info with the custom version you created. Be sure to have the correct root location. It may be easiest to copy an existing section and just replace the stuff you changed.
19. reboot, you should see the new version in the boot list.

To troubleshoot the specific hotplug issue you are having I would possibly try a different approach:

1. run 'depmod -a'
2. run 'modprobe hotplug'
3. run step 15 from above.

This may give you more info about why you are having problems specific to hotplug. Once you figure out the hotplug problems, then go back to the above procedure.
 

9 More Discussions You Might Find Interesting

1. Red Hat

kernel 2.6.18

Again same issue with new kernel 2.6.18.1 root@world # iptables -L modprobe: QM_MODULES: Function not implemented modprobe: QM_MODULES: Function not implemented modprobe: Can't locate module ip_tables iptables v1.2.8: can't initialize iptables table `filter': iptables who? (do you... (10 Replies)
Discussion started by: prashant_ohol
10 Replies

2. Linux

Kernel panic - not syncing: cannot execute a PAE-enabled kernel on PAE-less CPU

ok so I just installed fedora core 6 on my dell inspiron 700m and I go to boot into linux and I get this error. Has anyone seen this before? I also had XP Pro and Vista installed on this pc prior to putting fedora core 6 on the machine. I'm trying to setup a triple boot system. Please Help... (2 Replies)
Discussion started by: dave043
2 Replies

3. Programming

kernel-kernel call communication

hi all! i have developed a mechanism in system.c to count how many times each kernel call is called. The results are held in an array in system.c . What i want to do is to create a new kernel call which will print this array. I need help in passing the array from system.c to the new kernel call. ... (5 Replies)
Discussion started by: aureliano
5 Replies

4. SuSE

max number of slabs per kernel module (kernel 2.6.17, suse)

Hi All, Is there a max number of slabs that can be used per kernel module? I'm having a tough time finding out that kind of information, but the array 'node_zonelists' (mmzone.h) has a size of 5. I just want to avoid buffer overruns and other bad stuff. Cheers, Brendan (4 Replies)
Discussion started by: Brendan Kennedy
4 Replies

5. AIX

How to convert a partition usin 64 bits kernel to 32 bits kernel?

Hello there: I know that exist a procedure to convert an OS using 32bits kernel to 64 bits kernel. But, exist a procedure to convert an OS using 64bits to 32 bits kernel? Please help me. Regards. (2 Replies)
Discussion started by: GEIER
2 Replies

6. Linux

Supermicro(dual core) server getting rebooted after "decompressing the kernel;booting the kernel" me

supermicro(dual core) server getting rebooted after "decompressing the kernel;booting the kernel" message comes. I tried giving acpi=off to the kernel command line but same problem.It shows everything ok and no problem with memory and processors and power supplies.Wt could be the reason? It has... (1 Reply)
Discussion started by: pankajd
1 Replies

7. Solaris

Which file is read by kernel to set its default system kernel parameters values?

Hi gurus Could anybody tell me which file is read by kernel to set its default system kernal parameters values in solaris. Here I am not taking about /etc/system file which is used to load kernal modules or to change any default system kernal parameter value Is it /dev/kmem file or something... (1 Reply)
Discussion started by: girish.batra
1 Replies

8. Red Hat

How does the kernel know where is /etc/ ?

If I create some hard disk partitions: /boot, /, /usr, /tmp ... , of cause the kernel is in the /boot partition, /etc/fstab is in the / partition not in /boot partition, when the system boot, how does the kernel know where is the / partition? Or I create a separated partition: /etc, can the... (7 Replies)
Discussion started by: haixiao_liu
7 Replies

9. Linux

Unload kernel module at boot time (Debian Wheezy 7.2, 3.2.0-4-686-pae kernel)

Hi everyone, I am trying to prevent the ehci_hcd kernel module to load at boot time. Here's what I've tried so far: 1) Add the following line to /etc/modprobe.d/blacklist.conf (as suggested here): 2) Blacklisted the module by adding the following string to 3) Tried to blacklist the module... (0 Replies)
Discussion started by: gacanepa
0 Replies
LINUX-VERSION(1)					      General Commands Manual						  LINUX-VERSION(1)

NAME
linux-version - operate on Linux kernel version strings SYNOPSIS
linux-version compare VERSION1 OP VERSION2 linux-version sort [--reverse] [VERSION1 VERSION2 ...] linux-version list [--paths] DESCRIPTION
linux-version operates on Linux kernel version strings as reported by uname -r and used in file and directory names. These version strings do not follow the same rules as Debian package version strings and should not be compared as such or as arbitrary strings. compare VERSION1 OP VERSION2 Compare version strings, where OP is a binary operator. linux-version returns success (zero result) if the specified condition is satisfied, and failure (nonzero result) otherwise. The valid operators are: lt le eq ne ge gt sort [--reverse] [VERSION1 VERSION2 ...] Sort the given version strings and print them in order from lowest to highest. If the --reverse option is used, print them in order from highest to lowest. If no version strings are given as arguments, the version strings will instead be read from standard input, one per line. They may be suffixed by arbitrary text after a space, which will be included in the output. This means that, for example: linux-version list --paths | linux-version sort --reverse will list the installed versions and corresponding paths in order from highest to lowest version. list [--paths] List kernel versions installed in the customary location. If the --paths option, show the corresponding path for each version. AUTHOR
linux-version and this manual page were written by Ben Hutchings as part of the Debian linux-base package. 30 March 2011 LINUX-VERSION(1)
All times are GMT -4. The time now is 02:32 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy