grub引导修复(分区表未损坏)




grub引导修复(分区表未损坏)




将sda前446字节备份到/home/jason/下面


[[email protected] jason]# dd if=/dev/sda of=/home/jason/mbr.bak bs=446 count=1
1+0 records in
1+0 records out
446 bytes (446 B) copied, 0.000208564 s, 2.1 MB/s


查看备份


[[email protected] jason]# ls -lh | grep mbr.bak
-rw-r--r-- 1 root  root   446 Jun 20 23:16 mbr.bak


破坏sda前446字节


[[email protected] jason]# dd if=/dev/zero of=/dev/sda bs=446 count=1
1+0 records in
1+0 records out
446 bytes (446 B) copied, 0.00020676 s, 2.2 MB/s


重启


[[email protected] jason]# reboot


VMware设置


a.选择镜像文件


grub引导修复(分区表未损坏)

b.选择从BIOS启动


grub引导修复(分区表未损坏)


通过方向键进入到BOOT界面


grub引导修复(分区表未损坏)


将CD-ROM Drive设定为首启动


grub引导修复(分区表未损坏)


F10保存并退出


grub引导修复(分区表未损坏)


选择rescue模式


grub引导修复(分区表未损坏)


选择English


grub引导修复(分区表未损坏)


选择键盘


grub引导修复(分区表未损坏)


Unsupported Hardware Dectected


grub引导修复(分区表未损坏)


点击ok继续


network选择no


grub引导修复(分区表未损坏)


Rescue


grub引导修复(分区表未损坏)


通过Tab键选择Continue


Examing storage devices


grub引导修复(分区表未损坏)


Your system has been mounted under /mnt/sysp_w_picpath


grub引导修复(分区表未损坏)


系统被挂载到/mnt/sysp_w_picpath下面


Your system is mounted under /mnt/sysp_w_picpath directory


grub引导修复(分区表未损坏)


shell Start shell


grub引导修复(分区表未损坏)


在shell Start shell按“Enter”进入shell中


恢复备份


grub引导修复(分区表未损坏)


通过"dd if=/home/jason/mbr.bak of=/dev/sda bs=446 count=1"将之前备份在/home/jason下的mbr.bak中的信息写入到sda中,实现对grub引导的修复。


reboot正常进入到登录界面


grub引导修复(分区表未损坏)


修复完成




转载于:https://blog.51cto.com/zencode/1791583

相关文章:

  • 2022-01-02
  • 2021-12-27
  • 2021-11-10
  • 2021-09-30
  • 2021-04-05
  • 2021-04-20
  • 2021-08-11
猜你喜欢
  • 2021-08-11
  • 2022-01-03
  • 2021-09-21
  • 2021-10-01
  • 2022-01-03
  • 2022-01-08
相关资源
相似解决方案