用LILO引导另一块硬盘上的windows
时间:2006-04-09
来源:互联网
最新在搞bootsplash和修改lilo menu菜单字体的颜色,google的很多都是基于grub的。lilo的很少,没办法只有自己硬着头皮去man lilo.conf,居然把我的windows启动也搞定了。
分享一下我的心得
我是这样硬盘分区大概如下
hda 80g
/dev/hda1 1 47 377496 82 Linux swap
/dev/hda2 * 48 850 6450097+ a5 FreeBSD
/dev/hda3 * 851 1033 1469947+ 83 Linux slackware /
/dev/hda4 1034 9729 69850620 5 Extended
/dev/hda5 1034 1216 1469916 83 Linux slackware /usr/local
/dev/hda6 1217 4864 29302528+ 83 Linux
/dev/hda7 4865 9729 39078081 83 Linux
hdb 20g
/dev/hdb1 1 244 1959898+ 83 Linux
/dev/hdb2 245 488 1959930 83 Linux
/dev/hdb3 489 1218 5863725 83 Linux
/dev/hdb4 1219 2434 9767520 83 Linux
hdc 20g
/dev/hdc1 * 1 4065 2048256 7 HPFS/NTFS windows 2003
Partition 1 does not end on cylinder boundary.
/dev/hdc2 4065 10153 3068415 b W95 FAT32
Partition 2 does not end on cylinder boundary.
/dev/hdc3 10160 38792 14431032 f W95 Ext'd (LBA)
Partition 3 does not end on cylinder boundary.
/dev/hdc5 10160 30479 10241248+ b W95 FAT32
/dev/hdc6 30480 38792 4189720+ b W95 FAT32
hdd fireball 15g or liteon 16p9s(dvd)
《linux系统管理员手册》上提到用lilo引导windows,/etc/lilo.conf看起来大概如下(以我的情况举例)
other = /dev/hdc1
lable = Windows
table = /dev/hdc
但这样,我的windows始终也没引导起来。
仔细想想这样应该可以引导同一个硬盘的多个系统,但对于其他硬盘的系统就不行。
我的freebsd和slackware共存一个硬盘上,这样就没问题。
other = /dev/hda2
lable = Freebsd
table = /dev/hda
man lilo.conf
--------------------------------------------------------
# other operating systems:
other=/dev/hda3
label=dos
boot-as=0x80 # must be C:
other=/dev/hdb1
label=Win98
boot-as=0x80 # must be C:
--------------------------------------------------------
我把原来的
table = /dev/hdc
改为 boot-as=0x80就可以了。
但这里我有两点疑惑,如果是lilo直接读取hdb的mbr,0x80转换为10进制是128。如果是mbr我想应该是前512字节呀?
must be C:
如果windows在C盘,也就是上面的hdb1。如果在d盘,是否把hdb1改为hdb2就可以了?
分享一下我的心得
我是这样硬盘分区大概如下
hda 80g
/dev/hda1 1 47 377496 82 Linux swap
/dev/hda2 * 48 850 6450097+ a5 FreeBSD
/dev/hda3 * 851 1033 1469947+ 83 Linux slackware /
/dev/hda4 1034 9729 69850620 5 Extended
/dev/hda5 1034 1216 1469916 83 Linux slackware /usr/local
/dev/hda6 1217 4864 29302528+ 83 Linux
/dev/hda7 4865 9729 39078081 83 Linux
hdb 20g
/dev/hdb1 1 244 1959898+ 83 Linux
/dev/hdb2 245 488 1959930 83 Linux
/dev/hdb3 489 1218 5863725 83 Linux
/dev/hdb4 1219 2434 9767520 83 Linux
hdc 20g
/dev/hdc1 * 1 4065 2048256 7 HPFS/NTFS windows 2003
Partition 1 does not end on cylinder boundary.
/dev/hdc2 4065 10153 3068415 b W95 FAT32
Partition 2 does not end on cylinder boundary.
/dev/hdc3 10160 38792 14431032 f W95 Ext'd (LBA)
Partition 3 does not end on cylinder boundary.
/dev/hdc5 10160 30479 10241248+ b W95 FAT32
/dev/hdc6 30480 38792 4189720+ b W95 FAT32
hdd fireball 15g or liteon 16p9s(dvd)
《linux系统管理员手册》上提到用lilo引导windows,/etc/lilo.conf看起来大概如下(以我的情况举例)
other = /dev/hdc1
lable = Windows
table = /dev/hdc
但这样,我的windows始终也没引导起来。
仔细想想这样应该可以引导同一个硬盘的多个系统,但对于其他硬盘的系统就不行。
我的freebsd和slackware共存一个硬盘上,这样就没问题。
other = /dev/hda2
lable = Freebsd
table = /dev/hda
man lilo.conf
--------------------------------------------------------
# other operating systems:
other=/dev/hda3
label=dos
boot-as=0x80 # must be C:
other=/dev/hdb1
label=Win98
boot-as=0x80 # must be C:
--------------------------------------------------------
我把原来的
table = /dev/hdc
改为 boot-as=0x80就可以了。
但这里我有两点疑惑,如果是lilo直接读取hdb的mbr,0x80转换为10进制是128。如果是mbr我想应该是前512字节呀?
must be C:
如果windows在C盘,也就是上面的hdb1。如果在d盘,是否把hdb1改为hdb2就可以了?
作者: r00to 发布时间: 2006-04-09
这里和mbr是多少字节没有关系。boot-as的数值是传递给BIOS的硬盘编号,详情请 man lilo.conf
看boot-as选项的解释。
看boot-as选项的解释。
作者: windrose 发布时间: 2006-04-09
在stardict的帮助下看了差不多一个小时,终于把那20多行弄得似懂非懂了。:-)
作者: r00to 发布时间: 2006-04-09
相关阅读 更多
热门阅读
-
office 2019专业增强版最新2021版激活秘钥/序列号/激活码推荐 附激活工具
阅读:74
-
如何安装mysql8.0
阅读:31
-
Word快速设置标题样式步骤详解
阅读:28
-
20+道必知必会的Vue面试题(附答案解析)
阅读:37
-
HTML如何制作表单
阅读:22
-
百词斩可以改天数吗?当然可以,4个步骤轻松修改天数!
阅读:31
-
ET文件格式和XLS格式文件之间如何转化?
阅读:24
-
react和vue的区别及优缺点是什么
阅读:121
-
支付宝人脸识别如何关闭?
阅读:21
-
腾讯微云怎么修改照片或视频备份路径?
阅读:28