Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

as I've already wrote in the topic, I compiled a new Kernel with make defconfig, the bzImage is where it there, so is vmlinux.bin. I've installed modules with make modules_install.

Now, what is the next step? should I rename bzImage to my liking and put it into /boot? And how do I create an initramfs?

vmlinux.bin is executable, is that my Kernel?

I'm using GRUB, and I'm quite familiar with using and configuring it. But I'm having a hard time putting the kernel together.

share|improve this question
add comment

1 Answer

up vote 2 down vote accepted

Once you've made make modules_install, the next steps are:

  • make install this will take care to move the bzImage, System.map and .config to /boot with the right names, e.g. config-2.6.39-rc1, System.map-2.6.39-rc1, etc...

  • the next step is to build the initramfs. That depends on the distro. On a debian-like distro, it would be mkinitramfs -c -k 2.6.39-rc1. A RH like distro that would be mkinitrd /boot/initrd-2.6.39-rc1.img 2.6.39-rc1

  • Add the new kernel to your boot loader, on a modern distro, that would be a simple update-grub

Note: make defconfig may generate a kernel that lacks the proper drivers for your hardware. Safer alternatives would be to either copy the .config of your currently running kernel (look in /boot or /proc/config.gz), or to manually determine the necessary drivers by 'hand' and running a make xconfig

Note2: -rc1 is very fresh, expect it to contain bugs.

share|improve this answer
    
I know about freshness, etc. This is just a test, though. I'll configure with make gconfig later. –  polemon Apr 5 '11 at 6:47
    
Wouldn't using high-level distribution-specific tools eg. Debian's kernel-package (though it seems to not have the favor of Debian's kernel packaging team) be more efficient? This would automate the lower level steps. –  Faheem Mitha Apr 5 '11 at 9:18
    
@Faheem I does, but I personaly found easier to learn the low level steps, so that you don't have to relearn everything every time you switch to another distro. I guess it depends on how many different distros you deal with on a regular basis. –  Frederik Deweerdt Apr 5 '11 at 22:01
    
@Frederik: good point –  Faheem Mitha Apr 5 '11 at 22:30
    
Also, this Kernel is not meant to make too much sense. It's just for testing out stuff. –  polemon Apr 6 '11 at 1:38
show 3 more comments

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.