LinuxSir.cn,穿越时空的Linuxsir!

 找回密码
 注册
搜索
热搜: shell linux mysql
查看: 946|回复: 0

修复Grub启动的疑难问题请教!(已解决)

[复制链接]
发表于 2006-7-5 12:28:38 | 显示全部楼层 |阅读模式
我用的是Suse10.1,使用中发现根分区"/" 快满了,就在windows下用Acronis DiskDirector 将“/”分区扩大了1GB,/boot 也在“/”分区下,重启动后grub丢失了。

我用suse安装盘进入rescue模式。

#grub
grub>root (hd0, //按TAB键出来:

partition num 0, Filesystem type is vfat ...
partition num 2, Filesystem type is reiserfs...     //我的根分区"/" 在这里
partition num 4, Filesystem type is vfat...
partition num 5, Filesystem type is ext2fs...       //我的"/home"分区在这里
partition num 6, Filesystem type unknown...     //8MB 没有格式化的空间

根据以上信息,我选择
grub>root (hd0,2)

grub>setup (hd0)

提示安装成功(succeeded).

重启后, 显示grub菜单,但是不能启动Linux.

看来分区resize 和 move 后partition num 改变了.

又进入rescue 模式, 接着修改/boot/grub/menu.lst

将原来的 root (hd0,5) 改为 root (hd0,2) ; 将root=/dev/hda6, 改为root=/dev/hda3, 如下所示:

-----------------------------------------------------------------------------------
title Suse10.1
root (hd0,2)
kernel /boot/vmlinuz root=/dev/hda3  vga=0x317 resume=/dev/hda6 splash=silent showopts
initrd /boot/initrd
-----------------------------------------------------------------------------------
上面resume=/device 就是指/home 分区吧?

现在有启动过程了,但在fsck (检查文件系统)时出错, 启动过程就停在那里.
出错信息大致如下:
--------------------------------------------------------------------------------------
[/sbin/fsck.ext3(1) --home]fsck.ext3 -a /dev/hda7
fsck.ext3: Bad magic number in superblock while trying to open /dev/hda7
-----------------------------------------------------------------------------------------------

我的/home 是独立分区, 在hda6上 (对应partition num 5).
上面出错信息的hda7 对应 partition num 6, Filesystem type unknown...     //8MB 没有格式化的空间

怎么fsck 要检查没有格式化的空间呢? 在suse 里( /home 独立分区) resume=/device 是否必要?

请问如何解决这个问题?
=======================================================

哎。。。只差修改fstab,在fstab里把改变了的partition num 对照修改就行了。
您需要登录后才可以回帖 登录 | 注册

本版积分规则

快速回复 返回顶部 返回列表