Solved

how to compile a 2.4 kernel with module support?

Posted on 2004-04-01
4
350 Views
Last Modified: 2013-12-15
i installed a kernel source 2.4.24 on my redhat linux 9 machine which have kernel 2.4.20.
when i start 'make menuconfig' and do fine tune for my new kernel 2.4.24 and compile it.
it compiled successfuly.i then boot it. but while booting it gives iptables module error and
display that service FAILED. same thing for USB devices. the USB file sytem starts successfully
but then next it gives USB mouse, hdd, keyboard initialization FAILED.
how can i solve this. the kernel boots then very well with remaining services configured.
Also when i check lsmod it gives very less module info 1 or 2 .but when i boot to my default installation it gives me 15 to 20 entries with lsmod command. how can i made it same for my newly configured kernel?

0
Comment
Question by:b123coder
  • 2
4 Comments
 
LVL 9

Expert Comment

by:Alf666
ID: 10734568
Two choices :

1) By hand. For each of these modules, under menuconfig, ask for a module instead of just "enabled" (the "m" choice).

2) You have to take the 2.4.20 config. It should be in : /usr/src/linux-2.4/configs

cd /usr/src/linux (or wherever you compile your kernel).

backup the config that took you so long to create :
cp .config ~/my-kernel-config

make mrproper

copy the current config to the .config file

and do :

make oldconfig

The process will ask you some questions about the new kernel parameters.

Then, you can make dep ; make bzImage ; make modules ; make modules_install

You can take this as a base config for customizing your kernel.
0
 

Expert Comment

by:navijr
ID: 10759585
if you find that your 2.4.20 kernel configuration from RH 9 install is well enough for you, then better use that config file.

cp /boot/kernel(something).config /usr/src/linux-2.4.24
which means: copy kernel.config file to the newly decompressed folder of 2.4.24.. then...

make menuconfig as you said, look for the modules you want to ADD, like if you have plans to purchase additional hardware for it, or to enable networking features in the near future, then install it. (instructions are there, its just "M") and then...

make dep ; make bzImage ; make modules

then wait for errors, if there are none, then move on

make modules_install

and of course copy the bzimage of 2.4.24 from /usr/src/linux-2.4.24/i386/boot/bzImage and let your Linux boot manager use that, much better if you ADD it up first inorder to retain your original kernel.

if you're well with the newly compiled kernel, then just comment it out from your boot manager and thats enough...
0
 

Author Comment

by:b123coder
ID: 10763279

can any body tell me which minimum options should i select in USB file system in make menuconfig to use USB devices.
cause rh9 have everything enbled in that menu. I want only minumum that meance to run my usb printer support in kernel only.
0
 
LVL 9

Accepted Solution

by:
Alf666 earned 50 total points
ID: 10764144
Depends on your hardware. You'd need (at least) :

I suggest doing all as modules.

CONFIG_USB=m
CONFIG_USB_UHCI=m
CONFIG_USB_OHCI=m
CONFIG_USB_PRINTER=m

There's a good chance it's enough. But, if you really want to compile the minimum, it'll take you time to identify everything.
0

Featured Post

Free learning courses: Active Directory Deep Dive

Get a firm grasp on your IT environment when you learn Active Directory best practices with Veeam! Watch all, or choose any amount, of this three-part webinar series to improve your skills. From the basics to virtualization and backup, we got you covered.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Network Interface Card (NIC) bonding, also known as link aggregation, NIC teaming and trunking, is an important concept to understand and implement in any environment where high availability is of concern. Using this feature, a server administrator …
I am a long time windows user and for me it is normal to have spaces in directory and file names. Changing to Linux I found myself frustrated when I moved my windows data over to my new Linux computer. The problem occurs when at the command line.…
Learn how to navigate the file tree with the shell. Use pwd to print the current working directory: Use ls to list a directory's contents: Use cd to change to a new directory: Use wildcards instead of typing out long directory names: Use ../ to move…
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.

789 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question