[Feature Requests & Feedback] Deepin V25 Alpha版修改目录结构,导致Opencore无法引导v25
Tofloor
poster avatar
水手
deepin
2025-03-24 20:03
Author

如题,本人习惯使用Opencore引导系统,主要是Opencore比较美观,比grub引导界面看着舒服多了。

之前在使用Win11和deepin v23或其他linux (Kylin,Mint等)多系统时,安装完系统会在Opencore界面产生一个或多个SYSTEM的图标,对应不同linux系统的grub,

同时,我在Opencore配置文件里UEFI-->Drives部分添加了Openlinuxboot.efi,会自动硬盘上存在的Linux系统并显示在启动界面上,这样启动很方便。

只是SYSTEM图标会有点冗余,一般我会直接Reset NVRAM,然后用easyEFI重新添加opencore引导信息。

这样重启之后Opencore引导界面会很干净,一个系统一个图标。

但是,Deepin V25 Alpha版修改目录结构,导致Opencore无法引导v25,界面图标没有v25。

从其他linux系统进去查看deepin v25系统,文件目录结构确实跟v23不一样,变动很大。

这很难搞啊,Reset NVRAM后要怎么才能通过Opencore引导v25,哪位大神指导一下呗。

微信图片_2025-03-24_201519_769.png

Reply Favorite View the author
All Replies
穿西装的万斯在统亻言
deepin
Backbone of ecological co-construction group
2025-03-24 21:56
#1

磐石系统本来目录结构就改变了很多

Reply View the author
ssk-wh
deepin
2025-03-25 10:44
#2

可以先按照下面的步骤去找到磐石系统的根文件系统(以我自己的系统举例,全盘安装的系统):

在initrd阶段:

1.挂载系统分区

挂载系统层分区到/rootmnt,并设置挂载属性为 private 的挂载属性。

mount /dev/sda3 /rootmnt
mount --make-private /rootmnt

2.挂载数据分区

persistent 分区的设备路径可以从 cmdline 中的 root=参数上获取

挂载数据层分区到/rootmnt/persistent,并设置挂载属性为 private 的挂载
属性。
mount /dev/sda4 /rootmnt/persistent
mount --make-private /rootmnt/persistent

3.获取 ostree_arg 参数
ostree_arg 通常需要从 cmdline 中获取,根据执行的环境不同,获取 cmdline 的方式也可能
不同。主要有两种方式:

从/proc/cmdline 中获取
cmdline=$(cat /proc/cmdline)
从/boot/grub/grub.cfg 中获取
cmdline=$(grep "ostree=" /boot/grub/grub.cfg)

ostree_arg是ostree=后面的部分

4.调用 deepin-mount-root 脚本进行挂载磐石根文件系统
deepin-mount-root /rootmnt $ostree_arg
此时根文件系统就完全准备好了,chroot 到/rootmnt,或者执行 run init 都行。 如果是
chroot,记得后面还需要 mount dev proc sys run 等目录到/rootmnt 下。

Reply View the author