安装linux(6)
--- (文/曾瑞源)
□ 系统设定
刚刚完成的安装工作, 所花时间可能会用掉一两个小时之间, 假
如想更快些, 在後面我会示□快速自动安装法。
下面画面是刚刚安装过程最後的一个画面, 也就是在安装完成时,
安装程式会立刻询问我们要不要接著进行系统设定, 我们按
选择 Yes。
<< 画面 5-58 >>
________________ CONFIGURE YOUR SYSTEM? _________________
□ Now it's time to configure your Linux system. If this □ □ is a new system, you must configure it now or it will □ □ not boot correctly. Otherwise, you can back out to the □ □ main menu if you're sure you want to skip this step. □ □ If you've installed a new kernel image, it's important □ □ to reconfigure your system so that you can install □ □ LILO (the Linux loader) or create a bootdisk using the □ □ new kernel. Do you want to move on to the CONFIGURE □ □ option? □ □ □ __________________________________________________________□ □ < Yes > < No > □ __________________________________________________________□
制作一张系统启动磁片
<< 画面 5-59 >>
____________________ MAKE BOOT DISK? _____________________
□ It is HIGHLY recommended that you make a standard boot □ □ disk for your Linux system at this time. Such a disk □ □ can be very handy if LILO of a kernel is ever □ □ improperly installed. Since the boot disk will contain □ □ a kernel that is independent of LILO and the kernel on □ □ your hard drive, you'll still be able to use it to □ □ boot your system no matter what you do to LILO or your □ □ hard drive kernel. Would you like to make a standard □ □ boot disk? □ □ □ __________________________________________________________□ □ < Yes > < No > □ __________________________________________________________□
<< 画面 5-60 >>
____________________ BOOT DISK CREATION ____________________□ □ □ □ Now put a formatted floppy in your boot drive. □ □ This will be made into your Linux boot disk. Use this to □ □ boot Linux until LILO has been configured to boot from □ □ the hard drive. □ □ □ □ Any data on the target disk will be destroyed. □ □ □ □ YES creates the disk, NO aborts. □ □ □ ____________________________________________________________□ □ < Yes > < No > □ ____________________________________________________________□
<< 画面 5-61 >>
________________ CREATING DISK _________________
□ Creating boot disk from 'vmlinuz'... □ □ □ □ □ ________________________________________________□
设定数据机
以下询问是有配备有数据机 (Modem)? 有数据机则直接按
键, 若没有, 使用 或 左右方向键把反白移到 < No >, 再按
键。
<< 画面 5-62 >>
________________________ MODEM CONFIGURATION _________________________
□ □ □ This part of the configuration process will create a link in /dev □ □ from your callout device (cua0, cua1, cua2, cua3) to /dev/modem. □ □ You can change this link later if you put your modem on a different □ □ port. □ □ □ □ Would you like to set up your modem? □ □ 2 □ _______________________________________________________________________
□ < Yes > < No > □ _______________________________________________________________________
若有数据机, 则进一步选择数据机所在之串列埠。 请移动反白
做正确选择。 以下这动作相当於正常 Linux环境下的指令:
$ ln -s /dev/ttyS1 mouse, 但是把 ttyS1 换成正确的一个。
<< 画面 5-63 >>
________________ SELECT CALLOUT DEVICE __________________□ □ Please select the callout device which you would like □ □ to use for your modem: □ □ ______________________________________________________□□ □□ cua0 com1: under DOS □□ □□ cua1 com2: under DOS □□ □□ cua2 com3: under DOS □□ □□ cua3 com4: under DOS □□ □ ______________________________________________________□□ __________________________________________________________□ □ < OK > □ __________________________________________________________□
设定滑鼠装置
以下询问有没有滑鼠装置?
<< 画面 5-64 >>
______________________ MOUSE CONFIGURATION ________________________□ □ □ □ This part of the configuration process will create a link in /dev □ □ from your mouse device to /dev/mouse. You can change this link □ □ later if the setting chosen does not work, or if you switch to a □ □ different type of mouse. □ □ □ □ Would you like to set up your mouse? □ □ □ ____________________________________________________________________□ □ < Yes > < No > □ ____________________________________________________________________□
以下回答滑鼠种类。 很多朋友不清楚, 我们一般常的滑鼠都是串
列式滑鼠, 这些是串接在 RS-232C 通讯埠上 (25针或9针), 另外有一
些圆形接头的滑鼠, 这些则是各品牌的 Bus 滑鼠。 以下选项 1 与 6
分别是两键式与三键式串列滑鼠, 请做小心正确选择。
<< 画面 5-65 >>
__________________ SELECT MOUSE TYPE ____________________□ □ These mouse types are supported: □ □ ______________________________________________________□□ □□ 1 Microsoft compatible serial mouse □□ □□ 2 C&T 82C710 or PS/2 style mouse (Auxiliary port) □□ □□ 3 Logitech Bus Mouse □□ □□ 4 ATI XL Bus Mouse □□ □□ 5 Microsoft Bus Mouse □□ □□ 6 Mouse Systems serial mouse □□ □ ______________________________________________________□□ __________________________________________________________□ □ < OK > □ __________________________________________________________□
对串列滑鼠来说, 我们还要具体指定滑鼠所接的通讯埠所在, 如下图。
<< 画面 5-66 >>
__________________ SELECT SERIAL PORT ___________________
□ Your mouse requires a serial port. Which one would you □ □ like to use? □ □ ______________________________________________________□□ □□ ttyS0 com1: under DOS □□ □□ ttyS1 com2: under DOS □□ □□ ttyS2 com3: under DOS □□ □□ ttyS3 com4: under DOS □□ □ ______________________________________________________□□ __________________________________________________________□ □ < OK > □ __________________________________________________________□
设定唯独光碟机
下面问有没有唯独式光碟机?
<< 画面 5-67 >>
______ CONFIGURE CD-ROM? _______
□ □ □ Do you have a CD-ROM? □ □ □ _________________________________
□ < Yes > < No > □ _________________________________
若回答有唯读式光碟机, 以下动作则是进一步做一个 /dev/cdrom
连结档。 这样做方便使用者或管理者统一以 /dev/cdrom 代表光碟装
置, 否则不同类型光碟机在 Linux系统下的档案名称并不一样, 这对
生手还说会很困扰, 比方说 Panasonic 562B/563B 牌为 /dev/sbpcd,
Mitsumi牌为 /dev/mcd, Sony 535 为 /dev/sonycd, Sony CDU31A 为
/dev/cdu31a, 至於 SCSI 规格则可能为 /dev/sr0、 /dev/sr1、
/dev/scd0 或 /dev/scd1 等等其中之一。
<< 画面 5-68 >>
____________ Configuring CD-ROM link (/dev/cdrom) _____________
□ □ □ What type of CD-ROM drive do you have? □ □ □ □ ____________________________________________________________□□ □□ 1 SCSI [ /dev/sr0, /dev/sr1, /dev/scd0, or /dev/scd1 ] □□ □□ 2 Sony CDU31A [ /dev/cdu31a ] □□ □□ 3 Sony 535 [ /dev/sonycd ] □□ □□ 4 Mitsumi [ /dev/mcd ] □□ □□ 5 Sound Blaster Pro (Panasonic) [ /dev/sbpcd ] □□ □ ____________________________________________________________□□ ________________________________________________________________□ □ < OK > □ ________________________________________________________________□
设定数据机速度
以下设定数据机速度, 一般 14.4K v.32bis/v.42bis 数据机不妨
指定最高速的 38400 (Linux可以用 setserial 这支工具程式把 DTE
通讯数度调为 57600 或甚至 115200 bps)。
<< 画面 5-69 >>
__________________ SET YOUR MODEM SPEED __________________□ □ Please select a modem speed. You may use setserial □ □ later to make 38400 stand for a higher baud rate if □ □ these speeds aren't fast enough. □ □ ______________________________________________________□□ □□ 38400 □□ □□ 19200 □□ □□ 9600 □□ □□ 4800 □□ □□ 2400 □□ □□ 1200 □□ □□ 300 Ouch! □□ □ ______________________________________________________□□ __________________________________________________________□ □ < OK > □ __________________________________________________________□
设定 LILO
以下进行到最重要的, 设定 LILO 开机选择程式。 LILO 是一个
相当优秀的系统工具, 读这若漏装了这软体, 将非常可惜。 有了 LILO,
您不需要任何其他开机选择程式。
假如我们电脑内只有 Linux 系统, 没有其他作业系统, 这时只需
执行以下 Begin 及 Linux 两个程序, 假如说硬碟内有 DOS, 而我们
也想开机时可以选择DOS或 Linux, 这样子也把以下 DOS选项也一并执
行, 当确定设定无误後, 执行 Install程序。 以下我再分别简单说明
各步骤之作用:
Begin: 设定 LILO 安装模式, 比方安装在硬碟 MBR、 Superblock
或者软碟, 要不要 LILO 稍作延迟等等细节。
Linux: 设定把 Linux包含进开机选择。
DOS : 设定把 DOS 包含进开机选择。
Install: 实际安装动作
以下画面中, 我们就把反白移到 Begin 选项上。
<< 画面 5-70 >>
__________________________ LILO INSTALLATION __________________________□ □ LILO (the Linux Loader) allows you to boot Linux from your hard □ □ drive. To install, you make a new LILO configuration file by □ □ creating a new header and then adding at least one bootable □ □ partition to the file. Once you've done this, you can select the □ □ install option. Alternately, if you already have an /etc/lilo.conf, □ □ you may reinstall using that. If you make a mistake, you can always □ □ start over by choosing 'Begin'. Which option would you like? □ □ ___________________________________________________________________ □ □□ Begin Start LILO configuration with a new LILO header □□ □□ Linux Add a Linux partition to the LILO config file □□ □□ OS/2 Add an OS/2 partition to the LILO config file □□ □□ DOS Add a DOS partition to the LILO config file □□ □□ Install Install LILO □□ □□ Recycle Reinstall LILO using the existing lilo.conf □□ □□ Skip Skip LILO installation and exit this menu □□ □□ View View your current /etc/lilo.conf □□ □□ Help Read the Linux Loader HELP file □□ □ ___________________________________________________________________ □ _______________________________________________________________________
□ < OK > □ _______________________________________________________________________
下面首先询问要不要在启动时, 传一些参数给 Kernel。 据笔者
了解, 有些情况会有这需要, 比方说您使用级特殊规格的硬碟 (IBM
牌硬碟可能是其中之一), 还有比方说您的光碟机控制卡 Kernel无法
侦测到, 另外还有配备两块网路卡时, 这些情况都会需要在系统启动
时额外传参数给 Kernel。
不过, 我建议读者朋友先忽略这操作, 等系统设定完成後, 若发
觉有需要, 届时手工编修 /etc/lilo.conf 档即可。
<< 画面 5-71 >>
______________________□OPTIONAL append= LINE ________________________□ □ Some systems might require extra parameters to be passed to the □ □ kernel in order to boot. An example would be the hd=cyl,hds,secs □ □ needed with some SCSI systems and some machines with IBM □ □ motherboards. If you needed to pass parameters to the kernel when □ □ you booted the Slackware bootkernel disk, you'll probably want to □ □ enter the same ones here. Most systems won't require any extra □ □ parameters. If you don't need any, just hit ENTER to continue. □ □ __________________________________________________________________□□ □□ □□ □ __________________________________________________________________□□ ______________________________________________________________________□ □ < OK > □ ______________________________________________________________________□
底下我们就来选择开机模式。 以下有三个选项, 我分别解释如下:
MBR: MBR是位在第一颗硬碟、第一sylinder内的第一个sector,
电脑一启动电源後, 会先读取这区域, 来决定开机。
Root: 这是所谓 superblock, 就是把 LILO 装在 Linux 所在
的分割区。
Floppy: 指定把LILO安装在软碟上, 这样可以软碟开机。
以上 MBR 与 Floppy可能比较常用, 第一次安装 Linux的生手,
笔者尤其推荐用软碟开机, 等熟悉後, 最好把也同时设定 MBR, 这
样万一其中一个坏掉, 还可以用另外一个方式开机。
<< 画面 5-72 >>
________________ SELECT LILO TARGET LOCATION _________________
□ LILO can be installed to a variety of places: the master □ □ boot record of your first hard drive, the superblock of □ □ your root Linux partition (which could then be made the □ □ bootable partition with fdisk), or a formatted floppy disk. □ □ If you're using a boot system such as OS/2's Boot Manager, □ □ you should use the Root selection. Please pick a target □ □ location: □ □ ___________________________________________________________ □ □□ MBR Use the Master Boot Record □□ □□ Root Use superblock of the root Linux partition □□ □□ Floppy Use a formatted floppy disk in the boot drive □□ □ ___________________________________________________________ □ _______________________________________________________________
□ < OK > □ _______________________________________________________________
以下询问要不要开机时, 让 LILO停顿一下, 若选择 None, 则开机
时, 除非按住 或 键, 这样会迫使 LILO停下来, 否则
LILO 不会停下来。
照笔者的习惯, 我习惯设定停顿五秒钟, 在这五秒钟内, 只要我碰
一下 键, 就会出现 LILO: 提示符号, 我再进一步按一下
键, 就会出现所有 OS 的选单。
<< 画面 5-73 >>
________________________ CHOOSE LILO DELAY __________________________□ □ How long would you like LILO to wait for you to hit left-shift to □ □ get a prompt after rebooting? If you let LILO time out, it will □ □ boot the first OS in the configuration file by default. □ □ __________________________________________________________________□□ □□ None Don't wait at all - boot straight into the first OS □□ □□ 5 5 seconds □□ □□ 30 30 seconds □□ □□ Forever Present a prompt and wait until a choice is made □□ □ __________________________________________________________________□□ ______________________________________________________________________□ □ < OK > □ ______________________________________________________________________□
以上已经指定好 LILO 的运作方式了, 接下来我们就要把我们硬
碟里现的 OS, 全部加入 LILO 的开机选单中。 底下先把反白移道第
二行。
<< 画面 5-74 >>
__________________________ LILO INSTALLATION __________________________□ □ LILO (the Linux Loader) allows you to boot Linux from your hard □ □ drive. To install, you make a new LILO configuration file by □ □ creating a new header and then adding at least one bootable □ □ partition to the file. Once you've done this, you can select the □ □ install option. Alternately, if you already have an /etc/lilo.conf, □ □ you may reinstall using that. If you make a mistake, you can always □ □ start over by choosing 'Begin'. Which option would you like? □ □ ___________________________________________________________________ □ □□ Begin Start LILO configuration with a new LILO header □□ □□ Linux Add a Linux partition to the LILO config file □□ □□ OS/2 Add an OS/2 partition to the LILO config file □□ □□ DOS Add a DOS partition to the LILO config file □□ □□ Install Install LILO □□ □□ Recycle Reinstall LILO using the existing lilo.conf □□ □□ Skip Skip LILO installation and exit this menu □□ □□ View View your current /etc/lilo.conf □□ □□ Help Read the Linux Loader HELP file □□ □ ___________________________________________________________________ □ _______________________________________________________________________
□ < OK > □ _______________________________________________________________________
底下侦测到一共有两个 Linux属性的分割区, 我们在空白内填入
想要 LILO 开机启动的分割区。
<< 画面 5-75 >>
________________________ SELECT LINUX PARTITION ________________________□ □ These are your Linux partitions: □ □ □ □ Device Boot Begin Start End Blocks Id System □ □ /dev/hdb1 1 1 100 50368+ 83 Linux native □ □ /dev/hdb3 161 161 300 70560 83 Linux native □ □ □ □ Which one would you like LILO to boot? □ □ ____________________________________________________________________□□ □□dev/hdb3 □□ □ ____________________________________________________________________□□ □ □ □ □ □ □ □ □ □ □ □ □ ________________________________________________________________________□ □ < OK > □ ________________________________________________________________________□
以下填入一个代号, 这样在开机时 LILO 提示符号下, 键入该代
号, 就可以启动进入这代号所代表的作业系统。
<< 画面 5-76 >>
________________ SELECT PARTITION NAME __________________□ □ Now you must select a short, unique name for this □ □ partition. You'll use this name if you specify a □ □ partition to boot at the LILO prompt. 'Linux' might □ □ not be a bad choice. THIS MUST BE A SINGLE WORD. □ □ ______________________________________________________□□ □ □linux1 □□ □ _____________________________________________________□□ __________________________________________________________□ □ < OK > □ __________________________________________________________□
把 Linux 分割区加入开机选单後, 以下我们要回到 LILO 的主
服务画面。 底下我想把我 /dev/hda1 的 DOS 分割区也加入选单, 以
下选择 DOS。
<< 画面 5-77 >>
__________________________ LILO INSTALLATION __________________________□ □ LILO (the Linux Loader) allows you to boot Linux from your hard □ □ drive. To install, you make a new LILO configuration file by □ □ creating a new header and then adding at least one bootable □ □ partition to the file. Once you've done this, you can select the □ □ install option. Alternately, if you already have an /etc/lilo.conf, □ □ you may reinstall using that. If you make a mistake, you can always □ □ start over by choosing 'Begin'. Which option would you like? □ □ ___________________________________________________________________ □ □□ Begin Start LILO configuration with a new LILO header □□ □□ Linux Add a Linux partition to the LILO config file □□ □□ OS/2 Add an OS/2 partition to the LILO config file □□ □□ DOS Add a DOS partition to the LILO config file □□ □□ Install Install LILO □□ □□ Recycle Reinstall LILO using the existing lilo.conf □□ □□ Skip Skip LILO installation and exit this menu □□ □□ View View your current /etc/lilo.conf □□ □□ Help Read the Linux Loader HELP file □□ □ ___________________________________________________________________ □ _______________________________________________________________________
□ < OK > □ _______________________________________________________________________
以下安装程式侦测到 /dev/hda1 有 DOS分割区, 我们就回答该分
割区作为启动之用。
<< 画面 5-78 >>
________________________ SELECT DOS PARTITION _________________________
□ These are possibly DOS partitions. They will be treated □ □ as such if you install them using this menu. □ □ □ □ Device Boot Begin Start End Blocks Id System □ □ /dev/hda1 * 1 1 1000 127491+ 6 DOS 16-bit >=32M □ □ □ □ Which one would you like LILO to boot? □ □ ____________________________________________________________________□□ □□dev/hda1 □□ □ ____________________________________________________________________□□ □ □ □ □ □ □ □ □ □ □ □ □ ________________________________________________________________________□ □ < OK > □ ________________________________________________________________________□
同样的, 以下我们也给这DOS分割区取一个代码, 这里我们取名为
dos (大小写无关系)。
<< 画面 5-79 >>
________________ SELECT PARTITION NAME __________________□ □ Now you must select a short, unique name for this □ □ partition. You'll use this name if you specify a □ □ partition to boot at the LILO prompt. 'DOS' might not □ □ be a bad choice. THIS MUST BE A SINGLE WORD. □ □ ______________________________________________________□□ □责os □□ □ ______________________________________________________□□ __________________________________________________________□ □ < OK > □ __________________________________________________________□
又回到这画面, 现在我们就可以把反白移动到 Install 这一行,
真正执行 LILO Install。
<< 画面 5-80 >>
__________________________ LILO INSTALLATION __________________________□ □ LILO (the Linux Loader) allows you to boot Linux from your hard □ □ drive. To install, you make a new LILO configuration file by □ □ creating a new header and then adding at least one bootable □ □ partition to the file. Once you've done this, you can select the □ □ install option. Alternately, if you already have an /etc/lilo.conf, □ □ you may reinstall using that. If you make a mistake, you can always □ □ start over by choosing 'Begin'. Which option would you like? □ □ ___________________________________________________________________ □ □□ Begin Start LILO configuration with a new LILO header □□ □□ Linux Add a Linux partition to the LILO config file □□ □□ OS/2 Add an OS/2 partition to the LILO config file □□ □□ DOS Add a DOS partition to the LILO config file □□ □□ Install Install LILO □□ □□ Recycle Reinstall LILO using the existing lilo.conf □□ □□ Skip Skip LILO installation and exit this menu □□ □□ View View your current /etc/lilo.conf □□ □□ Help Read the Linux Loader HELP file □□ □ ___________________________________________________________________ □ _______________________________________________________________________
□ < OK > □ _______________________________________________________________________
我们接著可以在萤幕上看到下面这讯息。
<< 画面 5-81 >>
______________________________________□ □ □ □ Installing the Linux Loader... □ □ □ ______________________________________□
设定网路
紧接著设定 LILO 之後, 我们要进行网路的设定。
<< 画面 5-82 >>
__________________ CONFIGURE NETWORK? ___________________
□ Would you like to configure your network? □ □ □ __________________________________________________________□ □ < Yes > < No > □ __________________________________________________________□
下面讯息稍微阅读一下, 尤其不要忘记, 当您系统建议起来後,
随时还可以用 netconfig 命令重新设定网路。
<< 画面 5-83 >>
______________________ NETWORK CONFIGURATION _______________________
□ □ □ Now we will attempt to configure your mail and TCP/IP. This □ □ process probably won't work on all possible network □ □ configurations, but should give you a good start. You will be □ □ able to reconfigure your system at any time by typing: □ □ □ □ netconfig □ □ □ ____________________________________________________________________□ □ < OK > □ ____________________________________________________________________□
以下首先回答您这部 Linux的主机名称, 在这里, 笔者将之取名为
linux3, 注意, hostname 加上 domain name 就是您机器的完整网路
名称。 通常假如您在台湾学术网路的话, 这名称要在学校的 nameserver
注册, 至於在台湾非学术网路部份, 可以透过 service@tpts1.seed.net.tw
的服务来注册 (也就是那些 *.org.tw、 *.com.tw 及 *.gov.tw 等等),
假如是公司内部网路, 则无须登记。
<< 画面 5-84 >>
__________________________ ENTER HOSTNAME __________________________□ □ First, we'll need the name you'd like to give your host. Only □ □ the base hostname is needed right now. (not the domain) □ □ □ □ Enter hostname: □ □ ________________________________________________________________□□ □□linux3 □□ □ ________________________________________________________________□□ ____________________________________________________________________□ □ < OK > □ ____________________________________________________________________□
以下回答该机器所在网路之 domain name, 以下我回答 uuserv.net.tw。
<< 画面 5-85 >>
________________________ ENTER DOMAINNAME _________________________
□ Now, we need the domain name. Do not supply a leading '.' □ □ □ □ Enter domain name for linux3: □ □ ________________________________________________________________□□ □| uuserv.net.tw □□ □|________________________________________________________________□□ ____________________________________________________________________□ □ < OK > □ |____________________________________________________________________□
下面询问是否是单机网路, 也就是说假如该机器没配备有网路卡,
也没有透过串列通讯界面 (比方SLIP/PPP) 或 平行通讯界面 (PLIP)
连接网路, 底下就回答 Yes, 假如想上网路, 则回答 No。
<< 画面 5-86 >>
__________________________ LOOPBACK ONLY? __________________________□ □ If you only plan to use TCP/IP through loopback, then your □ □ IP address will be 127.0.0.1 and we can skip a lot of the □ □ following questions. □ □ □ □ Do you plan to ONLY use loopback? □ ____________________________________________________________________□ □ < Yes > < No > □ ____________________________________________________________________□
假如上一个画面回答 No, 您接著就会看到以下画面。 以下回答
该机器的 IP 地址, 注意, 假如这机器要连上 Internet的话, 这 IP
不可以乱定, 因为 Internet上的 IP 地址是不可以重复的。 至於是
内部网路的话, 可以任意选用以下的 IP。
10.0.0.0 ~ 10.255.255.255
172.16.0.0 ~ 172.31.255.255
192.168.0.0 ~ 192.168.255.255
注意, 假如您在台湾学术网路的话, 往下的资料, 通常您要询问
贵校的计算机中心才可获得, 否则, 找一个网路前辈问看看。
<< 画面 5-87 >>
____________________ ENTER LOCAL IP ADDRESS _____________________
□ Enter your IP address for the local machine. Example: □ □ 111.112.113.114 □ □ Enter IP address for linux3 (aaa.bbb.ccc.ddd): □ □ ______________________________________________________________□□ □□92.168.1.149 □□ □|______________________________________________________________□□ __________________________________________________________________□ □ < OK > □ |__________________________________________________________________□
假如有 Gateway的话, 填到底下。
<< 画面 5-88 >>
____________________ ENTER GATEWAY ADDRESS ____________________□ □ Enter your gateway address, such as 111.112.113.1 □ □ □ □ If you don't have a gateway on your network, you can enter □ □ your own IP address. □ □ □ □ Enter gateway address (aaa.bbb.ccc.ddd): □ □ ___________________________________________________________ □ □□92.168.1.150 □□ □ ___________________________________________________________ □ _______________________________________________________________
□ < OK > □ _______________________________________________________________
底下填入 Netmask。
<< 画面 5-89 >>
________________________ ENTER NETMASK ________________________□ □ Enter your netmask. This will generally look something □ □ like this: 255.255.255.0 □ □ Enter netmask (aaa.bbb.ccc.ddd): □ □ ___________________________________________________________ □ □□55.255.255.0 □□ □ ___________________________________________________________ □ _______________________________________________________________
□ < OK > □ _______________________________________________________________
以下询问是否有 nameserver, 内部私有网路可以回答 No, 至於
想上 Internet的机器, 则一定要有 (此处是指定一部 Name server
提供不机器的需要的 IP<-> Domain name 转换服务, 而不是说要设
立自己的一部 Name server。 对大部分人来说, 没有必要有自己的
Name server)。
<< 画面 5-90 >>
______________ USE A NAMESERVER? _______________
□ Will you be accessing a nameserver? □ ________________________________________________□ □ < Yes > < No > □ ________________________________________________□
Internet 上负责把 IP 转 Domain name (或反过来) 的服务, 就
是由 nameserver负责, 以下把距您最近的一部 nameserver的 IP 填
入。
<< 画面 5-91 >>
________________________ SELECT NAMESERVER __________________________□ □ Here is your current IP address, full hostname, and base hostname: □ □ 192.168.1.149 linux3.uuserv.net.tw linux3 □ □ □ □ Please give the IP address of the name server to use. □ □ You can add more Domain Name Servers by editing /etc/resolv.conf. □ □ □ □ Name Server for domain uuserv.net.tw (aaa.bbb.ccc.ddd): □ □ __________________________________________________________________□□ □□39.175.249.15 □□ □ __________________________________________________________________□□ ______________________________________________________________________□ □ < OK > □ ______________________________________________________________________□
<< 画面 5-92 >>
__________________ NETWORK SETUP COMPLETE ____________________□ □ □ □ Your networking software has now been configured. □ □ □ _______________________________________________________________
□ < OK > □ _______________________________________________________________
以上, 基本网路设定已经妥当。 接下来, 我们要设定电子邮件服
务系统 (sendmail), 这里的设定只适用在 Slackware Linux 2.02 以
後的版本, 之前的版本无须此道操作。
接下来进行到画面 5-93, 这里所遇到的, 是 selection 萤幕剪
贴 (只在 Console有效) 程式, 这里问说, 是否要在系统一开机时就
执行该程式, 使得随时可以有剪贴功能 (类似 DOS常驻功能)。 笔者
建议这里回答 No, 之後假如发现有用到, 随时执行该程式即可。
<< 画面 5-93 >>
________________ SELECTION 1.5 CONFIGURATION _________________
□ Selection is a program that allows you to do cut and paste □ □ on the virtual consoles using a mouse. If you choose to □ □ have it run at boot time, the line: □ □ □ □ selection -t ms & □ □ □ □ will be added to the end of your /etc/rc.d/rc.local. □ □ □ □ Running selection with a bus mouse can cause problems with □ □ XFree86 2.0. If XFree86 2.0 refuses to start and complains □ □ that it cannot open the mouse then you might want to comment □ □ the line out of /etc/rc.d/rc.local. Would you like to add □ □ □ □ selection -t ms & □ □ □ □ to /etc/rc.d/rc.local so that selection will load at boot □ □ time? □ □ □ _______________________________________________________________
□ < Yes > < No > □ _______________________________________________________________
以下主要有三个选择, 假如您的机器摆在 直接 Internet连线,
这时您可以选择 SMTP+BIND, 假如内部 TCP/IP 网路, 可以选用SMTP
, 至於想透过 UUCP通讯, 则选择 UUCP。 安装软体在自动拷贝恰当
的设定档, 并摆在 /etc/sendmail.cf。
<< 画面 5-94 >>
______________________ SENDMAIL CONFIGURATION ______________________□ □ Sendmail requires a configuration file (/etc/sendmail.cf). Three □ □ versions are provided: TCP/IP with a nameserver, TCP/IP without □ □ a nameserver, and UUCP. If none of these proves suitable, you □ □ can make your own (look in /usr/src/sendmail). It probably won't □ □ hurt to try one of these, though. □ □ ________________________________________________________________□□ □□ SMTP+BIND Connected to the net with nameserver access □□ □□ SMTP Connected to a network with no nameserver □□ □□ UUCP Use UUCP for mail transmission □□ □□ SKIP Do not install /etc/sendmail.cf □□ □ ________________________________________________________________□□ ____________________________________________________________________□ □ < OK > □ ____________________________________________________________________□
最後填入时区, 如画面 5-95 的说明。 读者若在台湾的话, 移动
往下方向键, 一直到 ROC, 之後按 键做选择。 请读者特别
留意, 是用放向键移动反白, 不是用空白键。
<< 画面 5-95 >>
______ TIMEZONE CONFIGURATION _______
□ Select one of the following □ □ timezones: □ □ __________________________________□□ □□ Australia/LHI □□ □□ Australia/NSW □□ □□ Australia/North □□ □□ Australia/Queensland □□ □□ Australia/South □□ □□ Australia/Tasmania □□ □□ Australia/Victoria □□ □□ Australia/West □□ □□ Australia/Yancowinna □□ □□ Brazil/Acre □□ □□ Brazil/DeNoronha □□ □□ Brazil/East □□ □□ Brazil/West □□ □□ Mexico/BajaSur □□ □□ Mexico/General □□ □□ MET □□ □□ □□ □□ ... (画面省略) □□ □□ ... □□ □□ □□ □□ NZ □□ □□ Navajo □□ □□ PRC □□ □□ Poland □□ □□ ROC □□ □ ____□(+)_________________________ □ ______________________________________□ □ < OK > □ ______________________________________□
<< 画面 5-96 >>
___________________ REPLACE /etc/fstab? ____________________
□ You already have an /etc/fstab on your install □ □ partition. If you were just adding software, you □ □ should probably keep your old /etc/fstab. If you've □ □ changed your partitioning scheme, you should use the □ □ new /etc/fstab. Do you want to replace your old □ □ /etc/fstab with the new one? □ __________________________________________________________
□ < Yes > < No > □ __________________________________________________________
画面 5-96应该是您执行 CONFIGURATION阶段所看到的最後一个画
面, 假如您没有看到这画面, 就表示一定哪里出问题了, 最好您能够
重新执行一遍 CONFIGURATION, 否则通常您也没有办法正常开机进入
系统。 尤其对於安装交大云观 CD-ROM III Linux Plug and Play,
想直接由 CD-ROM 跑 Linux的朋友来说, 若您没有看到画面 5-96 更
新 /etc/fstab 的动作, 您将完全无法启动机器来 Plug & Play :-)
以上终於大公告成, 恭喜您, 您就此拥有一部完整的多工多使用
者作业系统, 而且支援完整的 TCP/IP 网路功能。 这里我提一些建议
给新手朋友, 不要期望第一次就可以安装一部没有瑕疵的 Linux 系统
,照笔者经验, 很多新手们问一些奇奇怪怪的问题, 这类的问题有很多
都是起因於安装过程的错误。
最後, 回到主服务画面, 底下我们可以 离开, 之後用
reboot 指令重新开机, 且注意, 用刚刚您造出来的系统开机磁片来启
动。
<< 画面 5-97 >>
______________ Slackware Linux Setup (version FD-2.0.2) ______________□ □ Welcome to Slackware Linux Setup. □ □ Select an option below using the UP/DOWN keys and SPACE or ENTER. □ □ Alternate keys may also be used: '+', '-', and TAB. □ □ __________________________________________________________________□□ □□HELP Read the Slackware Setup HELP file □□ □□KEYMAP Remap your keyboard if you're not using a US one □□ □□QUICK Choose quick or verbose install mode [now: VERBOSE] □□ □□MAKE TAGS Experts may customize tagfiles to preselect packages □□ □□ADDSWAP Set up your swap partition(s) □□ □□TARGET Set up your target partitions □□ □□SOURCE Select source media □□ □□DISK SETS Decide which disk sets you wish to install □□ □□INSTALL Install selected disk sets □□ □□CONFIGURE Reconfigure your Linux system □□ □□EXIT Exit Slackware Linux Setup □□ □ __________________________________________________________________□□ □_____________________________________________________________________□ □ < OK > □ ______________________________________________________________________□
* 作者: 曾瑞源 著作权声明 *
* yuan@UUserv.Net.tw *
* *
* 任何个人都可未经授权自行列印阅读, 这里「个人」指任何人, *
* 「自行列印」指的是非删改作者原作情况下, 自行由电脑印表机 *
* 列印。本著作权规□不限制您列印数量, 但凡商业性出版使用、 *
* 转排版印刷都不被允许。 *
* *
* 关於本著作物(电子书)的转发行规定, 您被鼓励将之摆放在任何 *
* Internet FTP档案库上 Gopher/WWW站、或者任何联盟的PC BBS *
* 站台, 作者欢迎并感激您愿意如此做, 因为这样做受益的朋友必 *
* 然会更多。最後, 本版权声明是本著作的一部份, 任何将本声明 *
* 与本著作分离的动作已经侵权并违法。其它未定事宜, 或您认为 *
* 本版权声明有不合时宜之处, 请联络作者。我再次感谢您读我, *
* 再见。 *
* *
第五章 其他非标准安装程序解析
透过前几章的介绍, 您应该已经大致完成 Slackware Linux 的
系统安装了。 本章介绍的话题, 主要是一些与系统安装有直接或间
接关系的技术与观念, 相信这些可以帮助您进一步了解 Linux。 笔
者也再次提醒, 对於想把 Linux 摆在严肃场合的朋友来说, 若没有
把握系统安装的品质, 不妨考虑重新安装, 而透过更多的技术琢磨,
重新安装後的系统必然可以更顺畅运转。
交大『云观 CD-ROM III』直接由 CD-ROM执行之安装法
bootdisk 磁片可以当作系统急救磁片
如何自制 bootdisk
pkgtool 软体维护
手工建置档案系统
您需要虚拟记忆体吗?
手工建造 Swap Partition
手工建造 Swap File
手工设定 LILO
如何解除LILO自动开机程序
□ 交大『云观 CD-ROM III』直接由 CD-ROM执行之安装法
笔者很高兴看到交大一群朋友们的努力, 出版了一份本土的 "Plug
& Play" Linux CD-ROM, 我想, 凡是受益於这份 CD-ROM 的朋友, 应
该有必要知道, 这 CD-ROM 主要是刘大川、黄界木坚、李欣□、李建
达以及张杰生等几位先生先进们的努力所成就。
由於本 CD-ROM 也附有标准 Slackware Linux 2.1.0, 想正常安
装 Linux 系统者 (其实这才是笔者所推荐的, 本节的 Play & Play
Linux 我感觉只适合用来作为 demo 用途, 不过这算是笔者的偏见而
已), 请参考第四章的说明即可, 不过, 仍有一点须要注意的, 就是
CD-ROM 上的路径, 这部份您要回答 ″/slackware/slakware″ (注
意不要拼错字) 即可, 也就是在 setup 画面选择 "slackware/slakware
TransAmeritech CD" 选项。
这一节我们所要介绍的, 是此次交大 云观三的一个特色之一 --
Plug & Play, 这意思是说, 好像电器用品一样, 插上电源就可以玩了,
虽然, 这样说法或许有些夸张, 其真正的情况是说, 您「几乎」 不需
要额外的进行正常的安装程序, 而只需要一些些硬碟空间, 以及几步简
单的程序, 之後, 就可以直接从 CD-ROM 上跑 Linux!
底下我们就来看看如何把 Linux 插上去就可以玩 :-)
一样的, 我仍然建议读者先给 Linux 预备一个专有分割区 (
Partition) [注], 这个分割区不需要很大, 根据笔者测试, 大约只需
要 13MB 到 15MB 空间即可进行安装, 而安装後系统实际占用空间大
约为 10MB左右。
有了一个分割区, 接下来的动作当然是建置档案系统, 这就好像
DOS 的 FORMAT (格式化) 动作。 以上两个动作, 仍然是标准的作业
系统安装步骤, 以下的步骤才是特殊之处。
前面几段话已经暗示了, 我们其实没有办法把 Linux 直接在云观
III CD-ROM 上跑, 真正的情况, 是云观 III CD-ROM 设计了一个 /usr
目录, 这目录收集了高达二百六十几MB的应用软体, 这些都是可立刻
执行的, 也就是说可以把 CD-ROM 的 /cdrom/usr目录 挂在 / 档案系
统之下的 /usr。 我们反过来说, 我们之前之所以要设立一个 13MB的
分割区, 是因为 Linux 系统的 / (root) 档案系统仍然必须设立好,
且 / 档案系统下的 /bin 、 /sbin/、 /etc、 /boot、 /proc、 /tmp
等等目录架构是构成一部 Linux系统所必须有的, 这些虽然可以精简阳
春, 可是却不能没有, 更重要的原因, Linux / 档案系统有一部份是必
须可以读也可以写 (Read & Write), 而 CD-ROM 却只能唯读 (Read Only
)。
云观 III CD-ROM 所谓 Play & Play的设计, 就是把以上所提到的
这些最基本档案系统, 事先压缩成两个独立的档案, 放在该 CD-ROM 内
(/cdrom/linux/root.tgz 及 /cdrom/linux/var/tgz), 所以说, 我们
安装时, 在观念上, 就是直接把这两个档案直接解压缩在这一个 13MB
的分割区上, 该分割区就立刻拥有一个完整的档案系统架构。 这里,
我们可以容易的看出, 这样的安装法完全不同於标准 Slackware Linux
安装程序。
经过了直接的解压缩安装, 我们仍然需要非常简单的系统设定,
而这部份又与 Slackware Linux安装程序完全一样, 於是我们可以完
全引用 setup 程式来做, 不过主要只做 setup 里面的 SOURCE 与
CONFIGURATION两道步骤。 当这到步骤也完成之後, 我们重新开机,
这时, 我们可以看到系统一启动过程中, CD-ROM 灯号就立刻亮起来,
而且断断续续, 这是因为系统决大部分的东西都放在该 CD-ROM 内,
系统必须依靠 CD-ROM 才可以完整启动机器, 更重要的, 我们所需
要的所有应用软体, 也都摆在该 CD-ROM内。
希望以上罗哩罗唆的说明, 有助於观念上的补充, 以下, 我们就
来看看实际上的操作细节。
步骤零, 分割区规划:
首先您要根据第四章的说明, 规划出至少 13MB 的硬碟空间, 再
次提醒您, 您必须在 Linux 环境下用 fdisk 来执行规划, 更具体的
说, 是用 bootdisk及rootdisk两张磁片开机後 (有关bootdisk 及
rootdisk 的选择与制作, 请参考第三章), 执行 fdisk。
步骤一, 建置作档案档案系统:
假如想依照 Slackware Linux的标准程序来做的话, 可以参考第
四章的说明, 假如想迅速的手工操作的话, 可以参考第五章「手工建
置档案系统」乙节的说明。
以上两个步骤都可以用 Slackware Linux的 setup 标准安装程序
来完成。
接下来的步骤才是本节的精华, 以下我们要做一些假设, 我们假
设所要安装的分割区为 /dev/hda2, 使用之 CD-ROM 为 Panasonic
562B/563B, 读者引用时, 记得依照您的实际情况做修改。
步骤二. 安装前预备
以下步骤类似於 Slackware Linux setup 过程中, 所指令的 Target
与 Source等程序。
往下的步骤, 您也同样选用恰当的 bootdisk 及 rootdisk 磁片
来启动机器, 之後以 root 帐号进入系统, 接下来执行以下操作。
$ mount -t ext2 /dev/hda2 /mnt -o rw
这步骤与 Slackware Linux setup 程序的 Target 设定同样意思。
$ mount -t iso9660 /dev/sbpcd /var/adm/mount -o ro
这步骤与 Slackware Linux setup 程序的 Source 设定同样意思。 请
读者特别留意, 假如您使用 Mitsumi 唯独光碟机, 把 /dev/sbpcd
换成 /dev/mcd, 是 Sony CDU-31A 的话换成 /dev/sonycd, 是 Sony
CDU-535 的话换成 /dev/cdu535, 是 LMS/Philips 则换成 /dev/lmscd
, 其他 SCSI 唯读光碟机则换成 /dev/scd0。
步骤三. Linux Plug & Play 安装:
$ cd /cdrom/linux
$ install
正常的话, 您会在萤幕上看到一连串档案拷贝的过程, 这步骤可
能维持一两分钟。
步骤四. 系统设定
这步骤您也可以引用 Slackware Linux 的 setup 标准安装程序
来完成, 不过大约有两点要留意, 在 setup 程序中, 只执行 SOURCE
以及 CONFIGURATION两到程序即可, TARGET 不执行是因为刚刚步骤
二时已经完成, SOURCE之所以要重复做一次 (注意, 步骤二也同样已
经做了), 我发现是因为 setup 会 umount 已经挂好的光碟机。
$ setup
这个指令就是您此刻唯一需要做的, 请参考第四章的说明, 细心
的完成 CONFIGURATION 的操作, 之後用 CONFIGURATION过程中所制
作的开机片重新启动机器。 正常的话, 您就可以使用这 Plug & Play
Linux。
注. Linux 也可以在 UMSDOS模式下, 直接在 DOS Partition下执行,
但笔者不推荐这样做, 尤其想把 Linux摆在有生产力应用所在者, 不
要试。
□ bootdisk 磁片可以当作系统急救磁片
这一章中, 我们首先来看看 bootdisk 作为救急磁片的用途。
Slackware Linux 的 bootdisk 的第一个救急用途, 就是用来
启动硬碟内的 Linux 系统, 什麽时候需要用到呢? 比方说您原本
从硬碟开机突然失效了, 更不巧您也没有做软碟开机片, 这些情况
您就可以使用 bootdisk 开机 (没有用到 rootdisk 磁片), 之後
在提示符号下使用 mount root=/dev/hda1 指令, 详细情况如下面
萤幕所示。