Grub error 17,并且无法修复。。。?怎么办,代码如下

feelwithear 2008-09-13 10:47:00
我开机后就显示grub error 17 然后就死在那了。。。

然后我在网上查了一下,按他们的操作还是出错

用 Ubuntu 的 liveCD 进去后如下。。。
/*
grub> find /boot/grub/stage1
(hd0,5)

grub> root (hd0,5)

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)"... 16 sectors are embedded.
succeeded
Running "install /boot/grub/stage1 (hd0) (hd0)1+16 p (hd0,5)/boot/grub/stage2
/boot/grub/menu.lst"... failed

Error 12: Invalid device requested
*/

然后 我又查了 Error 12的修正方法 如下

/*
grub> root (hd0,5)

grub> setup (hd0)(hd0,5)
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)"... 16 sectors are embedded.
succeeded
Running "install /boot/grub/stage1 (hd0) (hd0)1+16 p (hd0,5)/boot/grub/stage2
/boot/grub/menu.lst"... failed

Error 12: Invalid device requested
*/

还是不行。。。
怎么办

我系统里 menu.lst 里为什么都是从 (hd0,7) 进入的呢?明明查出来是 (hd0,5)。。。。。。。。//这个问题很痛苦。。。
我试着把 (hd0,7) 改为 (hd0,5) 还是不行。。。

/boot/grub/menu.lst
/*
default 0
timeout 10
title Ubuntu 8.04.1, kernel 2.6.24-21-generic
root (hd0,7)
kernel /boot/vmlinuz-2.6.24-21-generic root=UUID=d2700d3b-b181-4cf3-bd77-5cac02c06ea0 ro quiet splash
initrd /boot/initrd.img-2.6.24-21-generic
quiet

title Ubuntu 8.04.1, kernel 2.6.24-21-generic (recovery mode)
root (hd0,7)
kernel /boot/vmlinuz-2.6.24-21-generic root=UUID=d2700d3b-b181-4cf3-bd77-5cac02c06ea0 ro single
initrd /boot/initrd.img-2.6.24-21-generic

title Ubuntu 8.04.1, kernel 2.6.24-16-generic
root (hd0,7)
kernel /boot/vmlinuz-2.6.24-16-generic root=UUID=d2700d3b-b181-4cf3-bd77-5cac02c06ea0 ro quiet splash
initrd /boot/initrd.img-2.6.24-16-generic
quiet

title Ubuntu 8.04.1, kernel 2.6.24-16-generic (recovery mode)
root (hd0,7)
kernel /boot/vmlinuz-2.6.24-16-generic root=UUID=d2700d3b-b181-4cf3-bd77-5cac02c06ea0 ro single
initrd /boot/initrd.img-2.6.24-16-generic

title Ubuntu 8.04.1, memtest86+
root (hd0,7)
kernel /boot/memtest86+.bin
quiet

### END DEBIAN AUTOMAGIC KERNELS LIST

# This is a divider, added to separate the menu items below from the Debian
# ones.
title Other operating systems:
root


# This entry automatically added by the Debian installer for a non-linux OS
# on /dev/sda1
title Microsoft Windows XP Professional
root (hd0,0)
savedefault
makeactive
chainloader +1
*/

有知道原因的么。。。

...全文
1587 5 打赏 收藏 转发到动态 举报
写回复
用AI写文章
5 条回复
切换为时间正序
请发表友善的回复…
发表回复
wodeyouxian 2008-09-18
  • 打赏
  • 举报
回复
我的办法:


1.找一张带有grub4dos的虚拟启动盘,(如果找不到,email:tjb@tzc.edu.cn,我自己做的,5M),
2.记下linux安装路径,找到grub.conf里的引导linux的参数,记下来.自己机上没了,就参考别人的.
3.启动到虚拟dos下,fdisk /mbr,将mbr清掉.
输入grub,运行grub.将grub安装到mbr.copy 相应的stage到相应分区下.
修改menu.lst文件,将linux的引导信息拷贝到里面去.
重启.

=========
ps: 另一个方法,把grub4dos中的grub文件放在C盘下,再修改menu.lst文件也是一样的,只是启动过程变成了
windows ntldr==>grub===>linux or windows
这个方法更简单易行.
cceczjxy 2008-09-15
  • 打赏
  • 举报
