Linux - GeneralThis Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Hi folks,
1. I've downloaded (and built (successfully(more-or-less))) the Linux 2.4.1 kernel. I chose to include everything in the kernel image, even if it can be made into a module. Is this a bad thing? If so, why? If not, why does the documentation say that you "build essential drivers into the kernel and compile the rest as modules".
2. The documentation recommends using gcc 2.95.3 (or thereabouts... don't remember exactly which version). Is there a problem using a later (stable) build of gcc to build my kernel, like the newly-released gcc 3.0?
Most people don't need everything, They might later on but not now. Later they can load a module if the kernel will support it. If you change out something in your system like a soundcard or nic if it is a module then the new card can be loaded as a module and the one you took out unloaded. This is why it is a good idea to load some of your nonessential hardware as a module.
So if you think you will need it later choose the module option. If you know you will never need it why fatten up the kernel.
For example, I have no plan to go out and buy a Gravis Ultrasound card so why put it in the kernel.
The smaller it is the faster.
Last edited by DavidPhillips; 06-25-2001 at 02:51 AM.
When I said everything, I didn't mean every blessed thing the kernel sources contain. I meant everything relevant to my hardware and what I plan to use (eg. I chose not to include NFS support, etc.). I don't add new hardware everyday, and when I do, I'm sure I can spend the 15 mins it takes to recompile.
Wouldn't loading modules etc. etc. impose extra overhead over having it simple compiled into the kernel?
There is an overhead to loading a module but if you're looking to save memory then its probably worth it, although the amount you'll save won't be amazing compared to the available memory in a modern system.
As for smaller being faster I'm not sure - someone said this a little while ago (can't remember who) on the forum and I asked them to justify this (becuase I'm curious not because I'm trying to catch them out!) but don't think I got a response. I don't see why a kernel with code in it that isn't used would be slower than a kernel that doesn't have the code there - the only advantage I can see is really clear is the memory saving. Any justification DavidPhillips?
I tend to just chuck the things I deem as non-essential in as modules and let them autoload... Saying this if you miss something like floppy support I've had problems in the past where I've lost access to the partition holding my modules and then needed to gain access to the floppy disk for something to do with the repair, but couldn't as the module wasn't there
Thanks for the input, I might have a hunt around the web later and see if I can turn up anything specific. Hadn't really considered the boot time but yeah, a smaller kernel would uncompress and load faster so thats one point where is makes sense.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.