Learn to delete old Linux Kernel

Source: Internet
Author: User

For old Linux users, if a new version of the Linux kernel is released, how can you delete the old Ubuntu Linux kernel? I hope this article will help you learn about the Linux kernel. First, use the following command to list all installed kernels. In the following table, the kernel files with images are used. Select the package to be uninstalled and use apt-get to uninstall the package.

Admingu @ andy :~ $ Dpkg -- get-selections | grep Linux

 
 
  1. libseLinux1                   install  
  2. Linux-generic                   install  
  3. Linux-headers-2.6.24-16               install  
  4. Linux-headers-2.6.24-18               install  
  5. Linux-headers-2.6.24-18-generic           install  
  6. Linux-headers-2.6.24-19               install  
  7. Linux-headers-2.6.24-19-generic           install  
  8. Linux-headers-generic               install  
  9. Linux-image-2.6.24-16-generic           deinstall  
  10. Linux-image-2.6.24-18-generic           install  
  11. Linux-image-2.6.24-19-generic           install  
  12. Linux-image-generic               install  
  13. Linux-libc-dev                   install  
  14. Linux-restricted-modules-2.6.24-16-generic   deinstall  
  15. Linux-restricted-modules-2.6.24-18-generic   install  
  16. Linux-restricted-modules-2.6.24-19-generic   install  
  17. Linux-restricted-modules-common           install  
  18. Linux-restricted-modules-generic       install  
  19. Linux-sound-base               install  
  20. Linux-ubuntu-modules-2.6.24-16-generic       deinstall  
  21. Linux-ubuntu-modules-2.6.24-18-generic       install  
  22. Linux-ubuntu-modules-2.6.24-19-generic       install  
  23. util-Linux                   install  
  24. util-Linux-locales               install 

The specific uninstall method is

Sudo apt-get remove Linux-image-2.6.24-16-generic
Sudo apt-get remove Linux-headers-2.6.24-16-generic

In this way, the kernel files can be automatically deleted and the disk space can be released.

In addition, you need to record a command.

Uname-

Use this command to view the Kernel used by the current system.

After uninstallation, there are other options in the Start menu, so we need to modify the Start menu,

Run the following command to open menu. lst:

Sudo gedit/boot/grub/menu. lst

Find the unnecessary menu and delete it. Remember to modify the default value and the default startup Item! In this way, the old Linux kernel is successfully deleted.

  1. Teach you how to set Linux Startup Encryption
  2. Will you become a GNU/Linux User?
  3. Linux network operation commands
  4. Best Solution: Linux hard disk partitioning
  5. Brief Introduction to Linux Application

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.