Linux - KernelThis forum is for all discussion relating to the Linux kernel.
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.
I am attempting to configure my own kernel and am struggling to to find a review of the process that I find suitable. Many sites seem to either tell you the mechanics of which commands to issue in order to compile a kernel, or go into detail explaining each and every config option.
The sources I've been looking at to guide me through the process are:
Whilst I now feel reasonably confident in configuring and compiling the kernel for the particular hardware in the machine, I feel I am stabbing in the dark when it comes to configuring the rest of the kernel. I am trying to set up a web/nfs server with ssh access. In the vein of 3) above, are there any site/books walking through standard recipes for such servers that anyone could recommend?
Little thing I do is cd to the kernel make mrpropper then I go to my /boot/ folder and I copy the config file of the kernel I am using at the moment to the kernel source. then I rename it (.confg) ---->.<---- dot config. then type "make oldconfig" Default all questions based on the contents of
your existing ./.config file and asking about
new config symbols.
then any new parts of the kernel then you can answer them the way you want. then do make make install and you must do a make modules_install if it is a new kernel. if you are using lilo then make sure you reconfigure lilo to boot the old kernel before rebooting because the new symlink point to the new kernel and if the new one fails you will need to boot the old kernel.
This has been a fail safe remedy for vinilla kernels I have great luck with this . if your linux uses and initrd.img then make sure you build before you try to boot it.
I feel I am stabbing in the dark when it comes to configuring the rest of the kernel.
Nothing wrong with that - will probably encourage you to meander through the config and "learn as you go". I sure we all did it.
Quote:
I am trying to set up a web/nfs server with ssh access. In the vein of 3) above, are there any site/books walking through standard recipes for such servers that anyone could recommend?
I can't imagine a standard/default config that has all your hardware defined would need any "tweaking". Better to look for product "how-tos" - say for NFS - and see if any particular kernel options are recommended/necessary. For someone starting out, I don't know that I'd necessarily recommend Gregs approach (in that chapter). Good to know the concept, but he is after all one of the kernel maintainers - going to that depth isn't normally necessary for mere mortals.
The kernel is (very) fluid - finding a "current" guide will be nigh on impossible. Really all you can do is either copy a working config as above, or use a default one, and adapt as required.
Thanks for the quick reply! I've been doing what you suggested with some success. I used Slackware's smallest kernel and have been adjusting that to meet my needs. However, this seems to be a slightly messy way of going about things, in that there is always the chance that I may leave something included that needn't be there, where as if I start from scratch then then I only include what is required - two sides of the same coin I guess!
Anyway, if you have any recipes or links to, I would love to hear from you.
I did one from scrath ten years ago and I still have that config around some where. build a stock kernel with alot of stuff you do not need like syg00 said. but hey if have you seen the size of todays kernel. just to read the kerenel is a small book lol. but Once you build one get it working. then you can try diferent stuff. the 2.2 and 2.4 kernel are big but the 2.6. wow. even Linus doesn't do it. I start fat then slim it down no easy way I know.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.