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.
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.
View Poll Results: How many times did you compile your kernel?
I have compiled a kernel about 5-6 times for gentoo. And I did it once for slackware 3 days back but wasn't so successful then.
Will be compiling a lot kernels in the days to come.
If the kernel is for the same machine, when you compile for another distro you need not start from scratch all over again. At the worst, just save your .config file, untar new kernel source, throw that old .config file in the newly created ./linux-2.6.x.y/ directory, then issue:
make silentoldconfig
make
cp System.map /boot/System.map-2.6.x.y ; ln -sf /boot/System.map-2.6.x.y /boot/System.map
make modules_install
cp arch/i386/boot/bzImage /boot/vmlinuz-2.6.x.y
edit /etc/lilo.conf and create a new section for your new kernel (leave the old one in place as a fallback option)
lilo
reboot
and enjoy your shiny new Linux kernel
Between my desktop and laptop, I've dont well over 50. My laptop runs 2.6.16.13 (just upgraded from 2.6.13 yesterday) with a slightly modified kernel.
My desktop's kernel is heavily modified by me. It's really really small now, which I am happy about. I'm not that great with Linux yet, but I have a LOT of spare time so I thought why not make an uber kernel?
During the last 5 months, I've compiled my kernel way over 20 times - mainly because I have always had a new bit of hardware to focus on, and I prefer having most things build-in - in fact the only modules i have are:
- A buggy and obsolte webcam driver
- stir4200 IrDA module, necessary for irattach and co.
- broadcom bluetooth chip
- slmodem, to get my winmodem (yes, a winmodem) working
- snd_intel8x0m, necessary for slmodemd (daemon for slmodem)
- ipw2200 wireless network
First time i compiled my own kernel? 2.6.14, to be able to use my 802.11G wifi...
Now running 2.6.16-mm1... way behind, now it's 2.6.16.14 :-)
I'll upgrade to 2.6.17 when it'll be stable, to get SDHCI (secure digital & mmc card host) in the main kernel tree...
hi i have been compiling my kernel i think i have done it some 50 to 60 times i think but still im not sure of the steps so can any one provide me exact steps plz..........
Perhaps a mistake in between
don't forget to copy the System.map file to /boot/System.map[version], a easy mistake to do.
that and update and run lilo (if nessessary) after copying the bzImage.
Are you guys too fond of making things complicated?
Just type "make install" after completing compilation. Everything would be copied to the right place and it will even edit your grub.conf correctly.
Are you guys too fond of making things complicated?
Just type "make install" after completing compilation. Everything would be copied to the right place and it will even edit your grub.conf correctly.
Wrong. You have a commercial distribution listed as your Linux distro, and someone may have hacked "make_install" to do so, but normally it does not. And most distros don't even use grub -- they use LiLO.
There is an "install" target in the official linux kernel makefiles (at least since 2.6.14, that's when i started compiling), and it seems to work at least in debian-based distributions and in fedora core 4... < > don't tell me you think debian is a commercial distro </ > ... and then you just have to edit your bootloader's config file, using a special program or just any plain old text editor.
If it doesn't work with your distribution, you might need to compile some packages or download it using your package manager: when I type "make help" in my kernel's sources' path, I see that ~/bin/installkernel or /sbin/installkernel is necessary.
Edit: and it's in the i386-arch-specific target list
A "debian-based distributions" is not the same as Debian, nor did anyone but you in this thread mention Debian and commercial distro in the same post.
In the source of linux-2.6.16.14 I see absolutely nothing about GrUB. What I do see in README is this:
Code:
- Do a "make" to create a compressed kernel image. It is also
possible to do "make install" if you have lilo installed to suit the
kernel makefiles, but you may want to check your particular lilo setup first.
And in that Makefile I see nothing to adjust any bootloader on it's own.
IMO you have to edit files to make that happen, no matter which bootloader you have. It is not possible with Kernel.org sources to
Quote:
Just type "make install" after completing compilation. Everything would be copied to the right place and it will even edit your grub.conf correctly.
-- unless someone has edited the bootloader to suit the Makefile.
The reason I'm even carrying on this silly argument is because newbies who don't know any better will read this thread, follow erroneous advice, and then wonder what happened.
Slackware doesn't have any hacked scripts included in the distro -- everything is pristine. Therefore, if you follow what was posted by debasish_5849 you will reboot with the same kernel(s) you had before. Just trying to keep a little sanity in the process we're discussing here.
Last edited by Bruce Hill; 05-07-2006 at 08:20 AM.
nano/pico/emacs/vi /etc/lilo.conf
[edit the stuff]
lilo
<<OR>>
nano/pico/emacs/vi /boot/grub/menu.lst (or /boot/grub/grub.conf)
[edit the stuff]
reboot.
Always have a backup kernel, never overwrite your only functional kernel. Have knoppix in hand, have a kernel build handbook if new to compilling kernels, and nothing else is nessessary that I know of...
make install overwrites the current kernel, and only works with lilo as far as 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.