全部博文(89)
分类: LINUX
2009-07-30 15:13:57
####################
#
# 环境说明
#
####################
OS: debian-501-lenny-i386
disk: U盘为/dev/sdb, 专门分一个区/dev/sdb1
####################
#
# 分区
#
####################
# 注意 加启动标记。
fdisk /dev/sdb
fdisk -l
--------------------------------------------------------------------
/dev/sdb1 * 1 1014 974423 83 Linux
####################
#
# 格式化
#
####################
aptitude install dosfstools
mkdosfs /dev/sdb1
#############################
#
# boot loader 安装与配置
#
#############################
aptitude install syslinux mtools
--------------------------------------------------------------------------------
syslinux # utilities for the syslinux bootloaders
mtools # Tools for manipulating MSDOS files
syslinux /dev/sdb1
mount /dev/sdb1 /mnt
vim /mnt/syslinux.cfg
-------------------------------
default vmlinuz
append initrd=initrd.gz
####################
#
# 拷贝 文件
#
####################
cd /mnt
wget ftp://ftp.debian.org/debian/dists/lenny/main/installer-i386/current/images/hd-media/initrd.gz
wget ftp://ftp.debian.org/debian/dists/lenny/main/installer-i386/current/images/hd-media/vmlinuz
cp debian-501-lenny-i386-netinst.iso /mnt
umonut /mnt
### OVER... 可以进行U盘安装
####################
#
# 修复 mbr
#
####################
aptitude install mbr
-------------------------------------------------------------------------
mbr # Master Boot Record for IBM-PC compatible computers.
install-mbr /dev/sdb