[Seek Help] 20.8内核6.1.12/6.1.9安装失败
Tofloor
poster avatar
Misaka
deepin
2023-03-12 06:18
Author

20.8尝试安装6.1.12和6.1.9内核,安装的时候终端有部分报错,重启无法用新的安装内核进入系统。开机界面显示:您需要先加载内核。先后安装两个不同的内核,情况都一样。只能照样使用旧的内核进入系统。请问是什么原因呢?如何解决?谢谢!

安装信息如下:

sudo apt update && sudo apt install linux-image-6.1.12 linux-headers-6.1.12
请输入密码:
验证成功
命中:1 https://community-packages.deepin.com/deepin apricot InRelease
命中:2 https://proposed-packages.deepin.com/dde-apricot unstable InRelease
命中:3 https://community-packages.deepin.com/driver driver InRelease
命中:4 https://pro-driver-packages.uniontech.com eagle InRelease
命中:6 https://community-packages.deepin.com/printer eagle InRelease
命中:5 https://home-store-img.uniontech.com/230310171814429/appstore deepin InRelease
命中:7 https://repo.steampowered.com/steam stable InRelease
正在读取软件包列表... 完成
正在分析软件包的依赖关系树
正在读取状态信息... 完成
所有软件包均为最新。
正在读取软件包列表... 完成
正在分析软件包的依赖关系树
正在读取状态信息... 完成
下列【新】软件包将被安装:
linux-headers-6.1.12 linux-image-6.1.12
升级了 0 个软件包,新安装了 2 个软件包,要卸载 0 个软件包,有 0 个软件包未被升级。
需要下载 80.4 MB 的归档。
解压缩后会消耗 398 MB 的额外空间。
获取:1 https://proposed-packages.deepin.com/dde-apricot unstable/main amd64 linux-headers-6.1.12 amd64 6.1.12-1 [8,930 kB]
获取:2 https://proposed-packages.deepin.com/dde-apricot unstable/main amd64 linux-image-6.1.12 amd64 6.1.12-1 [71.5 MB]
已下载 80.4 MB,耗时 37秒 (2,188 kB/s)
正在选中未选择的软件包 linux-headers-6.1.12。
(正在读取数据库 ... 系统当前共安装有 279348 个文件和目录。)
准备解压 .../linux-headers-6.1.12_6.1.12-1_amd64.deb ...
正在解压 linux-headers-6.1.12 (6.1.12-1) ...
正在选中未选择的软件包 linux-image-6.1.12。
准备解压 .../linux-image-6.1.12_6.1.12-1_amd64.deb ...
正在解压 linux-image-6.1.12 (6.1.12-1) ...
正在设置 linux-headers-6.1.12 (6.1.12-1) ...
正在设置 linux-image-6.1.12 (6.1.12-1) ...
Error! Bad return status for module build on kernel: 6.1.12 (x86_64)
Consult /var/lib/dkms/broadcom-sta/6.30.223.271/build/make.log for more information.
Error! The dkms.conf for this module includes a BUILD_EXCLUSIVE directive which
does not match this kernel/arch. This indicates that it should not be built.
update-initramfs: Generating /boot/initrd.img-6.1.12
cryptsetup: WARNING: The initramfs image may not contain cryptsetup binaries
nor crypto modules. If that's on purpose, you may want to uninstall the
'cryptsetup-initramfs' package in order to disable the cryptsetup initramfs
integration and avoid this warning.
setupcon is missing. Please install the 'console-setup' package.
W: Possible missing firmware /lib/firmware/i915/dg1_huc.bin for module i915
W: Possible missing firmware /lib/firmware/i915/tgl_huc.bin for module i915
W: Possible missing firmware /lib/firmware/i915/tgl_huc.bin for module i915
W: Possible missing firmware /lib/firmware/i915/skl_guc_70.1.1.bin for module i915
W: Possible missing firmware /lib/firmware/i915/bxt_guc_70.1.1.bin for module i915
W: Possible missing firmware /lib/firmware/i915/kbl_guc_70.1.1.bin for module i915
W: Possible missing firmware /lib/firmware/i915/glk_guc_70.1.1.bin for module i915
W: Possible missing firmware /lib/firmware/i915/kbl_guc_70.1.1.bin for module i915
W: Possible missing firmware /lib/firmware/i915/kbl_guc_70.1.1.bin for module i915
W: Possible missing firmware /lib/firmware/i915/cml_guc_70.1.1.bin for module i915
W: Possible missing firmware /lib/firmware/i915/icl_guc_70.1.1.bin for module i915
W: Possible missing firmware /lib/firmware/i915/ehl_guc_70.1.1.bin for module i915
W: Possible missing firmware /lib/firmware/i915/ehl_guc_70.1.1.bin for module i915
W: Possible missing firmware /lib/firmware/i915/tgl_guc_70.1.1.bin for module i915
W: Possible missing firmware /lib/firmware/i915/tgl_guc_70.1.1.bin for module i915
W: Possible missing firmware /lib/firmware/i915/dg1_guc_70.bin for module i915
W: Possible missing firmware /lib/firmware/i915/tgl_guc_70.1.1.bin for module i915
W: Possible missing firmware /lib/firmware/i915/tgl_guc_70.bin for module i915
W: Possible missing firmware /lib/firmware/i915/adlp_guc_70.1.1.bin for module i915
W: Possible missing firmware /lib/firmware/i915/adlp_guc_70.bin for module i915
W: Possible missing firmware /lib/firmware/i915/dg2_guc_70.bin for module i915
W: Possible missing firmware /lib/firmware/i915/dg2_dmc_ver2_07.bin for module i915
I: The initramfs will attempt to resume from /dev/sda4
I: (UUID=afd5a6f1-64a3-41bf-be03-ba71733c7de5)
I: Set the RESUME variable to override this.
live-boot: core filesystems devices utils udev blockdev dns.
fix systemd/logind config
get rootb uuid error: failed to get "rootb" uuid
正在生成 grub 配置文件 ...
找到主题:/boot/grub/themes/deepin-fallback/theme.txt
Found background image: /boot/grub/themes/deepin-fallback/background.jpg
找到 Linux 镜像:/boot/vmlinuz-6.1.12
找到 initrd 镜像:/boot/initrd.img-6.1.12
找到 Linux 镜像:/boot/vmlinuz-6.1.9
找到 initrd 镜像:/boot/initrd.img-6.1.9
找到 Linux 镜像:/boot/vmlinuz-5.18.17-amd64-desktop-community-hwe
找到 initrd 镜像:/boot/initrd.img-5.18.17-amd64-desktop-community-hwe
找到 Windows Boot Manager 位于 /dev/sdb1@/EFI/Microsoft/Boot/bootmgfw.efi
Adding boot menu entry for EFI firmware configuration
完成

