2012年5月14日 星期一

重建 grub2

以前 grub 0.97 很簡單就能重建了…換到grub 1.9x後,有點不習慣…

grub找不到 grub.cfg 就會出現如下:
  • Minimal BASH-like line editing is supported. Fot the first word, TAB lists possible command completions. Anywhere else TAB lists the possible completions of a device/filename.
    grub>
幫它把 gurb.cfg 找到後就行了:
  • grub> ls
    grub> set root=(hd0,msdosX)  <- 根據 ls 的結果選擇grub.cfg所在的partition
    grub> linux /boot/vmlinuz... root=/dev/sdaX (如果上面資訊正確的話,這裡可以用tab補完自串)
    grub> initrd /boot/initrd...
    grub> boot
沒什麼意外的話,這樣就可以開機了

沒有留言:

張貼留言