Skip to main content

Remove an Old or New kernel in Fedora

To remove a kernel in Fedora, follow these steps:

Identify the kernel you want to remove using the uname -r command. This will display the currently running kernel version.

Use the rpm -qa | grep ^kernel command to list all of the installed kernel packages on your system. Look for the kernel package that you want to remove. It will be named kernel-version, where version is the version number of the kernel you want to remove.

Example:

rpm -qa | grep ^kernel

proves the kernel 6.0.11 is still present:

kernel-core-6.0.11-300.fc37.x86_64
kernel-modules-6.0.11-300.fc37.x86_64
kernel-devel-6.0.11-300.fc37.x86_64
kernel-6.0.11-300.fc37.x86_64
kernel-core-6.0.12-300.fc37.x86_64
kernel-modules-6.0.12-300.fc37.x86_64
kernel-devel-6.0.12-300.fc37.x86_64
kernel-6.0.12-300.fc37.x86_64

to remove older kernel the below command will have to be used.

sudo dnf remove kernel-headers-6.0.5-300.fc37.x86_64
sudo dnf remove kernel-core-6.0.11-300.fc37.x86_6
sudo dnf remove kernel-modules-6.0.11-300.fc37.x86_64
sudo dnf remove kernel-6.0.11-300.fc37.x86_64

you can follow the below step too.

sudo dnf remove $(rpm -qa | grep ^kernel | grep 6\.0.11)

After uninstalling the kernel, you will need to update the GRUB boot menu so that the removed kernel is no longer listed as an option. To do this, run the grub2-mkconfig -o /boot/efi/EFI/fedora/grub.cfg command. This will regenerate the GRUB configuration file with the updated list of kernels.

Reboot your system to apply the changes. The removed kernel will no longer be listed in the boot menu.

Note: Keep in mind that you should not remove the kernel that is currently running. If you do, you will not be able to boot your system. It is recommended to always have at least two kernels installed so that you have a fallback in case something goes wrong.


Comments

Popular posts from this blog

Compile OpenSSH 9

Install  yum install rpm-build zlib-devel openssl-devel pam-devel libselinux-devel gcc perl-devel libXt-devel gtk2-devel make -y wget -c https://cdn.openbsd.org/pub/OpenBSD/OpenSSH/portable/openssh-9.3p2.tar.gz ./configure --with-pam --with-selinux --with-privsep-path=/var/lib/sshd/ --sysconfdir=/home/saz163user/ssh ./configure make make install

Use the CIA triad to protect organizations

The CIA triangle is a concept that can assist organisations think about risk while developing systems and security policies. It consists of three components that cybersecurity analysts and organisations strive to maintain: confidentiality, integrity, and availability. Maintaining an acceptable level of risk and ensuring that systems and policies are developed with these factors in mind aids in the establishment of a successful security posture, which refers to an organization's ability to manage its defence of key assets and data as well as respond to change.  Confidentiality The concept of confidentiality states that only people with permission can access particular resources or data. The application of design principles, such as the concept of least privilege, can improve secrecy inside an organisation. The least privilege principle restricts users' access to only the data they need to finish tasks relevant to their jobs. One technique to keep private data secure and secret i...

People who like to be alone

People who enjoy being alone and seek solitude may exhibit a variety of personality traits. Here are some potential traits that may be present in individuals who prefer to be alone:     Independence: People who enjoy being alone may value their independence and may be comfortable making decisions and going about their daily lives on their own. They may be self-motivated and able to entertain themselves without the need for external stimuli.     Introversion: Many people who enjoy being alone may be introverted, meaning that they tend to be more inwardly focused and may get their energy from solitude rather than social interactions. Introverts may prefer to spend time alone thinking, reading, or engaging in solitary activities.Creativity: Being alone can provide an opportunity for people to tap into their creativity and to engage in activities that allow them to express themselves. People who enjoy being alone may be more inclined to engage in creative pursu...