📄 ch03.htm
字号:
<DL>
<DD>
<HR>
<A NAME="Heading10<FONT COLOR="#000077"><B>CAUTION:</B> </FONT>Your boot sequence
in the CMOS on your PC must be A: first, then C:. Otherwise, you will not be able
to boot up from floppy disks.
<HR>
</DL>
<P>After you are in a directory, select the boot disk that best describes your system
from the list presented in the VIEW.EXE program. The files whose names end in <TT>.i</TT>
are boot disks for IDE systems, and those whose names end in <TT>.s</TT> are boot
disks for SCSI systems. Select the boot disk that best describes your CD-ROM and
other related hardware. Be sure to select the boot disk that contains the CD-ROM
drive on your machine even if the correct Ethernet or other device is not supported
in it. You can always rebuild the kernel later. For the moment, just ensure that
your Slackware CD-ROM is readable by the kernel that you will be booting.</P>
<P>When you have made your selection, the VIEW.EXE program asks you to insert a floppy
disk in drive A. Label this floppy as the boot floppy, insert this floppy in drive
A, and press Enter. Be patient; the file transfer takes a few minutes.</P>
<P>After the boot image has been written to disk, the VIEW.EXE program asks you to
create a root disk.</P>
<P>A root image is a binary representation of a small root file system that also
happens to reside on a floppy, just like the boot image. You need the root file system
to start the installation process for Slackware.</P>
<P>The 1.2MB installation disks have the <TT>12</TT> string in their names rather
than <TT>144</TT>. For example, the tty image for the 1.2MB floppy disks is called
<TT>tty12</TT>. Table 3.1 lists the root images for the 1.44MB floppies. <BR>
<CENTER>
<P><FONT SIZE="4"><B>Table 3.1. Root images for 1.44MB drives. </B></FONT>
<TABLE BORDER="0">
<TR ALIGN="LEFT" rowspan="1">
<TD ALIGN="LEFT"><I>Filename </I></TD>
<TD ALIGN="LEFT"><I>Description </I></TD>
</TR>
<TR ALIGN="LEFT" rowspan="1">
<TD ALIGN="LEFT"><TT>COLOR.GZ</TT> </TD>
<TD ALIGN="LEFT">A root install disk that uses the new full-screen color-install program. Be patient
as you use this installation. </TD>
</TR>
<TR ALIGN="LEFT" rowspan="1">
<TD ALIGN="LEFT"><TT>TEXT.GZ</TT> </TD>
<TD ALIGN="LEFT">A root install disk for text-based installations. No fancy graphics, just a dumb
terminal version of the install program. </TD>
</TR>
<TR ALIGN="LEFT" rowspan="1">
<TD ALIGN="LEFT"><TT>UMSDOS.GZ</TT> </TD>
<TD ALIGN="LEFT">A version of <TT>color.gz</TT> used to install UMSDOS, a file system that enables
you to install Linux into a directory on an existing MS-DOS partition. Not as fast
as <TT>ext2</TT>, but you don't have to repartition your drive either. </TD>
</TR>
<TR ALIGN="LEFT" rowspan="1">
<TD ALIGN="LEFT"><TT>RESCUE</TT> </TD>
<TD ALIGN="LEFT">Utilities to attempt to recover from an incomplete installation. </TD>
</TR>
<TR ALIGN="LEFT" rowspan="1">
<TD ALIGN="LEFT"><TT>TAPE</TT> </TD>
<TD ALIGN="LEFT">An experimental disk for installation from tape. </TD>
</TR>
<TR ALIGN="LEFT" rowspan="1">
<TD ALIGN="LEFT"><TT>PCMCIA</TT> </TD>
<TD ALIGN="LEFT">For laptop installation with PCMCIA cards from an NFS mounted drive. </TD>
</TR>
</TABLE>
<BR>
</CENTER>
<P>The <TT>COLOR.GZ</TT> version of the install system is the preferred disk in almost
all cases. Use the <TT>COLOR.GZ</TT> image if you can. It does have some known "features"
though:
<UL>
<LI>You will see the <TT>cancel</TT> selection for certain options. This selection
cancels only the current package you are installing, not the entire installation
process.
<P>
<LI>This version looks pretty with its colored boxes and other features. but it's
not particularly forgiving of extra keystrokes entered between screens. If you are
not patient, use the <TT>text</TT> version.
</UL>
<DL>
<DT></DT>
</DL>
<DL>
<DD>
<HR>
<A NAME="Heading11<FONT COLOR="#000077"><B>TIP:</B> </FONT>The floppies must
have no bad blocks on them. Be sure you're using brand-new, preformatted, error-free
floppies.
<HR>
</DL>
<CENTER>
<H3><A NAME="Heading12<FONT COLOR="#000077">Making the Root and Boot Disks
Without VIEW.EXE</FONT></H3>
</CENTER>
<P>You can make the root and boot disks without the VIEW.EXE program. This is the
way to make floppies using the CD-ROM at the back of this book. The boot images that
are available for 1.44MB floppies on the CD-ROM included with this book can be found
in the <TT>bootdsks.144</TT> directory. For 1.2MB (5[dieresis]-inch) floppy disks,
comparable boot images exist in the <TT>bootdsks.12</TT> directory. Several boot
images are provided in this directory because of the diversity of various Linux device
drivers. You have to choose which one best fits your system from those files in the
installation directories. Check the <TT>bootdsks.144</TT> or <TT>bootdsks.12</TT>
directories for the listed entries in the <TT>WHICH.ONE</TT> file.</P>
<P>Look in the <TT>INSTALL</TT> directory of the CD-ROM. You will see two programs
there. Make sure that the <TT>PATH</TT> environment variable is set to include these
programs:
<UL>
<LI>GZIP.EXE is an MS-DOS executable of the gzip compression program used to compress
the boot and root disk files. (The <TT>.gz </TT>extension on the filenames indicates
that this GZIP.EXE program was used for compression.)
<P>
<LI>RAWRITE.EXE is an MS-DOS program that writes the contents of a file (such as
the boot and root disk images) directly to a floppy, without regard to format. You
will use RAWRITE.EXE to create the boot and root floppies.
</UL>
<P>Use the RAWRITE.EXE program to write the boot and root disk images to the floppies.
For example, if you're using the <TT>color144.gz</TT> boot disk, issue these commands:<FONT
COLOR="#0066FF"></FONT>
<PRE><FONT COLOR="#0066FF">D:\> cd install
D:\INSTALL> rawrite
RaWrite 1.3 - Write disk file to raw floppy diskette
Enter source file name: d:\bootdsks.144\scsi
Enter destination drive: a
Please insert a formatted diskette into drive A: and press -Enter- : <Enter>
Writing image to drive A: Press ^C to abort.
Track: 33 Head: 0 Sector: 10
Done.
</FONT></PRE>
<P>Answer the prompts for the name of the file to read (such as <TT>BARE</TT>) and
the drive (such as A) to which to write it. RAWRITE copies the file, block-by-block,
directly to the floppy.</P>
<P>Use RAWRITE for the root disk image (such as <TT>COLOR</TT>) for the next floppy.
Here's a sample run:<FONT COLOR="#0066FF"></FONT>
<PRE><FONT COLOR="#0066FF">D:\> cd rootdsks.144
D:\ROOTDSKS> copy color.gz c:\
1 file(s) copied
D:\ROOTDSKS> c:
C:\> d:\install\gzip -d color.gz
C:\> d:\install\rawrite
Enter source file name: color
Enter destination drive: a
Please insert a formatted diskette into drive A: and press -Enter- : <Enter>
Writing image to drive A: Press ^C to abort.
Track: 79 Head: 1 Sector: 16
</FONT></PRE>
<CENTER>
<H3><A NAME="Heading13<FONT COLOR="#000077">Creating Boot and Root Floppies
on a UNIX System</FONT></H3>
</CENTER>
<P>You don't need to use GZIP.EXE and RAWRITE.EXE under UNIX to create the boot and
root floppies. You can use the <TT>gzip</TT> and <TT>dd</TT> commands on a UNIX system
instead. For this, you need a UNIX workstation with a floppy drive. For example,
on a UNIX workstation with a 1.44MB floppy drive on device /dev/fd0H1440, you can
use the following command:<FONT COLOR="#0066FF"></FONT>
<PRE><FONT COLOR="#0066FF">% dd if=bare of=/dev/fd0H1440 obs=18k
</FONT></PRE>
<P>The <TT>dd</TT> command writes the file bare to the floppy disk. The <TT>obs</TT>
parameter is required to specify the output block size argument.
<CENTER>
<H3><A NAME="Heading14<FONT COLOR="#000077">Preparing the Hard Disk</FONT></H3>
</CENTER>
<P>Depending on the type of root system you selected, you must either use an existing
MS-DOS partition (for UMSDOS root) or create partitions for Linux. If you are using
UMSDOS, skip to the next section. For other Linux installations, you need to create
at least two partitions: one for swap space (used as virtual memory) and another
for your "root file system" (that is, the actual Linux operating system
software and your files). The root file system and your data don't have to reside
in one partition. You can make additional partitions for your own data and user files.
For example, instead of having just one partition contain both the Linux operating
system and data, you can have two separate partitions, one for user files and data,
and the other for the Linux operating system. (This will give you a total of three
partitions if you count the swap space.) It's best to start with one partition that
will contain both the data and the operating system for the moment because this is
a simple procedure.</P>
<P>If you are an experienced UNIX user, you might want to keep the <TT>/home</TT>
directory tree on a separate disk or partition. The <TT>/home</TT> directory is where
users' data is kept in Linux. By keeping <TT>/home</TT> on a separate partition,
you can even reformat your partitions used for Linux (during a major update, for
example) and not affect your working directories. The only caveat is that you have
to remember to have Linux mount the <TT>/home</TT> partition when it boots.</P>
<P>Before you partition your hard drive, check to see whether you have any space
on it that's not already partitioned. Chances are that you have used it up already.
Run the MS-DOS FDISK program to delete the partition and re-create a smaller partition.
Of course, in so doing, you will lose everything on that DOS partition that you just
sliced up. Back up the files first and reinstall them after you've re-created and
reformatted the partition. For example, if you have a 800MB drive used entirely for
DOS, you might want to slice it into two 400MB portions: one for Linux and one for
DOS.
<DL>
<DT></DT>
</DL>
<DL>
<DD>
<HR>
<A NAME="Heading15<FONT COLOR="#000077"><B>CAUTION:</B> </FONT>When you delete
a partition, you will lose all the data on that partition. So be careful how you
resize your partitions. Always make a backup of your directory tree before modifying
the hard disk partition table.
<HR>
</DL>
<P>For dual boot systems that also use the hard drive to boot MS-DOS, you must allocate
the first partition of your hard drive for MS-DOS. This step is necessary if you
do not decide to use the Linux Loader (LILO) boot loader for your hard drive. LILO
is a configurable Linux utility you can use to specify which partition to use in
booting a machine. More details of LILO are covered in Chapter 4, "Booting Linux."
<CENTER>
<H4><A NAME="Heading16<FONT COLOR="#000077">Setting Aside Space for a Swap
Partition</FONT></H4>
</CENTER>
<P>A swap partition is used as virtual memory for Linux. If you have 8MB of memory
on your machine and use a 16MB swap partition, programs in Linux will be able to
utilize 24MB of virtual memory. The extra memory is slow because it's off a hard
drive. Programs that chew up a lot of memory, however, are able to run, even if slowly,
on a Linux system with less than ideal real memory.</P>
<P>I strongly suggest that you use a swap partition even if you have more than 16MB
of RAM. If you have 4MB of RAM or less, a swap partition is required to install the
software.</P>
<P>The size of your swap partition depends on how much virtual memory you need. It's
often suggested that you have at least 16MB of virtual memory total. Therefore, if
you have 8MB of physical RAM, you might want to create at least an 8MB swap partition
(or 16MB if you follow the "twice as much RAM" rule of thumb). The maximum
size for a swap partition was 128MB at the time of writing this book.
<CENTER>
<H4><A NAME="Heading17<FONT COLOR="#000077">Resizing MS-DOS Partitions</FONT></H4>
</CENTER>
<P>The MS-DOS version of FDISK is more reliable than the Linux fdisk if you want
to access DOS partitions on your machine. You should take the steps to resize MS-DOS
partitions with MS-DOS FDISK:
<DL>
<DD><B>1. </B>Make a full backup of any current software.<BR>
<B><BR>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -