Linux command
kernel-install 命令
安全
权限或系统影响较大,执行前请核对目标。
常用示例
Add
sudo kernel-install add [kernel-version] [kernel-image] [path/to/initrd]
Remove
sudo kernel-install remove [kernel-version]
Inspect
sudo kernel-install inspect [kernel-image]
说明
kernel-install manages kernel images in the boot partition. It's part of systemd and handles the installation and removal of kernel images for systemd-boot and other bootloaders. The tool runs plugins (install.d scripts) that handle tasks like copying files, generating bootloader entries, and updating the initramfs. It integrates with the Boot Loader Specification.
参数
- add _VERSION_ _KERNEL_ _INITRD_...
- Add kernel and optional initramfs images to boot partition
- remove _VERSION_
- Remove kernel and associated files from boot partition
- inspect _KERNEL_
- Display configured and auto-detected paths
FAQ
What is the kernel-install command used for?
kernel-install manages kernel images in the boot partition. It's part of systemd and handles the installation and removal of kernel images for systemd-boot and other bootloaders. The tool runs plugins (install.d scripts) that handle tasks like copying files, generating bootloader entries, and updating the initramfs. It integrates with the Boot Loader Specification.
How do I run a basic kernel-install example?
Run `sudo kernel-install add [kernel-version] [kernel-image] [path/to/initrd]` in a terminal, then adjust file names, paths, flags, or remote targets for your system.
What does add _VERSION_ _KERNEL_ _INITRD_... do in kernel-install?
Add kernel and optional initramfs images to boot partition