1. 程式人生 > >ubuntu 安裝之後開機顯示 grub rescue>

ubuntu 安裝之後開機顯示 grub rescue>

win10、ubuntu雙系統,win10升級之後無法正常啟動ubuntu
螢幕提示grub rescue>
grub rescue>ls
會羅列所有的磁碟分割槽資訊,比方說:
(hd0,msods1),(hd0,msdos2),(hd0,msdos3),(hd1,msdos2),.....
ls (hd0,msdos1)/boot/grub    # 未單獨分出/boot分割槽;單獨進行/boot分割槽的不加/boot
依次進行所有硬碟的嘗試,那個正常列出目錄,則為linux,假設為(hd0,msdos2)
grub rescue>set root=(hd0,msdos2)
grub rescue>set prefix=(hd0,msdos2)/boot/grub


grub rescue>insmod /boot/grub/normal.mod
如果上一步提示 /boot/grub/normal.mod為找到,則用下面的命令,原因normal.mod在 i386-pc資料夾內
grub rescue>insmod normal
grub rescue>normal
然後正常進入ubuntu系統後,開啟終端:
sudo update-grub
sudo grub-install /dev/sda         
  #注意:不要在/dev/sda加任何數字,sda對應上面的hd0,hd1就是sdb
以後進入ubuntu就恢復正常啦