Skip to content

kernel_remove: init script to remove a specified kernel #8

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: mainline
Choose a base branch
from

Conversation

thefossguy-ciq
Copy link
Contributor

This script basically cleans up all the possible paths that might be populated from a make modules_install and make install. Given that the kernel is removed, the grub entry is also removed with the help of grubby.

This is an ad-hoc script created to quickly remove a kernel without much fuss about it.


The script only accepts the kernel version and is used like following:

$ ./kernel_remove.sh $KERNEL_VERSION

$ ./kernel_remove.sh 4.18.0-ciqlts8_8-6a8fa3030700+

And that's all. It will remove all installed files and even remove the grub entry.

This script basically cleans up all the possible paths that might be
populated from a `make modules_install` and `make install`. Given that
the kernel is removed, the grub entry is also removed with the help of
`grubby`.

This is an ad-hoc script created to quickly remove a kernel without much
fuss about it.
@PlaidCat
Copy link
Collaborator

Could you add a check for making sure you're not deleting the running kernel?

Additionally could you add an Entry to the ReadMe explaining this and the expected use case and limitations?

Otherwise thanks this will be helpful for full systems or those that don't treat their VM's as disposable (i know this is important to some)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants