我从这里安装了主线内核 4.18http://kernel.ubuntu.com/~kernel-ppa/mainline/v4.18/使用 ubuntu 18.04
这些软件包未签名,现在 grub 每次更新时都会抱怨这一点。
E: Your kernels are unsigned. This system will fail to boot in a secure boot environment.
我怎样才能让这条消息消失?或者让 4.18 签名?
我没有考虑构建自己的内核。
答案1
我删除未签名的内核的过程(忘记我已经安装了它?):
$ uname -r 4.17.2-041702-generic
$ ls /boot/ abi-4.15.0-23-generic memtest86+.elf abi-4.15.0-34-generic memtest86+_multiboot.bin abi-4.17.2-041702-generic retpoline-4.15.0-23-generic config-4.15.0-23-generic retpoline-4.15.0-34-generic config-4.15.0-34-generic retpoline-4.17.2-041702-generic config-4.17.2-041702-generic System.map-4.15.0-23-generic efi System.map-4.15.0-34-generic grub System.map-4.17.2-041702-generic initrd.img-4.15.0-23-generic vmlinuz-4.15.0-23-generic initrd.img-4.15.0-34-generic vmlinuz-4.15.0-34-generic initrd.img-4.17.2-041702-generic vmlinuz-4.17.2-041702-generic memtest86+.bin
$ dpkg -S /boot/vmlinuz-4.17.2-041702-generic linux-image-unsigned-4.17.2-041702-generic: /boot/vmlinuz-4.17.2-041702-generic
$ dpkg --list | grep 4.17.2 ii linux-headers-4.17.2-041702 4.17.2-041702.201806160433 all Header files related to Linux kernel version 4.17.2 ii linux-image-unsigned-4.17.2-041702-generic 4.17.2-041702.201806160433 amd64 Linux kernel image for version 4.17.2 on 64 bit x86 SMP ii linux-modules-4.17.2-041702-generic 4.17.2-041702.201806160433 amd64 Linux kernel extra modules for version 4.17.2 on 64 bit x86 SMP
$ dpkg --list | grep 4.17.2 | awk '{print $2}' linux-headers-4.17.2-041702 linux-image-unsigned-4.17.2-041702-generic linux-modules-4.17.2-041702-generic
$ sudo apt-get purge $(dpkg --list | grep 4.17.2 | awk '{print $2}') [sudo] password for alex: Reading package lists... Done Building dependency tree Reading state information... Done The following packages will be REMOVED: linux-headers-4.17.2-041702* linux-image-unsigned-4.17.2-041702-generic* linux-modules-4.17.2-041702-generic* 0 upgraded, 0 newly installed, 3 to remove and 0 not upgraded. 2 not fully installed or removed. After this operation, 308 MB disk space will be freed. Do you want to continue? [Y/n] y (Reading database ... 203507 files and directories currently installed.) Removing linux-headers-4.17.2-041702 (4.17.2-041702.201806160433) ... Removing linux-image-unsigned-4.17.2-041702-generic (4.17.2-041702.201806160433) ... W: Removing the running kernel I: /vmlinuz.old is now a symlink to boot/vmlinuz-4.15.0-23-generic I: /initrd.img.old is now a symlink to boot/initrd.img-4.15.0-23-generic /etc/kernel/postrm.d/initramfs-tools: update-initramfs: Deleting /boot/initrd.img-4.17.2-041702-generic
答案2
我最终从 ubuntu 恢复到默认内核并且一切都按预期工作。