OpenBSD, NetBSD, FreeBSD是同门三兄弟!OpenBSD以安全著称, 支持的平台很多!现在主要有三个分支:stable, release, current. 每六个月出一个release! 主要版本号是:3.1stable, 3.3release, 3.4 current. 3.4release 11月1日发行!
stable是非常稳定的版本, release是发行版, 还有一些错误, 慢慢会发展成stable版, current是新功能版, 属最新技术的版本! 一般主要使用的是release, stable, current不支持使用, 它的错误较多, 一般用户使用不方便!具体信息可查看OpenBSD主站上的介绍!
主要安装方式:CD-ROM, FTP, LocalFilesystem等!
安装前的准备
一、 下载所需要的文件:floppy33.fs, 这可从一般的OpenBSD FTP站点上下载!
国内的OpenBSD很少, 我一个都没找到! 在安装时从国外的站点上下载文件很慢, 我上次晚上安装时到了那里就不管理它了, 到第二天早上才去继续安装!
下面说说启动盘的镜像文件:floppy33.fs, floppyB33.fs, floppyC33.fs
floppy33.fs 桌面PC版本, 它支持一般的PCI, ISA NICs, IDE, SCSI接口, 还有一些PCMCIA接口。
floppyB33.fs 服务器版本, 支持很多的RAID, 和一些SCSI。但一些基本的SCSI, ISA NICs, EISA都删除了!
floppyC33.fs 笔记本电脑版本, 支持Cardbus, PCMCIA.
我想, 一般都是桌面PC, 我自己的就是, 下载floppy33.fs.
下面是安装所需要的一些基本文件, 我把它下载下来放到内部网的FTP上了, 这样安装起来快一些:
bsd, bsd.rd, base33.tgz, etc33.tgz, comp33.tgz, man33.tgz, misc33.tgz, game33.tgz, xbase33.tgz,xfont33.tgz, xserv33.tgz, xshare33.tgz.
我还下载了ports.tar.gz, src.tar.gz, sys.tar.gz, 系统安装后这些ports tree, 内核源码都没安装, 要自己手动安装的。
二、制作启动盘
现在我们已下载了软盘镜像, 开始制作启动盘
1. Unix 下:
我是在slackware上制作的, 我在windows 下用rawrite2.exe没作成功!
# fdformat /dev/fd0
# dd if=floppy33.fs of=/dev/fd0 bs=32k
2. windows下(请参考OpenBSD主站上的安装指南)
主要工具都放在FTP站点上的TOOLS目录里, 主要有: rawrite, fdimage, ntrw, rawrite不能在windows NT, windows 2000 or XP下使用!
相关操作可自己找资料, 都很简单, 在DOS下操作!
现在我们要收集自己计算机上的信息:什么平台, 硬盘上的资料要不要备份?, 网卡信息(IP,subnet masks, gateway, DNS) 一些isa卡可以安装时以dmesg查看!
已下载了安装所需要的文件!现在我们进行的是FTP安装, 我将下载的文件放在FTP上, 目录是openbsd/OpenBSD下!这样安装快很多!
安装过程
用软盘启动系统!我们会看到蓝色背景的字!这里是OpenBSD的开机信息!然后我们会看到下面的这个:
erase ^?, werase ^W, kill ^U, intr ^C, status ^T
(I)nstall, (U)pgrade or (S)hell? I
选择I, 安装新系统, 如果是从原来的系统上升级则选择U, 或者你可以选择S, 在SHELL下操作, 其实当你在安装过程序中自己有某些设置错误Ctrl + c中止后, 也是回到这个SHEEL下操作的!在SHEEL下执行install就是安装系统。
Welcome to the OpenBSD/i386 3.3 install program.
This program will help you install OpenBSD in a simple and rational way. At
any prompt except password prompts you can run a shell command by typing
'!foo', or escape to a shell by typing '!'. Default answers are shown in []'s
and are selected by pressing RETURN. At any time you can exit this program by
pressing Control-C and then RETURN, but quitting during an install can leave
your system in an inconsistent state.
Specify terminal type: [vt220] Enter
Do you wish to select a keyboard encoding table? [n] y
选择键盘类型, 一些都是US。
IS YOUR DATA BACKED UP? As with anything that modifies disk contents, this
program can cause SIGNIFICANT data loss.
It is often helpful to have the installation notes handy. For complex disk
configurations, relevant disk hardware manuals and a calculator are useful.
Proceed with install? [n] y
下面我们继续安装:
Cool! Let's get to it...
You will now initialize the disk(s) that OpenBSD will use. To enable all
available security features you should configure the disk(s) to allow the
creation of separate filesystems for /, /tmp, /var, /usr, and /home.
选择从哪个硬盘上安装, 我的系统只挂了一个小硬盘, 所以只一个!
Available disks are: wd0.
Which one is the root disk? (or done) [wd0] Enter
是否整个硬盘都安装OpenBSD, 是.
Do you want to use *all* of wd0 for OpenBSD? [no] yes
Treating sectors 63-6303024 as the OpenBSD portion of the disk.
You can use the 'b' command to change this.
Initial label editor (enter '?' for help at any prompt)
?
现在我们来进行硬盘分区, 这里打入?寻求帮助!
Available commands:
p [unit] - print label.
M - show entire OpenBSD man page for disklabel.
e - edit drive parameters.
a [part] - add new partition.
b - set OpenBSD disk boundaries.
c [part] - change partition size.
d [part] - delete partition.
D - set label to default.
g [d|b] - Use [d]isk or [b]ios geometry.
m [part] - modify existing partition.
n [part] - set the mount point for a partition.
r - recalculate free space.
u - undo last change.
s [path] - save label to file.
w - write label to disk.
q - quit and save changes.
x - exit without saving changes.
X - toggle expert mode.
z - zero out partition table.
? [cmnd] - this message or command specific help.
Numeric parameters may use suffixes to indicate units:
'b' for bytes, 'c' for cylinders, 'k' for kilobytes, 'm' for megabytes,
'g' for gigabytes or no suffix for sectors (usually 512 bytes).
Non-sector units will be rounded to the nearest cylinder.
Entering '?' at most prompts will give you (simple) context sensitive help.
我分了五个区, a 根分区 200M, b 交换分区 300M , d 100M /tmp, e 100M /var , f 最后的全给 /usr,
使用 d删除分区,a 创建分区,p 查看分区情况,q 退出!
d a 删除a分区
a a 创建a分区
p g 查看分区, 大小以G显示
p m 查看分区, 大小以M显示
下面我们挂载分区:
The root filesystem will be mounted on wd0a.
wd0b will be used for swap space.
Mount point for wd0d (size=122976k), none or done? [/tmp] Enter
Mount point for wd0e (size=82152k), none or done? [/var] Enter
Mount point for wd0g (size=2097144k), none or done? [/usr] Enter
Mount point for wd0h (size=4194288k), none or done? [/home] Enter
Mount point for wd0d (size=122976k), none or done? [/tmp] done
Done - no available disks found.
You have configured the following partitions and mount points:
wd0a /
wd0d /tmp
wd0e /var
wd0g /usr
wd0h /home
格式化分区:
The next step creates a filesystem on each partition, ERASING existing data.
Are you really sure that you're ready to proceed? [n] y
/dev/rwd0a: 307440 sectors in 305 cylinders of 16 tracks, 63 sectors
200MB in 20 cyl groups (16 c/g, 7.88MB/g, 1920 i/g)
/dev/rwd0b: 245952 sectors in 244 cylinders of 16 tracks, 63 sectors
300MB in 16 cyl groups (16 c/g, 7.88MB