Linux - HardwareThis forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?
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.
Hi could anyone tell me the procedure for remvoing a custom kernel ?? I built one and now I want to remove it since my driver appears to work in the deafult. Please give me the steps/commands.
Thank you.
Click here to see the post LQ members have rated as the most helpful post in this thread.
IMO, the easiest way for the newbie is to boot into the kernel you want to use and then use the synaptic package manager to remove the one you don't want.
If the new kernel was built from source code (and not installed from a .deb file or Synaptic), then it can't be removed using Yum. Instead one should just be able to boot the kernel you want to use, then just remove the old kernel files from /boot/. One can also remove the _old_ kernel source from /usr/src/ if it's not needed, but if the modules were compiled against this custom kernel, make sure they work with your other kernel before removing the custom one. I'm pretty sure kernel.org has some information about all this (should be in the README file that comes along the kernel source code, too), and if you haven't yet, it's a good idea to do a quick search from the web.
Distribution: Distribution: RHEL 5 with Pieces of this and that.
Kernel 2.6.23.1, KDE 3.5.8 and KDE 4.0 beta, Plu
Posts: 5,700
Rep:
For manually remove of customed compiled kernels.
Whether using grub or lilo you need to remove the section of that kernel from it. Grub you need to edit /boot/grub/grub.conf or 1st.menu and save the file. Lilo I forget how to do that. I know after edit you need to run the command lilo.
Remove the kernel image, system.map, and initrd that matches the kernel version to remove in /boot.
Remove the kernel source from /usr/src.
And last remove the /lib/modules/<kernel-version-of-modules>
After that, execute sudo update-grub. The grub entries will be updated automatically as its scripts inside /etc/grub.d will automatically detect files inside /boot then update accordingly. Note that /boot/grub/grub.cfg is not meant to be directly edit as noted inside the file as "DO NOT EDIT THIS FILE".
It might be in 2007 things might be different from now. But yeah, I just add this updated info for later new users reading this.
Whether using grub or lilo you need to remove the section of that kernel from it. Grub you need to edit /boot/grub/grub.conf or 1st.menu and save the file.
/boot/grub/grub.conf may possibly exist in no current distros. In many it never did. Others used /boot/grub/menu.lst for the original Grub. Most distros now use Grub2, so the relevant file is /boot/grub/grub.cfg or /boot/grub2/grub.cfg/, which is warned not to disturb, because there's an automatic system to regenerate it whenever a kernel is added or removed by the distro's package management system.
That's relevant only in some distros. Update-grub is not part of upstream Grub2 source. The official menu file regenerator is grub-mkconfig, which in some distros is grub2-mkconfig.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.