回复
不行的话就重新安装grub看看
feelwithear 2008-09-14
  • 打赏
  • 举报
回复
没有改过。。。原来一直用的好好的,突然就出错了。。。。
fox000002 2008-09-13
  • 打赏
  • 举报
回复
硬盘或系统改动过了吧

修复 grub 的话要及时修正 menu.lst 和 /etc/fstab
speme 2008-09-13
  • 打赏
  • 举报
回复
如果不确定位置的话可以用tab来显示所有的分区,也可以用/dev/hd*这样的形式来setup.
更新说明: 2017-02-04(yaya) Ls command: Empty Folder returns false. 2016-12-08(yaya) 修正lz4、vhd不显示解压缩进度指示。增加lzma解压缩进度指示。 2016-11-09(不点) 0x8205 bit 5 = 1: 使checkkey闲置循环停止指令。 2016-04-13(yaya) 支持动画菜单 setmenu --graphic-entry=类型=菜单行数=菜单列数=图形宽(像素)=图形高(像素)=菜单行间距(像素) 菜单项0的路径文件名 类型: 位0:高亮指定颜色 位1:高亮颜色翻转 位2:高亮显示线框 位7:背景透明(最好使用黑色背景) 文件名: *n.??? 格式 n=00-99 高亮颜色由 color HIGHLIGHT=0xrrggbb 指定。 字符可以使用任意字型、字高、颜色,可以辅以图标。 2016-03-25(yaya) 菜单字符可以使用不同字型。 例如:"七" 使用不同字型,将 .hex 文件中的 unicode 码 “4e03” 修改为 “0080”, 将菜单中的 "七" 修改为 “\X0080”。 2016-03-23(yaya) 增强 echo 函数功能。 例如:echo -e \x18 显示 UTF-8 字符 0x18。 echo -e \X2191 显示 unicode 字符 0x2191。 2016-03-15(yaya) 1.增加动画控制热键 F2:播放/停止。 2.增加动画控制位 0x835b,位0:0/1=停止/播放。 3.增加精简字库模式:--simp=起始0,终止0,...,起始3,终止3 中文可以使用 --simp= ,内置字库应当包含 DotSize=[font_h],['simp'] 例如:font --font-high=24 --simp= /24_24.hex DotSize=24,simp 不使用热键: 可以加载 32*32 unifont 全字库 使用热键: 可以加载 24*24 unifont 全字库 使用精简字库: 可以加载 46*46 汉字全字库 使用精简字库及热键:可以加载 40*40 汉字全字库 4.不再支持 bin 格式字库。 2016-03-03(yaya) 1.增加图像背景色设置方法。 splashimage --fill-color=[0xrrggbb] 作用之一,作为小图像的背景。 作用之二,直接作为菜单的背景(即不加载图像背景)。此时只设置字体的前景色即可。 2.增加动画菜单。 splashimage --animated=[type]=[delay]=[last_num]=[x]=[y] START_FILE 类型[type]:bit 0-3: 播放次数 bit 4: 永远重复 bit 7: 透明背景 type=00:禁止播放 播放n次:序列图像各显示n次,时间独占。可作为启动前导、序幕。 永远重复:序列图像无限循环,时间与菜单共享。可作为菜单里的动画。 背景透明:即抠像。要求4角像素为背景色。 背景色最好为白色或黑色,这样可以去除一些灰色杂波。若是彩色背景,则应当非常干净。 提醒:请以16进制方式输入。否则易错。 延迟[delay]:序列图像之间的延迟。单位是滴答,即1/18.2秒。 序列数[last_num]:序列图像总数(2位数,从1开始计数)。 偏移[x]、[y]:图像偏移,单位像素。 起始图像文件 START_FILE 命名规则:*n.??? n: 1-9 或 01-99 或 001-999。 3.增加固定图像的背景色可以透明。 splashimage [--offset=[type]=[x]=[y]] FILE 类型[type]:bit 7: 透明背景 2016-02-14(yaya) setmenu 函数增加菜单项目背景短/满参数(默认短) 2016-01-19(yaya) splashimage 函数增加图像起始偏移(默认0) 2015-08-20(yaya) 1.支持非

19,612

社区成员

发帖
与我相关
我的任务
社区描述
系统使用、管理、维护问题。可以是Ubuntu, Fedora, Unix等等
社区管理员
  • 系统维护与使用区社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