启动报错页面如下:


截图_选择区域_20230311221521.png

截图_选择区域_20230311221527.png

系统信息如下:

截图_dde-control-center_20230311221405.png

Reply Favorite View the author
All Replies
avatar
Misaka
deepin
2023-03-12 06:20
#1

tail

Reply View the author
avatar
Ziggy
deepin
2023-03-12 07:26
#2

只是不支持安全启动,只有维护的lts或hwe才是支持安全启动

Reply View the author
avatar
青稚
deepin
2023-03-12 18:08
#3

把安全启动关了,试试看能不能启动,话说你用高版本内核干嘛?

功能不正常吗?

Reply View the author
avatar
晚秋(lateautumn)
Moderator
2023-03-12 18:13
#4

坐等坛主解决了之后,我也升级试试joy

Reply View the author
avatar
安洛
deepin
2023-03-12 18:44
#5

关闭安全启动,或者自己对新内核签名。

Reply View the author
avatar
忘记、过去
deepin
2023-03-12 19:40
#6

安装内核时提示 broadcom-sta 驱动模块编译失败,博通网卡的驱动需要用 Debian 11/12 仓库的版本才能在 6.0 内核编译通过

Reply View the author
avatar
deepin_xjp
deepin
2023-03-12 20:58
#7

等待稳定版……

