我使用 clonezilla 将另一台计算机的分区映像 (Ubuntu 14.04) 安装到我的计算机 (以前是 Ubuntu 12.04) 上。另一台计算机上的系统分区是 sda1,而我的计算机上的系统分区是 sda4(我有一个多重引导系统,在其他 sda 上有 windows、MBR、UEFI、SWAP)。安装映像后,我的计算机无法再启动,因为 grub 无法在 sda4 上找到新的 Ubuntu 14.04。不幸的是,我无法从记忆棒或 Ubuntu 实时会话中运行引导修复。有人知道如何修复我的 grub 吗?
以下是启动修复错误日志文件输出的第一部分:
Boot Info Script e7fc706 + Boot-Repair extra info [Boot-Info 9Feb2015]
============================= Boot Info Summary: ===============================
=> Grub2 (v1.99-2.00) is installed in the MBR of /dev/sda and looks at sector
386664576 of the same hard drive for core.img, but core.img can not be
found at this location.
=> No boot loader is installed in the MBR of /dev/sdb.
=> Syslinux MBR (4.04 and higher) is installed in the MBR of /dev/sdc.
=> Syslinux MBR (4.04 and higher) is installed in the MBR of /dev/sdh.
sda1: __________________________________________________________________________
File system: vfat
Boot sector type: Windows 7/2008: FAT32
Boot sector info: No errors found in the Boot Parameter Block.
Operating System:
Boot files: /EFI/Boot/bkpbootx64.efi /EFI/Boot/bootx64.efi
/EFI/ubuntu/grubx64.efi /EFI/ubuntu/shimx64.efi
/EFI/Microsoft/Boot/bkpbootmgfw.efi
/EFI/Microsoft/Boot/bootmgfw.efi
/EFI/Microsoft/Boot/bootmgr.efi
/EFI/Microsoft/Boot/bootx64.efi
/EFI/Microsoft/Boot/memtest.efi
sda2: __________________________________________________________________________
File system:
Boot sector type: -
Boot sector info:
Mounting failed: mount: unknown filesystem type ''
sda3: __________________________________________________________________________
File system: ntfs
Boot sector type: Windows 7/2008: NTFS
Boot sector info: No errors found in the Boot Parameter Block.
Operating System: Windows 7
Boot files: /Windows/System32/winload.exe
sda4: __________________________________________________________________________
File system: ext4
Boot sector type: -
Boot sector info:
Operating System: Ubuntu 14.04.1 LTS
Boot files: /boot/grub/grub.cfg /etc/fstab
/boot/grub/i386-pc/core.img
sda5: __________________________________________________________________________
File system: swap
Boot sector type: -
Boot sector info:
答案1
看起来源计算机至少使用了 EFI。如果新计算机也使用 EFI,你应该可以使用我的rEFInd 启动管理器作为紧急启动系统:
- 从以下网址下载 CD-R 或 USB 闪存驱动器版本下载页面。
- 根据所述映像准备启动介质。
- 启动 rEFInd。这可能需要使用计算机的内置启动管理器,通常通过功能键访问。
- rEFInd 应该会显示所有 Linux 内核的选项。选择一个并按 Enter 键。
如果运气好的话,电脑会启动。然后您可以通过 Debian 软件包或 PPA 安装 rEFInd,或者运行 Boot Repair。
如果遇到问题,您可能需要启动紧急系统并编辑/etc/fstab
新系统的文件,因为您的文件系统 UUID 可能已更改。在这种情况下,最简单的方法是将行的第一个条目更改为/
read/dev/sda4
而不是UUID={whatever}
。再多花点功夫,您就可以使用blkid
来了解新的 UUID 值并进行适当的替换。