1 下載并安裝grub
./configure
make
make install
2 配置grub
a)把 /usr/local/share/grub/i386-pc/ 目錄下的所有文件統(tǒng)統(tǒng)拷貝到 /boot/grub/ 目錄下。
b)接下來是創(chuàng)建 grub.conf ,并在 /boot/grub/ 目錄下建立一個(gè) menu.lst ,指向 grub.conf。
c)執(zhí)行 grub-install /dev/hda1 把 stage1 寫入到 /boot 分區(qū)的引導(dǎo)扇區(qū)。
也可以執(zhí)行 grub 進(jìn)入 grub shell ,然后通過 root 和 setup 命令來安裝 stage1 。
(
grub shell安裝stage1的指令為
root (hd0,0)
setup (hd0)
)
3 重啟并運(yùn)行g(shù)rub指令,達(dá)到引導(dǎo)安裝程序的作用
引導(dǎo)安裝程序的指令為
root (hd0,0)
kernel /linuxdir/vmlinuz
initrd /linuxdir/initrd.img
boot
說明:其中的硬盤,路徑等信息隨情況不同有所變化.
聯(lián)系客服