1,105,556 Community Members

Help me to edit linux kernel

Member Avatar
touchbun.hun
Newbie Poster
2 posts since Nov 2012
Reputation Points: 0 [?]
Q&As Helped to Solve: 0 [?]
Skill Endorsements: 0 [?]
 
0
 

I want to edit linux os, How should i edit?
please help me!

Member Avatar
caperjack
I hate 20 Questions
13,852 posts since Aug 2003
Reputation Points: 875 [?]
Q&As Helped to Solve: 902 [?]
Skill Endorsements: 69 [?]
Team Colleague
 
0
 

check this out
Click Here

Member Avatar
L7Sqr
Veteran Poster
1,006 posts since Feb 2011
Reputation Points: 179 [?]
Q&As Helped to Solve: 168 [?]
Skill Endorsements: 11 [?]
 
0
 

It really depends on what you want to change. You will have to be more specific. In general, you find the source code for the part that you want to change, modify it to suit your needs, recompile and deploy.

Member Avatar
rubberman
Senior Poster
3,999 posts since Mar 2010
Reputation Points: 513 [?]
Q&As Helped to Solve: 501 [?]
Skill Endorsements: 87 [?]
 
0
 

I presume you want to reconfigure your kernel, perhaps to remove unneeded drivers, and such? You need to visit www.tldp.org and your Linux distribution's web site for "building a kernel" FAQ. In any case, you need to do the following at a minimum:

  1. Download and install the kernel sources.
  2. Go to the source code root directory.
  3. Run the command "make menuconfig" or "make xconfig".
  4. Run the make command to build the kernel.
  5. Run "make install" as root the install the kernel and drivers.

Do 1-4 as a regular user. #5 needs to be done as root, or sudo.

The "make menuconfig" in #3 will present you with a text-based (ncurses) form to edit the kernel configuration. The "make xconfig" will present you with an X-Windows based GUI to do the same. I prefer the xconfig myself since it has more useful help information.

Doing a manual kernel configuration is mostly useful when you need non-standard file system drivers automatically installed, or if you want to configure a minimal kernel for an embedded device or other small system.

All that said - RTFM! DO NOT DO THIS WITHOUT PREPARATION! Also, study the documentation for your boot loader, and remember that the above comments and instructions may NOT be complete for your distribution! Caveat user! :-)

FWIW, I only do this now for embedded systems that I am building. The last custom kernel that I built for my workstation/server was 3-4 years ago, though I have done this for specialized servers many times since then. Usually, if you need some driver installed that is not part of the default kernel or installation, that can be done by building the driver and installing it with the modprobe or insmod commands. So, exactly why do you want to "edit" your kernel?

You
This article has been dead for over three months: Start a new discussion instead
Post:
Start New Discussion
Tags Related to this Article