GRUB引导硬盘上的ISO
作者:互联网
Ventoy只能启动U盘上的ISO,我需要直接直接从硬盘上启动。
试了几天,终于发现了问题: iso-scan/filename 是必须的!
编辑 /etc/grub.d/40_custom,末尾增加,保存后,sudo update-grub。
这些成功了,但是丢失了选择菜单:
menuentry "Ubuntu Kylin" {
set root=(hd0,5)
set isofile="/ISO/ubuntukylin-20.04.1-enhanced-amd64.iso"
loopback loop $isofile
linux (loop)/casper/vmlinuz boot=casper iso-scan/filename=$isofile locale=zh_CN
initrd (loop)/casper/initrd
}
menuentry "ubuntu 16" {
set isofile="/ISO/ubuntu-16.04.7-desktop-amd64.iso"
loopback loop (hd0,5)$isofile
linux (loop)/casper/vmlinuz boot=casper iso-scan/filename=$isofile
initrd (loop)/casper/initrd
}
menuentry "KDE neon" {
set root=(hd0,5)
set isofile="/ISO/KDE-neon-user-20210217-1639.iso"
loopback loop $isofile
linux (loop)/casper/vmlinuz boot=casper iso-scan/filename=$isofile
initrd (loop)/casper/initrd
}
menuentry "fossapup" {
set root=(hd0,5)
set isofile="/ISO/fossapup64-9.5.iso"
loopback loop $isofile
linux (loop)/vmlinuz iso-scan/filename=$isofile
initrd (loop)/initrd.gz
}
menuentry "slitaz" {
echo "Loading memdisk..."
linux16 /usr/lib/syslinux/memdisk iso raw
echo "Loading ISO..."
initrd16 /usr/slitaz-rolling.iso
}
menuentry "WIN7PE" {
echo "Loading memdisk..."
linux /usr/lib/syslinux/memdisk iso raw
echo "Loading ISO..."
initrd (hd0,5)/ISO/WIN7PE.iso
}
这些仍然失败:
menuentry "elementaryos" {
set root=(hd0,5)
set isofile="/ISO/elementaryos-5.1-stable.20200814.iso"
loopback loop $isofile
linux (loop)/casper/vmlinuz boot=casper iso-scan/filename=$isofiler
initrd (loop)/casper/initrd.lz
}
menuentry "Deepin Live" {
set root=(hd0,5)
set isofile="/ISO/deepin-live-system-2.0-amd64.iso"
loopback loop $isofile
linux (loop)/live/vmlinuz boot=live iso-scan/filename=$isofile
initrd (loop)/live/initrd.img
}
menuentry "TinyCore" {
set root=(hd0,5)
set isofile="/ISO/CorePlus-current.iso"
loopback loop $isofile
linux (loop)/boot/vmlinuz boot=boot iso-scan/filename=$isofile
initrd (loop)/boot/core.gz
}
标签:set,GRUB,isofile,initrd,iso,loop,casper,ISO,硬盘 来源: https://blog.csdn.net/sonichty/article/details/114115539