LinuxQuestions.org
View the Most Wanted LQ Wiki articles.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software > Linux - Kernel
User Name
Password
Linux - Kernel This forum is for all discussion relating to the Linux kernel.

Notices

Reply
 
Search this Thread
Old 01-06-2009, 06:02 PM   #1
ceashton
Member
 
Registered: Nov 2006
Distribution: Slackware 12.2
Posts: 36

Rep: Reputation: 15
kernel configuration


Hello all,

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:

1) http://wiki.linuxquestions.org/wiki/...g_linux_kernel
2) http://howto.wikia.com/wiki/Howto_co...e_Linux_kernel

and in particular, I found this book/site particularly helpful:

3) http://www.kernel.org/pub/linux/kern...n_pdf/ch07.pdf

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?

Many thanks in advance,

Chris
 
Old 01-06-2009, 07:09 PM   #2
Drakeo
Senior Member
 
Registered: Jan 2008
Location: Urbana IL
Distribution: Slackware, Slacko,
Posts: 2,440
Blog Entries: 3

Rep: Reputation: 182Reputation: 182
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.
 
Old 01-06-2009, 07:56 PM   #3
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 12,043

Rep: Reputation: 970Reputation: 970Reputation: 970Reputation: 970Reputation: 970Reputation: 970Reputation: 970Reputation: 970
Quote:
Originally Posted by ceashton View Post
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.
 
Old 01-06-2009, 07:59 PM   #4
ceashton
Member
 
Registered: Nov 2006
Distribution: Slackware 12.2
Posts: 36

Original Poster
Rep: Reputation: 15
Hi Drakeo,

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.

Kind regards,

Chris
 
Old 01-06-2009, 08:45 PM   #5
Drakeo
Senior Member
 
Registered: Jan 2008
Location: Urbana IL
Distribution: Slackware, Slacko,
Posts: 2,440
Blog Entries: 3

Rep: Reputation: 182Reputation: 182
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.

Last edited by Drakeo; 01-06-2009 at 08:47 PM.
 
  


Reply

Tags
compile, config, make


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Diff between Kernel Compilation and Kernel Configuration ?? vikas027 Linux - Enterprise 8 09-20-2008 01:01 AM
Kernel configuration tusharb Linux - Software 3 04-17-2008 02:55 AM
New FAQ topic: Should I edit my kernel configuration?/Should I build a custom kernel? chort *BSD 10 09-10-2004 11:15 PM
Kernel Configuration berti Linux - Newbie 2 01-22-2004 04:57 PM
kernel configuration Syncrm Linux - General 2 03-07-2002 06:56 PM


All times are GMT -5. The time now is 01:44 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration