javatgo 发表于 2013-1-28 09:33:45

安装grub的具体步骤(转载)

引用于:http://linux.vbird.org/linux_basic/0510osloader.php# grub1. 先設定一下含有 /boot 目錄的那個 partition 啊!grub> root (hd0,0) Filesystem type is ext2fs, partition type 0x83# 瞧!找到啦!有這個 partition 的存在,且 grub 認識他為 ext2 的 filesystem。2. 搜尋一下,是否存在 stage1 這個資訊檔案?grub> find /boot/grub/stage1 (hd0,0) (hd1,0)# 呵呵!竟然找到兩個?因為剛剛我們也安裝一個在 /dev/hdb1 嘛!3. 搜尋一下是否可以找到核心? /boot/vmlinuz ?grub> find /boot/vmlinuzError 15: File not foundgrub> find /boot/vmlinuz-2.6.12-1.1456_FC4 (hd0,0)# 沒辦法,FC4 沒有連結檔,所以需要填寫完整的 kernel 檔案名稱! 4. 給他安裝上去吧!安裝到 MBR 看看!grub> setup (hd0) Checking if "/boot/grub/stage1" exists... yes Checking if "/boot/grub/stage2" exists... yes Checking if "/boot/grub/e2fs_stage1_5" exists... yes Running "embed /boot/grub/e2fs_stage1_5 (hd0)"...15 sectors are embedded.succeeded Running "install /boot/grub/stage1 (hd0) (hd0)1+15 p (hd0,0)/boot/grub/stage2 /boot/grub/grub.conf"... succeededDone.# 很好!確實有裝起來~這樣 grub 就在 MBR 當中了!5. 那麼重複安裝到我的 /dev/hda1 呢?亦即是 super block 當中?grub> setup (hd0,0) Checking if "/boot/grub/stage1" exists... yes Checking if "/boot/grub/stage2" exists... yes Checking if "/boot/grub/e2fs_stage1_5" exists... yes Running "embed /boot/grub/e2fs_stage1_5 (hd0,0)"... failed (this is not fatal) Running "embed /boot/grub/e2fs_stage1_5 (hd0,0)"... failed (this is not fatal) Running "install /boot/grub/stage1 (hd0,0) /boot/grub/stage2 p /boot/grub/grub.conf "... succeededDone.# 雖然無法將 stage1_5 安裝到 super block 去,不過,還不會有問題,# 重點是最後面那個 stage1 要安裝後,顯示 succeeded 字樣就可以了!grub> quit
页: [1]
查看完整版本: 安装grub的具体步骤(转载)