Reply View the author
avatar
Misaka
deepin
2023-03-12 21:28
#8
青稚

把安全启动关了,试试看能不能启动,话说你用高版本内核干嘛?

功能不正常吗?

也没啥不正常,就是尝尝鲜。joy

Reply View the author
avatar
Misaka
deepin
2023-03-12 21:28
#9
Ziggy

只是不支持安全启动,只有维护的lts或hwe才是支持安全启动

好的,谢谢。

Reply View the author
avatar
Misaka
deepin
2023-03-12 21:29
#10
安洛

关闭安全启动,或者自己对新内核签名。

怎么样才能自己对新内核签名?

Reply View the author
avatar
zxhzhou
deepin
2023-03-12 21:50
#11

我升级到6.1.1也是这样,把安全启动关了,就行了

Reply View the author
avatar
青稚
deepin
2023-03-12 22:00
#12
忘记、过去

安装内核时提示 broadcom-sta 驱动模块编译失败,博通网卡的驱动需要用 Debian 11/12 仓库的版本才能在 6.0 内核编译通过

博通的网卡,在windows下,我安装对了,驱动windows不干了,不让用,提示不兼容,装linux就好使,ubuntu20.04不能用无线网卡,deepin都可以,不知道为啥,博通的东西古怪。

joy

Reply View the author
avatar
Misaka
deepin
2023-03-12 22:46
#13
zxhzhou

我升级到6.1.1也是这样,把安全启动关了,就行了

OK ,謝謝

Reply View the author
avatar
WangZhongyun
deepin
2023-03-13 03:51
#14

我原来升级到6.*内核,但显卡分辨率搞不好,就又卸了

Reply View the author
avatar
安洛
deepin
2023-03-13 04:32
#15
Misaka

怎么样才能自己对新内核签名?

一般来说,如果你不希望清除机器本身的密钥的话,那么你需要生成一个MOK(机器所有者密钥),然后将这个密钥导入bios,之后就能通过这个密钥对启动软件,包括启动加载器和内核等进行签名。之后就能启动这些经过签名的东西,而没有经过签名的就无法启动。

Reply View the author
avatar
Misaka
deepin
2023-04-29 04:51
#16
安洛

一般来说,如果你不希望清除机器本身的密钥的话,那么你需要生成一个MOK(机器所有者密钥),然后将这个密钥导入bios,之后就能通过这个密钥对启动软件,包括启动加载器和内核等进行签名。之后就能启动这些经过签名的东西,而没有经过签名的就无法启动。

谢谢

Reply View the author
avatar
李昕旸dE
deepin
2026-06-27 20:31
#17

6.1.9内核版:

原因:/boot/vmlinuz-6.1.9的签名无效

方法:

  1. 确认内核模块签名
    确保你的系统启用了内核模块签名验证,这通常可以通过CONFIG_SYSTEM_TRUSTED_KEYS和CONFIG_MODULE_SIG内核配置选项来控制
  2. 验证内核签名
    你可以使用mokutil工具来检查模块签名密钥是否正确设置,首先,你需要安装mokutil:

bash:
sudo apt-get install mokutil # Debian/Ubuntu
sudo yum install mokutil # CentOS/RHEL
然后,使用以下命令检查签名密钥:

bash:
sudo mokutil --list-enrolled
3. 重新生成密钥并重新签名
若你发现签名密钥不正确或缺失,你可以使用以下步骤重新生成密钥并重新签名:

‌生成新的密钥‌:

