删除Ubuntu分区后的GRUB救援问题!

use*_*065 76 boot grub2 dual-boot windows-7 grubrescue

删除 Ubuntu 分区后,我重新启动了计算机,但只收到提示:

grub rescue >
Run Code Online (Sandbox Code Playgroud)

命令ls列表

(hd0) (hd0,msdos5) (hd0,msdos3) (hd0,msdos2) (hd0,msdos1) (hd1) (hd1,msdos1)
Run Code Online (Sandbox Code Playgroud)

我一一检查:

ls (hd0,msdos5)/
ls (hd0,msdos1)/
Run Code Online (Sandbox Code Playgroud)

但我找不到正确的分区。

小智 111

尝试以下..

grub rescue > ls
(hd0) (hd0,msdos5) (hd0,msdos3) (hd0,msdos2) (hd0,msdos1) (hd1) (hd1,msdos1)
grub rescue > ls (hd0,msdos1) # try to recognize which partition is this
grub rescue > ls (hd0,msdos2) # let's assume this is the linux partition
grub rescue > set root=(hd0,msdos2)
grub rescue > set prefix=(hd0,msdos2)/boot/grub # or wherever grub is installed
grub rescue > insmod normal # if this produced an error, reset root and prefix to something else ..
grub rescue > normal
Run Code Online (Sandbox Code Playgroud)

对于永久修复,在成功启动后运行以下命令:

sudo update-grub
sudo grub-install /dev/sdX
Run Code Online (Sandbox Code Playgroud)

/dev/sdX你的启动驱动器在哪里。

  • grub rescue > ls (hd0,msdos1) # 尝试识别这是哪个分区 -----> 我收到错误:ls 命令列出的三个分区中的每个分区中的文件系统未知。请帮助。谢谢。 (12认同)
  • ls 命令应该类似于“ls (hd0,msdos1) /boot” (5认同)
  • 我为所有人尝试了 'ls (hd0,msdos1) /boot'。它显示“未知文件系统”。我该怎么办?请帮忙 (5认同)
  • 谢谢回复。但我通过实时 USB 登录并发出“update-grub”命令来修复它 (3认同)

小智 38

要删除 GRUB,只需从另一台 PC 下载 Windows 8 或 10。使用 Rufus 将 iso 刻录到 USB 中。从 USB 启动,单击故障排除,然后单击命令提示符,然后键入:

Bootrec /fixmbr  
Run Code Online (Sandbox Code Playgroud)

Windows 将在没有 Ubuntu 的 GRUB 的情况下正常启动。您可以再次重新安装 Ubuntu。

  • 到 2020 年左右,认识到“fixmbr”命令将恢复 MBR 样式启动非常重要。如果以前有 UEFI,现在又是 MBR。我没有看到很多正确的答案,所以如果您已经陷入这个困境,您应该研究 Windows 的“mbr2gpt”程序,它是 [WinPE](https://docs.microsoft.com) 的一部分/en-us/windows-hardware/manufacture/desktop/winpe-in​​tro)可启动。使用它绝对是*痛苦*,但它可以让您的磁盘恢复到 GPT/UEFI。如果您没有运行“fixmbr”,它可能还具有修复工具来恢复 UEFI 设置。 (2认同)

小智 6

在 Ubuntu live-CD 或 live-USB 上启动您的计算机

然后按照第2 个选项部分进行操作从此链接在 Ubuntu 中安装引导修复

https://help.ubuntu.com/community/Boot-Repair

  • 我试过这个。它声称已经修复了它,但它总是让我回到 grub 终端。 (3认同)