打开APP
userphoto
未登录

开通VIP,畅享免费电子书等14项超值服

开通VIP
Linux与Windows双系统,安装完linux后无法通过grub进入Windows的解决方法

测试环境:Kali Linux (2022.2),Windows 10(19044),UEFI(GPT)

症状分析:先装Windows 10,Windows可正常启动,再装Kali,Kali提示装grub后照装。然而装完后重启发现无Windows选项(也就是没有Windows Boot Manager后面跟一大堆有的没的)。

解决方法:先进Linux,在终端下运行

sudo update-grub

得到反馈如下:

  1. Generating grub configuration file ...
  2. Found theme: /boot/grub/themes/kali/theme.txt
  3. Found background image: /usr/share/images/desktop-base/desktop-grub.png
  4. Found linux image: /boot/vmlinuz-5-18.0-kali5-amd64
  5. Found initrd image: /boot/initrd.img-5.18.0-kali5-amd64
  6. Warning: os-prober will not be executed to detect other bootable partitions. Systems on them will not be added to the GRUB boot configuration. Check GRUB_DISABLE_OS_PROBER documentation entry.
  7. Addming boot menu entry for UEFI Firmware Settings ...
  8. done

原因:os-prober未启用。

解决方法:

首先先打开grub的配置文件:

  1. sudo chmod 777 /etc/default/grub

  2. sudo vi /etc/default/grub

然后在文件中另起一行加上:

GRUB_DISABLE_OS_PROBER=false

保存后将文件改回只读,然后再update-grub即可。

  1. sudo chmod 644 /etc/default/grub

  2. sudo update-grub

如无误,输出将会如下:

  1. Generating grub configuration file ...
  2. Found theme: /boot/grub/themes/kali/theme.txt
  3. Found background image: /usr/share/images/desktop-base/desktop-grub.png
  4. Found linux image: /boot/vmlinuz-5-18.0-kali5-amd64
  5. Found initrd image: /boot/initrd.img-5.18.0-kali5-amd64
  6. Warning: os-prober will be executed to detect other bootable partitions.
  7. Its output will be used to detect bootable binaries on them and create new boot entries.
  8. Found Windows Boot Manager on /dev/nvme0n1p1@/EFI/Microsoft/Boot/bootmgfw.efi
  9. Addming boot menu entry for UEFI Firmware Settings ...
  10. done

重启机器即可从第三项(Windows Boot Manager on /dev/nvme0n1p1)启动Windows。

本站仅提供存储服务,所有内容均由用户发布,如发现有害或侵权内容,请点击举报
打开APP,阅读全文并永久保存 查看更多类似文章
猜你喜欢
类似文章
【热】打开小程序,算一算2024你的财运
Ubuntu grub2的启动配置文件grub.cfg,为了修改另人生厌的时间
Migrate to GRUB 2
Grub的图形化工具介绍
安装双系统后,设置XP为开机默认启动
kali liveU盘之我做主!
Grub24Dos for nt6
更多类似文章 >>
生活服务
热点新闻
分享 收藏 导长图 关注 下载文章
绑定账号成功
后续可登录账号畅享VIP特权!
如果VIP功能使用有故障,
可点击这里联系客服!

联系客服