bash:
sudo mokutil --sb-state
sudo mokutil --generate-random-key /tmp/mykey.prv
sudo mokutil --import /tmp/mykey.prv
‌准备重新启动并进入UEFI固件设置‌:
在启动时按下相应的键(通常是Esc或Delete键)进入BIOS/UEFI设置。查找与Secure Boot相关的设置,并启用它,然后,找到“Setup Mode”或“Maintenance Mode”并进入

‌在UEFI固件中添加密钥‌:
在UEFI固件中,找到“Enroll Keys”或类似的选项,选择你刚才导入的密钥文件(通常是/tmp/mykey.prv)

准备‌重启系统‌:
保存设置并准备重启系统

  1. 更新GRUB配置
    确保GRUB配置正确设置了内核参数以支持签名验证,你可以编辑/etc/default/grub文件,确保有如下设置:

bash:
GRUB_ENABLE_CRYPTODISK=y
然后更新GRUB配置:

bash:
sudo update-grub
5. 重新安装内核
若问题依然存在,请尝试重新下载并安装内核:

bash:
sudo apt-get update && sudo apt-get install --reinstall linux-image-6.1.9 # Debian/Ubuntu
sudo yum reinstall kernel-6.1.9 # CentOS/RHEL
6. 检查硬件兼容性
确保你的硬件与新内核兼容,有时候,新内核可能不完全支持某些较旧的硬件

6.1.12内核版:

原因:/boot/vmlinuz-6.1.12的签名无效

  1. 禁用内核模块签名验证
    若你确定你的系统环境是安全的,可以选择禁用内核模块的签名验证,这可以通过编辑 GRUB 配置文件来实现。

‌编辑 GRUB 配置文件‌
打开终端,以 root 用户身份编辑 GRUB 配置文件(通常是 /etc/default/grub 或 /etc/grub.d/10_linux,具体取决于你的发行版)

bash:
sudo nano /etc/default/grub # 适用于 Debian/Ubuntu 系统

bash:
sudo nano /etc/grub.d/10_linux # 适用于 CentOS/RHEL 系统
‌禁用签名验证‌
找到 GRUB_CMDLINE_LINUX_DEFAULT 行,并修改或添加 mitigations=off 或 nokaslr(根据你的内核版本和具体需求)例如:

bash:
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash mitigations=off"

bash:
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash nokaslr"
‌更新 GRUB‌
保存文件后,更新 GRUB 配置:

bash:
sudo update-grub # 对于 Debian/Ubuntu 系统

bash:
sudo grub2-mkconfig -o /boot/grub2/grub.cfg # 对于 CentOS/RHEL 系统
准备重启系统‌
准备重启你的计算机以应用更改:

bash:
sudo reboot
2. 手动安装签名密钥
若你希望保持签名验证功能开启,但遇到特定模块的签名无效问题,你可以尝试手动安装相应的公钥

‌下载公钥‌
从可信的源下载相应的公钥文件(通常是 .der 或 .x509 格式)。例如,如果你知道是哪个开发者的密钥导致了故障,你可以从他们的官方网站下载公钥

‌安装公钥‌
使用 modprobe 命令加载公钥:

bash:
sudo modprobe dm-mod [公钥文件]
例如:

bash:
sudo modprobe dm-mod /path/to/public-key.x509
‌验证模块签名‌
使用 modinfo 命令验证模块签名:

bash:
modinfo -F signature [模块名]
注意事项:
1.它允许加载未经签名的模块,禁用内核模块签名验证会降低系统的安全性,仅在你确信环境安全时才考虑这个操作
2.手动安装公钥是一种更安全的选择,但需要你确保下载的公钥是来自可靠源。总是从官方网站或通过官方渠道获取公钥
3.在进行任何系统更改之前,建议备份重要数据和系统配置

按照这些步骤操作后,你应该能够解决“/boot/vmlinuz-6.1.9或6.1.12的签名无效”的问题,若全部原因及方法未能解决,你可能需要更详细地检查硬件兼容性或考虑使用旧版本的内核

Reply View the author