grub2 基础教程(续)

启动讨论 grub/grub2/syslinux/grub4dos/Lilo
回复
fatality
帖子: 42
注册时间: 2006-04-18 9:18

Re: grub2 基础教程(续)

#151

帖子 fatality » 2009-10-28 12:14

Hi, smallapple
最新正式版及其使用手册都可以在这里找到:http://grub.enbug.org/FrontPage
头像
smallapple
论坛版主
帖子: 7868
注册时间: 2009-03-28 15:12

Re: grub2 基础教程(续)

#152

帖子 smallapple » 2009-10-28 15:55

fatality 写了:Hi, smallapple
最新正式版及其使用手册都可以在这里找到:http://grub.enbug.org/FrontPage
3Q!
fatality
帖子: 42
注册时间: 2006-04-18 9:18

Re: grub2配置文件详解及部分命令用法介绍

#153

帖子 fatality » 2009-10-29 11:55

smallapple 写了:
3. grub2 引导软盘img镜像启动
比如要加载(hd1,1)根目录下的 a.img 镜像,先把 memdisk 从 memdisk.gz 中解压出来,用法是:
linux (hd1,1)/memdisk #镜像文件超过2.88M要加上 c=* h=* s=*
initrd (hd1,1)/a.img
boot
现在有bug,加载memdisk会自动重启,beta2还没修正。
按达人bean的提法,这点需要修正:
现在linux命令是跳过实模式初始化代码,直接引导32位模式的。
而memdisk是利用实模式代码来操作的,如果需要处理16位代码的话,应使用linux16/initrd16命令。

linux16 (hd1,1)/memdisk #镜像文件超过2.88M要加上 c=* h=* s=*
initrd16 (hd1,1)/a.img
boot

但还是有bug,引导img镜像会导致死机。英文好的同去,不妨去官网反应一下。必竟,引导img镜像,是一项非常有用的功能。
头像
睡皮打滚要啊
帖子: 141
注册时间: 2009-03-09 19:07

Re: grub2 基础教程(续)

#154

帖子 睡皮打滚要啊 » 2009-10-30 14:16

问个很傻的问题,30_os_prober这个文件是不是只能在终端里重命名(具体怎么做),因为我找到这个文件右键rename是灰的 :em06
头像
smallapple
论坛版主
帖子: 7868
注册时间: 2009-03-28 15:12

Re: grub2 基础教程(续)

#155

帖子 smallapple » 2009-10-30 15:27

cd /etc/grub.d/
sudo mv 30_os-prober 07_os-prober

sudo nautilus /etc/grub.d
打开后右键重命名
头像
睡皮打滚要啊
帖子: 141
注册时间: 2009-03-09 19:07

Re: grub2 基础教程(续)

#156

帖子 睡皮打滚要啊 » 2009-10-30 15:55

搞定了 :em88 谢谢
shishihoule
帖子: 4
注册时间: 2009-10-31 12:27

Re: grub2 基础教程(续)

#157

帖子 shishihoule » 2009-10-31 14:33

mark
正在下载live cd 也许能用上
电脑菜鸟lx
帖子: 15
注册时间: 2009-09-13 0:16

Re: grub2 基础教程(续)

#158

帖子 电脑菜鸟lx » 2009-10-31 20:45

请问我在安装完ubuntu9.10之后vista就找不到了,grub-update之后也没有,那到底是应该直接将

menuentry "Windows Vista (loader) (on /dev/sda1)" {
insmod ntfs
set root=(hd0,1)
search --no-floppy --fs-uuid --set fada29cbda2984cb
chainloader +1
}

加进去呢,还是把在
### BEGIN /etc/grub.d/30_os-prober 中的这一段
if keystatus; then
if keystatus --shift; then
set timeout=-1
else
set timeout=0
fi
else
if sleep$verbose --interruptible 3 ; then
set timeout=0
fi
fi
删除或修改三处set timeout=<大于0>
另外修改之后保存会出现“您试图将文件保存至只读磁盘。请检查键入的位置是否正确,然后重试。”的警告改如何解决呢,期待你的答复,刚刚完全弄好ubuntu,vista就不见了,都郁闷死了,找了一整天了, :em20
希望你能帮我解决,先谢谢了
头像
smallapple
论坛版主
帖子: 7868
注册时间: 2009-03-28 15:12

Re: grub2 基础教程(续)

#159

帖子 smallapple » 2009-10-31 20:50

你是硬盘安装的,还是光盘安装的?
先看看你的vista分区下系统文件正常不。
fatality
帖子: 42
注册时间: 2006-04-18 9:18

Re: grub2 基础教程(续)

#160

帖子 fatality » 2009-10-31 21:08

关于不能引导软盘镜像的问题,已经有人找到变通办法了

> Hello
> J. Bakshi wrote:
> > Hello list,
> >
> > Finally I got success booting hdt.c32 module ( hdt = hardware
> > detection tool) with the latest floppy image released by hdt team.
> > hdt.c32 is a syslinux module. As per their suggestion the following
> > config works for me from usb stick.
> >
> > menuentry HDT {
> > linux16 /memdisk
> > initrd16 /<hdt_floppy_image>
> > }
> >
> > Though it would be nice to see grub's power to directly load
> > syslinux module like this one :-)
> >
> >
> I would be happy to have syslinux com32 glue level. Are you willing to
> code one?
电脑菜鸟lx
帖子: 15
注册时间: 2009-09-13 0:16

Re: grub2 基础教程(续)

#161

帖子 电脑菜鸟lx » 2009-10-31 22:22

是光盘安装的
电脑菜鸟lx
帖子: 15
注册时间: 2009-09-13 0:16

Re: grub2 基础教程(续)

#162

帖子 电脑菜鸟lx » 2009-10-31 22:35

文件都挺正常的,不过好像多了一个复制boot的文件夹
头像
smallapple
论坛版主
帖子: 7868
注册时间: 2009-03-28 15:12

Re: grub2 基础教程(续)

#163

帖子 smallapple » 2009-10-31 22:44

光盘安装没道理不认vista的。 :em06

sudo gedit /etc/grub.d/30_os-prober
把 timeout 改成大于 0

sudo gedit /etc/grub.d/40_custom
加上

代码: 全选

menuentry "Windows Vista (loader) (on /dev/sda1)" {
insmod ntfs
set root=(hd0,1)
search --no-floppy --fs-uuid --set fada29cbda2984cb
chainloader +1
}
完了再
sudo update-grub
再重启看看
头像
ubuntua
帖子: 542
注册时间: 2009-10-04 11:23

Re: grub2 基础教程(续)

#164

帖子 ubuntua » 2009-10-31 22:48

做个记号
电脑菜鸟lx
帖子: 15
注册时间: 2009-09-13 0:16

Re: grub2 基础教程(续)

#165

帖子 电脑菜鸟lx » 2009-10-31 22:56

有很多timeout应该是哪一个啊
回复