David Bandel rewrote and revised the first section on installing Linux. Parts of the work by the following authors of the different sections on Linux distributions were also added to this first section.
Boris Beletsky wrote the Debian section. Sean Dreilinger wrote the section on Slackware. Henry Pierce wrote the section on Red Hat Linux. Evan Leibovitch wrote the section on Caldera OpenLinux. Larry Ayers wrote the section on S.u.S.E. Linux.
Unlike most other operating systems, Linux can be obtained free of charge. Due to the GNU General Public License under which Linux is distributed (see Appendix C), no one can sell you a license for the software. You can use Linux at no charge and are encouraged to make it available to others.
But that doesn't mean companies aren't entitled to reimbursement for copying costs plus a profit. They may also add software that is not free that runs on the system.
This gives you the freedom to choose. If purchasing a CD-ROM is not within your budget, you may simply borrow a friend's copy or download the source from the Internet. Whether purchased from a major Linux distributor or downloaded from their FTP site (see Appendix B), you get the same operating system and the software packages that they offer. In fact, you can get more free software from one of the FTP sites than the companies can distribute on CD, due to restrictions some authors place on the distribution of their software.
Each distribution has its own installation and maintenance utilities that ease installation and system administration. Each is apparently aimed at a different audience. Any distribution will get you started and keep you running. So I recommend that you read about each distribution and talk to any knowledgeable friends. Most large cities have a Linux User Group, most with experienced users, who argue at length over which distribution is the best, and why. I suggest that you listen to some of their arguments and then decide. You can also join mailing lists (I recommend joining only one at a time) and reading user posts and answers from the list gurus. As different as each distribution is, so too are the mailing lists that provide assistance. Making the right choice for yourself is important, because changing distributions generally means reinstalling from scratch.
Before we begin, we must know where we are going. While it is certainly possible to get from New York to California (eventually) by striking out in almost any random direction, most of us would opt to go in a more or less direct route. So it is with installing Linux.
First, determine what kind of hardware you have. A checklist has been included to assist you. Be as precise as possible, but don't get carried away. For example, if you have an Ethernet card, you need to know what kind (e.g., SMC-Ultra, 3Com 3C509, etc.), base I/O (e.g., io=0x300), interrupt (IRQ 10), but not the hardware address (00 00 a6 27 bf 3c). Not all information will be needed for your hardware. If you have Windows 95 or Windows NT running, you can copy the values from the system hardware device information screen. Otherwise, consult the hardware manuals or the hardware company's Web site. Since it is important, we'll review this worksheet here.
GeneralProcessor: Type: 386 486 Pentium PPro
Speed (optional):
Mfg:
Intel AMD Cyrix
Motherboard: Make: Chip Set:
Example: Make: unknown Chip Set: triton II
Mouse: Mfg: Type: bus PS/2 serial port
If serial: COM1 (ttyS0) COM2 (ttyS1)
Hard disk drive(s): Type: IDE/MFM/RLL/ESDI SCSI
Size (list each drive):
If SCSI Controller: Make: Model:
Example: Make: BusLogic Model: 948
Boot: Linux DOS/Windows OS/2 Other
Disk: Partition: Size: Boot:
Disk: Partition: Size: Boot:
Disk: Partition: Size: Boot:
Disk: Partition: Size: Boot:
CD-ROM: IDE/ATAPI SCSI Proprietary
Mfg: Model:
(Proprietary only):
X-Windows:
Video Card: Mfg: Model:
RAM: 1Mb 2Mb 4Mb 8Mb 16Mb
Monitor: Mfg: Model: Max scan rate:
Networking:
Modem: Mfg: Model:
Serial port: COM1 COM2 COM3 COM4
(ttyS0) (ttyS1) (ttyS2) (ttyS3)
Computer hostname: Example: rainier
The following answers are only needed if using network interface card
(NIC): (do not configure networking if you do not have a NIC installed)
NIC Type: ethernet token ring FDDI other
NIC Mfg: Model:
Network domain name: (Example: mountains.net)
IP Address: (Ex: 192.168.1.2)
Network address: (Ex: 192.168.1.0)
Netmask: (Ex: 255.255.255.0)
Broadcast address: (Ex: 192.168.1.255)
Gateway(s): (Ex: none or 192.168.1.1)
DNS(s): (Ex: 192.168.1.2)
Some of the General Section is there for future reference. Specifically, we don't need to know right now our CPU processor type. We can also do without ever knowing what chip set we have on the motherboard. But if the information is available, it is good to have.
Read the print on the bottom of the mouse carefully before deciding. Also, if you have a mouse with three buttons, but it has a switch on the bottom which you can change between, say, Microsoft and PC systems, choose PC system. The Microsoft setting doesn't implement the middle button, which is useful in UNIX. For manufacturer, choose the switch setting, since that is the signaling protocol used. No drivers exist for a "Cutie" mouse, but do exist for the switch settings of Microsoft and Mouse System found on the bottom of the mouse.
While not specifically asked for, the only additional information you may want to add is the device through which the system accesses the mouse. Linux must know how the device is referred to. If you have a PS/2 mouse, you will normally use either /dev/psaux, the auxiliary port for a PS/2 pointing device, or /dev/psmouse, a synonym sometimes available for use. Bus mice are accessed through a file specifically created for that proprietary mouse, like /dev/atibm ATI bus mice, /dev/logibm for Logitech bus mice, /dev/inportbm for InPort bus mice, or their respective synonyms of atimouse, logimouse, and so on. For serial mice, if you know the MS-DOS COM: port, substitute /dev/ttyS0 for COM1: and /dev/ttyS1 for COM2:. I'll refrain from explaining the origins of the tty name of ttyS0 since that will take up several paragraphs and is already explained in many UNIX references
Your hard drive will be one of several kinds. For our purposes, IDE, MFM, RLL, and ESDI are equivalent, and I will use the term IDE. This also encompasses EIDE, the most common interface currently in home computer systems on the market and favored for its low price.
If the hard drive has a SCSI interface, this will be evident during booting. You will need to know the make and model of the SCSI controller. The most common are the Adaptec and BusLogic controllers, but by no means are they the only ones. These also have specific models, like the AHA-1572 or BTC-958. This information is often displayed during system initialization.
To allocate space, we need to assess the hard drive size. Under OS/2, you can use the entire hard disk for OS/2, then install Microsoft Windows on the partition with OS/2 and run Microsoft Windows under OS/2. If you have MS-DOS and Microsoft Windows, or OS/2 on your computer, Linux should have its own partition. It can be loaded on a MS-DOS partition with UMSDOS, which is not covered here. While Linux has DOS emulators and can read and even run some DOS programs, DOS cannot usually ``see'' what is on a Linux partition.
If you have and want to keep MS-DOS (assumed), you must determine how much space to reserve for it. Subtract this number from the hard disk total and that is what you have to work with. For now, annotate the total size of the drive(s) you have and the second number with how much to dedicate to Linux.
For your CD-ROM drive(s) you need similar information. A CD-ROM drive is either IDE/ATAPI, the most common in home systems marketed today; SCSI; or an older, proprietary drive, like those connected to sound cards. If you have an IDE or SCSI drive, so much the better. If you have a proprietary drive, you must know the make and model because Linux identifies proprietary CD-ROM drives by manufacturer and the specific drive.
Under Linux, as under any UNIX, devices are special files. Hard drives are treated as files and are referred to by name, as are modems, your monitor screen, and other hardware devices. UNIX treats them as files to be read from and written to. Since Linux sees them as files, they will all be located in a directory dedicated to devices. After installation you will be able to see them under the directory /dev, for devices.
Even though these devices are seen by Linux as files, they are special. They come in two ``flavors,'' block and character, which refer to the way the device communicates, in blocks of data or individual characters. They are created automatically during installation.
These naming conventions are discussed on page .
You must know the manufacturer and specific model of your video card. Some cards can be probed for RAM or chip sets, others can't. In either case, knowing how much RAM is on the card and the chips used, like the S3 or S3-Virge, is important. This information saves much time and grief. The most difficult and frustrating part of any Linux installation and setup is the X Window System.
The data for your monitor is often more difficult to obtain. If you have one of the more obscure brands of monitors, you may need to supply vertical and horizontal scan rates yourself.
If in doubt, always err on the conservative side. Overdriving your system can result in damage to the monitor or video card.
We already have most of the information that we need for the mouse, the only other subsystem the X server needs. The information that Linux needs to know about your mouse is described on page .
During initial Linux installation, if you do not have a NIC, you can skip over some of the networking part. However, all computers must have a name under Linux. The example on the worksheet assumes you've chosen a theme, like mountains, and will name your computers after names of mountains, but any scheme your concoct is fine.
If you have a modem, you must know where it is connected. This is a serial port, /dev/ttyS0 through /dev/ttyS3, corresponding to MS-DOS COM: ports 1-4. ISDN is treated similarly, but is normally set up post-installation with special, multiple device designations.
That finishes our worksheet and about half of the planning that we need to do. One notation that is not on our worksheet is the amount of random access memory (RAM) the system has. Linux runs happily on a system with less than 4 MB of RAM, but this has a significant impact on installation and subsequent system usage. If you have 4 MB of RAM or less, then you must follow special procedures for low memory machines where applicable. With the current low price of RAM and with few machines being sold today with less than 16MB of RAM, this generally isn't an issue. If it is, be sure to check your distribution for special instructions.
Another reason is that any bootable partition must be within the first 1024 cylinders of the hard drive. When any PC boots up, a sequence of events occurs which ends in the loading of the operating system. Due to limitations in the BIOS (Basic Input/Output System), until the operating system is loaded, only the first 1024 cylinders of the first or second hard disk can be accessed.
To get a feel for exactly what we're talking about, I'm going to describe a standard Linux file system and how Linux handles partitions.
Under MS-DOS, every partition is a different drive, and little distinction is made between whether that is a physical drive or a logical drive (partition). Under Linux, physical and logical drives are much less rigidly designated.
During installation, you must choose a partition as your root partition. The root partition is designated as ``/''. When we refer to ``/dev'', this is really two directories, ``/'' and ``dev''. Your Linux kernel will be located on the root partition, but can be in a subdirectory as long as that subdirectory resides on the root partition. For example, some distributions use /boot to hold the kernel, system map, and boot up files.
The following structure (as a minimum) will be set up on your root partition
during install:
You may see others like /boot, /mnt, /cdrom,
/floppy, /opt, and so on, but the above are essential.
What about other partitions? Linux can use a directory name (say /usr) as a mount point. That is, the other partition on the disk (or on another disk) is mounted under it (in this case /usr).
If you unmount the other partition and look in the subdirectory Linux uses as a mount point, you will (or should) see nothing--no files or directories. When the other partition is mounted, you will see files and directories which are on that partition under the mount point. So if you have two drives, one with 120 MB and another with 840 MB, you can make one partition on the 120MB drive (let's say it's the root partition) and mount any partitions you have created on the 840MB drive (this could be one big partition, or several smaller partitions) under their respective mount points, one partition per mount point, creating, in effect, one, 960-MB file system.
The one restriction is that you cannot use certain directories on the root drive as mount points, because they contain files that are needed to either boot the system or mount other systems. Obviously if the command used to mount other partitions is located on another partition and you can't access that partition until you've mounted it, you'll be like the dog chasing its tail.
The directories you cannot use as mount points are: /bin, /dev, /etc, /lib, /lost+found, /proc, /root, and /sbin.
A detailed description of what files are contained in these standard system directories is given on page .
Let's look at a small example. You are an aspiring Internet Service
Provider (ISP). You have four machines, and each has a 1-gigabyte drive.
So, you decide to allocate space as follows:
You probably noticed that I arbitrarily assigned the root partition
120MB, and allocated the rest to whatever ( /usr, /home,
/var/spool/mail and so forth). I also didn't allocate any space
to a swap partition. So, let's look at what we will likely need, understanding
that ``it depends,'' is key. I will discuss this from the perspective of
a home situation with only a few users, lots of programs, and no other
remarkable needs.
The best place to start is to tell you what my primary home computer
looks like. I have two drives, /dev/hda (1.2 GB) and /dev/hdb
(540 MB). df (disk free) displays
You can see that I have a half-used 150-MB root (/) partition,
a nearly full /usr partition, a largely used /usr/X11R6
partition, and a large, but cramped, 500-MB /home partition. The remainder
of the drive /dev/hdb is a swap partition.
At a realistic minimum, I would suggest reserving 80-100 MB for your root partition, about 10 MB per user on your /home partition, as much space as you can reserve for swap, within reason (see the next section), and the rest to /usr. I have a five-user system at home, but I personally have over 400 MB of the /home directory tied up, much of that in graphics--a photo album of family and friends. Your /usr partition should probably be at least 250 MB, but the minimum will depend on what you decide to install. As you can see, it can rapidly fill with over 800 MB of programs, libraries, and data. Also remember that partitions give you flexibility that you lose with one, giant partition.
One last consideration before you decide to how best to carve up the disk. Remember that I said the BIOS cannot ``see'' past sector 1023 on the hard drive (about 512MB). So, the Linux kernel (a file probably called vmlinuz on your boot disk), or any OS kernel for that matter, must reside entirely on one of the first two disk drives ( /dev/hda or /dev/hdb) and within the first 1024 sectors, or the BIOS will be unable to load it. To insure that it can, plan to make your root partition (as well as any other boot partition) fall entirely within this limitation on either the first or second hard drive.
One way or another, then, we will have two operating systems on this computer. If you currently have nothing on your disk (lucky you), that is great, but you're not quite ready to skip ahead. Linux is comfortable wherever you put it. Your BIOS may not be capable of booting it, but once running, it will not complain if it's relegated to the fourth partition of the fourth hard drive. But MS-DOS and Microsoft Windows aren't so forgiving. They want the first drive and the first partition and may refuse to boot from any other position. I have seen MS-DOS boot from the first partition on the second hard drive, but the first hard drive did not have any MS-DOS partitions, so MS-DOS didn't recognize the drive. The best strategy is often the path of least resistance. If at all possible, put MS-DOS on the first drive and the first partition.
A second consideration in a multiple OS situation is which operating system to load first. If you're tempted to partition the hard disk and install Linux first (reserving /dev/hda1 for MS-DOS, then installing MS-DOS second, don't. Windows 95 is the worst offender, but Microsoft products in general will delete any previous boot loader you had installed on the master boot record (what the BIOS uses to point to bootable kernels). In fact, you may even hear this referred to as the ``Microsoft virus''. This is not a virus in the true sense of the word, just arrogance on the part of Microsoft, that one would only want a Microsoft operating system to boot. Linux does not cause such problems, and in fact provides a way to choose the default boot image. It also allows you to intervene during the boot process to specify which operating system to boot. This is a standard part of Linux installation procedures.
The first thing that you should do is perform a complete backup. The tools that you will use work as they should. But these procedures are inherently dangerous. Any time you work with a hard disk partition table, you can easily lose all the data contained on the drive. Back up your hard disk before you proceed.
Once you have your disk backed up, create a boot floppy disk for the
system. You can either use the MS-DOS command
which formats the floppy and puts the required system files on it,
or, using a formatted disk, issue the command
Once you have created a boot floppy and tested it to insure that it works, copy the following files from your MS-DOS system to the boot floppy: FDISK.EXE, SCANDISK.EXE, and SYS.COM. Also copy the file RESTORRB.EXE from a Linux distribution CD or Linux FTP archive. (See Appendix B).
Run a defragmentation program on your DOS drive to defragment and group the files together at the front of the disk. If defragmeter encounters any errors, you need to run SCANDISK.EXE to fix the problems. Once you have defragmented the disk and ensured that the files are compressed toward the front of the drive (as indicated in the graphical portrayal of your disk), you're ready to run FIPS.EXE to shrink the MS-DOS partition.
At the A:> prompt, type FIPS (upper or lower case). You will be greeted and asked which drive you want to operate on (if you have more than one). Select the drive to shrink. Once you confirm your choice, let FIPS.EXE make a copy of your boot and root sectors to the floppy in case something untoward happens.
You will then be asked if all of the free space on your partition should be used to create a second partition. If you say, ``yes,'' you will not have any free space on the MS-DOS partition to save data to, so say, ``no.'' You will then be able to alter the amount of space allocated between the first and second partitions. Note that if you didn't properly defragment your drive, you won't have much to work with on the second partition. Also, if you use MS-DOS mirroring software, a file is created at the very end of the partition, and FIPS.EXE tells you that you have no space to create a second partition. Exit and correct the problem by deleting the MIRROR.FIL file, then restart FIPS.EXE.
You can edit and re-edit the table until you are satisfied. Once you are happy with the distribution of space between the partitions, confirm your changes and write out the table.
Once FIPS.EXE has finished, remove the boot floppy and reboot your computer. In this example, we'll destroy and recreate the second partition during installation to create at least two partitions for Linux: a swap partition and a Linux native partition. But you can create as many as you like.
Each distribution CD contains a MS-DOS program that allows you to write a raw disk image to a formatted floppy disk. You must have a high density floppy, and some distributions require this to be a 3.5-inch, 1.44 Mb floppy. Insert the floppy in the drive. On the CD (or on your disk drive if you downloaded it) find RAWRITE2.EXE (you may have the older RAWRITE.EXE).
Then cd to the directory that has the disk image(s) that you
need to boot with. There may be only one, or many which are configured
for different hardware. You will have to consult the distribution documentation.
Running RAWRITE2.EXE with no arguments results in your having
to answer two questions: the path name of the disk image file to write.
and the destination disk drive, either A: or B:. To shortcut
the prompts with RAWRITE.EXE or RAWRITE2.EXE, issue the
arguments on the MS-DOS command line
Repeat this step for any additional disk images your system needs.
If you can check the floppy disks with SCANDISK.EXE and do a surface scan before writing the images to the floppy, you may save yourself some time later. Most initial install failures come from boot disks that are bad, and RAWRITE2.EXE doesn't verify the disks.
This is also true if you create boot disks under Linux. The badblocks(1) manual page describes how to check disks for errors.
Label the disks that you create for future use.
An alternate method that works, though will often be shunned by ``real''
Linux administrators, is the cp (copy) command
Again, substitute the disk image file name for diskimage, the
correct boot floppy device, and repeat the step for each disk that
you need. You may receive a message asking if you want to replace the boot
floppy device with diskimage. Obviously this won't happen, since
the floppy diskette is not a true file but a device, but cp doesn't
pay attention to that detail. Just say, ``yes,'' if you are asked.
With the Linux installation boot disks in hand, you're ready to install our system. Most distributions invoke fdisk, the Linux version, so you can create a native Linux partition and a swap partition. The install programs continue by creating the file system (the equivalent of formatting a MS-DOS disk) for both the Linux and swap partitions, and initialize the swap partition and mount the Linux partition.
One question that you will be asked is whether you want to check your hard disk for bad blocks. If you are using a SCSI drive, answer ``no.'' SCSI drives have built-in error checking and correcting. IDE and similar drives don't have this and need to map out bad blocks. If you have an older drive you want to do this. If you say, ``yes,'' the installation program will invoke the badblocks program to maps out all of the bad blocks it finds. This takes time. If in doubt, say, ``yes.''
Under Linux, two disk partitioning programs are available: the original fdisk, and a friendlier cfisk. The difference between the two is that in fdisk you issue all commands via the keyboard with letters and numbers. With cfdisk, you use the arrow keys to highlight the options you want, and press Enter to execute the command. The only time you use anything but the arrow and Enter keys is when you specify a number for the size of the partition.
For starters, all Linux boot disks are created essentially equal. Reboot
the computer with the boot floppy in the boot drive. You will be greeted
with a screen with some instructions and a prompt
and a flashing cursor. If you use the Tab key, you should see a list
of names. The names differ depending on the distribution, but look for
one that says ``rescue'' or ``expert.'' The ``install'' label starts the
installation program after loading the kernel, so if you want to let the
installation program walk you through the partitioning and filesystem initialization
process, you can use the ``install'' label; otherwise, choose a different
label. You may also need to provide Linux some boot parameters. For our
purposes, this should not be necessary, but you'll soon find out if this
is the case.
Enter a label name and press /keyReturn. When the Linux kernel finishes the bootup process, you may be presented with any of a number of prompts, depending on the distribution. If you have a shell prompt, like the pound sign (#) or a dollar sign ($), you're where you need to be. If not, try presssing Alt-F2 or Alt-Shift-F2. You should be able to activate one of the system's virtual consoles.
Once you have a prompt (you should not need to log in), you will be
working as ``root'' (more on this in Chapter 4).
Enter the command
If an error is returned, try cfdisk. This is the disk partition
utility. It defaults to /dev/hda, so if you need to work on the
second hard drive, use the command
In fdisk, press m to see a menu. The commands you will use are: n to create a new partition; d to destroy a partition; t to change the partition type (83 is Linux Native, 82 is Linux Swap); p prints to the screen the partition information currently in memory (not what's on the disk); w writes the partition table to disk; and q quits.
Until you issue the w command, you are not committed and can make changes or quit without making any changes.
Pay attention to prefixes and suffixes of the partition size. With the partition size you need to specify ``+'' if the size will be other than the ending partition number, and a suffix of ``k'' or ``M'' (case does not matter) to specify KB or MB.
One final note on partitions: you can create up to four primary partitions. If you need more than four partitions, you will create three primary partitions and then extended partitions. The extended partition numbers begin with 5, so you may have /dev/hda1, /dev/hda2, /dev/hda3, /dev/hda5, and /dev/hda6 if you need five partitions.
As a final check before you write the partition table, ensure that your partitions do not overlap. As long as the start and end segments don't overlap with any other start and end segments, you can be sure the partition boundaries are okay. A beginning number may be listed as 1024 for partitions with numbers starting higher than that. For now, just consider that a reminder that the BIOS will not be able to read (or boot from) that partition.
cfdisk does exactly the same thing as fdisk, but displays on the screen the state of the partition table in memory (but not on the disk) at all times. Use the Up and Down arrow keys to select a partition to work on, and the Right and Left arrow keys to select the action to be performed. Then press Enter to perform the action. You will have to input numbers for the size you want to make the partition, but all information is given on the screen, just follow the instructions. cfdisk defaults to /dev/hda, so you must to give it the argument /dev/hdb if you want to change the partition table on a second disk drive. Remember to write the table before you quit. This is the hardest part of cfdisk. It doesn't ask for confirmation before exiting. So select Write and press Enter before you select Quit and press Enter.
You are now faced with the task of deciding which particular distribution of Linux suits your needs. Not all distributions are alike. Many of them come with just about all of the software you'd need to run a complete system--and then some. Other Linux distributions are ``small'' distributions intended for users without copious amounts of disk space. Many distributions contain only the core Linux software, and you are expected to install larger software packages, such as the X Window System, yourself. (In Chapter we'll show you how.)
The Linux Distribution HOWTO (see Appendix A) contains a list of Linux distributions available on the Internet as well as by mail order.
If you have access to USENET news, or another computer conferencing system, you might want to ask there for personal opinions from people who have installed Linux. Also, Linux Journal maintains a table of features comparing Linux Distributions and periodically publishes software reviews of distributions (check http://www.linuxjournal.com/selected.html for on-line versions of the table and articles). Even better, if you know someone who installed Linux, ask them for help and advice. There are many factors to consider when choosing a distribution; however, everyone's needs and opinions are different. In actuality, most of the popular Linux distributions contain roughly the same set of software, so the distribution you select is more or less arbitrary.
This section on Debian GNU/Linux was written by Boris Beletsky.
Table 2.1: Debian GNU/Linux archive structure.
For a base installation of Debian you need about 12 megabytes of disk space and some floppies. First, you need boot and driver floppy images. Debian provides two sets of boot floppy images, for 1.2 and 1.44 Mb floppy disks, and one set of the base images which work with either type of floppy. Check what floppy drive your system boots from, and download the appropriate disk set.
Table 2.2: Debian GNU/Linux installation floppies.
Choose the appropriate floppy set for your hardware from the table on page and write the images to floppy as described on page .
This file is a current list of Debian packages available in the stable Debian distribution. The file comes in a special format; every package has its own entry separated by a blank line. Each package's information is broken up into fields. The table on page describes the fields and their possible values. It should give you an idea of how to build your personal download list. When you have the list of the packages you want, you need to decide how to download them. If you are an experienced user, you may want to download the netbase package--and SLIP and PPP, if necessary--so you can download packages later, via Linux. Otherwise, you can download all of the packages with your current operating system and install them later from a mounted partition.
It's called the Rescue floppy because you can use it to boot your system and perform repairs if there is a problem that makes your hard disk unbootable. Save this floppy after you install the system.
You can do two things at the boot: prompt: press the function keys F1 through F10 to view a few pages of helpful information, or boot the system. If you have any hardware devices that Linux doesn't access correctly at boot time, you may find a parameter to add to the boot command line in the screens you see by pressing F3, F4, and F5.
If you add parameters to the boot command line, be sure to type the word ``linux'' and a space before the first parameter. If you simply press Enter, that's the same as typing ``linux'' without any special parameters.
If this is the first time you're booting the system, press Enter and see if it works correctly. It probably will. If not, you can reboot later and look for any special parameters that inform the system about your hardware.
Once you press Enter, you should see the messages
then there is a page or so of cryptic information about the hardware
in the system. There may be many messages in the form of, ``can't find
something,'' ``something not present,'' ``can't
initialize something,'' or even ``this driver release depends
on something,'' Most of these are harmless. The installation
boot disk is built to run on computers with many different peripheral devices.
Obviously, no computer will have every possible peripheral device, and
the operating system may emit a few complaints while it looks for peripherals
you don't own. You may also see the system pause for a while. This happens
if it is waiting for a device to respond that is not present on your system.
If you find that the time it takes to boot the system unacceptably long,
you can create a custom kernel after you install the system which doesn't
have the drivers for non-existent devices.
cfdisk is used to create a Linux Swap partition (type 82) on the hard drive. You need the swap partition for virtual memory during installation, because the procedure likely uses more memory than you have physical RAM for. Select the amount of virtual memory that you intend to use once your system is installed. It is exactly equal to the amount of disk space required. Sixteen megabytes is probably the smallest practical amount, but use 32 megabytes if you can spare the disk space, and 64 megabytes if the disk is large enough and you won't miss the space.
During the entire process, you are presented with the main menu. The
choices at the top of the menu change to indicate your progress in installing
the system. Phil Hughes wrote in Linux Journal that you could teach
a chicken to install Debian. He meant that the installation process was
mostly just pecking at the Enter key. The first choice on the installation
menu is the next action you should perform according to what the system
detects you have already done. It should say Next, and, at this
point, the next item should be
The shell and commands are there only in case something goes wrong. In particular, you should always use the menus, not the shell, to activate your swap partition, because the menu software can't detect whether you've done this from the shell. Press LeftAlt-F1 to get back to menus. Linux provides up to 64 virtual consoles, but the Rescue floppy only uses a few of them.
Last chance! Have you backed up your disks? Here's your first chance to wipe out all of the data on your disks, and your last chance to save your old system. If you haven't backed up all of your disks, remove the floppy from the drive, reset the system, and create a backup.
The Partition a Hard Disk menu item presents you with a list of disk drives you can partition and runs the cfdisk program (see page ), which allows you to create and edit disk partitions. You must create at least one Linux (type 83) disk partition.
Your swap partition will be used to provide virtual memory for the system and should be between 16 and 128 megabytes in size, depending on how much disk space you have and how many large programs you want to run. Linux will not use more than 128 megabytes of swap, so there's no reason to make your swap partition larger than that. A swap partition is strongly recommended, but you can do without one if you insist and system has more than 16 Mb of RAM.
The swap partition provides virtual memory to supplement the RAM in your system, and it's even used while the system is being installed. That's why we initialize it first.
You can initialize a Linux disk partition, or alternately you can mount a previously initialized partition.
The boot floppies will not upgrade an old system without removing the files--Debian provides a different procedure than using the boot floppies for upgrading existing Debian systems. Thus, if you are using old disk partitions that are not empty, you should initialize them, which erases all of the files. You must initialize any partition that you created in the disk partitioning step. About the only reason to mount a partition without initializing it at this point would be to mount a partition upon which you have user files, like /home, that you don't want deleted.
Select the Next menu item, to initialize and mount the root (the ``/'' directory) disk partition. The first partition you mount or initialize, after the swap partition, if you're using it, is the partition mounted as root. You will be offered the choice to scan the disk partition for bad blocks, as when you initialized the swap partition. It never hurts to scan for bad blocks. Keep in mind that this step can take 10 minutes or more if you have a large disk.
There will be a pause while the system looks for a local copy of the base system. This search is for CD-ROM installations and will not succeed. You are then offered a menu of drives from which to read the base floppies. Select the appropriate drive. Feed in the Base 1, Base 2, Base 3, and Base 4 floppies--and Base 5 if you are using 1.2MB floppies--as requested by the program. If one of the base floppies is unreadable, you need to create a replacement floppy and feed all five floppies into the system again. After the floppies have been read, the system installs the files. This can take ten minutes or more on a slow system.
There is a menu selection for PCMCIA device drivers, but you do not need to use it. After installation you can install the pcmcia-cs package. This detects PCMCIA cards automatically and configures those it finds. It also recognizes cards that are hot swapped when the system is running--they will all be configured as they are plugged in, and de-configured when unplugged.
Next, you are asked if your system clock should be set to Greenwich Mean Time (GMT) or local time. Select GMT if are running only Linux or another UNIX on your system. Select local time if you use another operating system like MS-DOS or Microsoft Windows. UNIX systems keep GMT time on the system clock and use software which converts it to the local time. This allows them to keep track of daylight savings time and leap years, and even allows users who are logged in from other time zones to individually set the time zone on their terminal. If you run the system clock on GMT and your locality uses daylight savings time, the system adjusts for daylight savings time properly on the days it starts and ends.
You should read the tutorial before attempting to install packages with dselect.
dselect allows you to select the packages that you want installed on your system. The Debian package management software is described in detail starting on page . If you have a CD-ROM or hard disk with the additional Debian packages or are connected to the Internet, you may want to read that section now. Otherwise, exit dselect. You can use the package management software after you have transferred the Debian package files to your system.
You must be the superuser (root) to use dselect.
If you install the X Window System and do not use a US keyboard, read the X11 Release note for non-US keyboards.
Table 2.3: Fields in a Debian/GNU Linux Packages file
record.
Debian distributions come in archives called packages. Every package is a collection of files (programs, usually) that can be installed using dpkg or dselect. In addition, the package contains some information about itself that is read by the installation utilities.
The priority of a package indicates how essential or necessary it is. Debian GNU/Linux classifies all packages into four different priority levels:
Never remove a required package from the system unless you are absolutely sure of what you are doing. This bears repeating: Never, never, never remove a required package from the system unless you are absolutely sure of what you are doing. It is likely that doing so will render your system completely unusable.
Required packages are abbreviated in dselect as Req.
Important packages are abbreviated in dselect as Imp.
Standard packages are abbreviated in dselect as Std.
Optional packages are abbreviated in dselect as Opt.
Extra packages are abbreviated in dselect as Xtr.
By default, dselect automatically selects the Standard system if the user doesn't want to individually select the packages to be installed.
The section of a package indicates its functionality or use. Packages on the CD-ROM and in FTP archives are arranged in subdirectories according to function. The directory names are fairly self-explanatory: for example, the directory admin contains packages for system administration and the directory devel contains packages for software development and programming. Unlike priority levels, there are many sections, and more may be added in the future, so we do not individually describe them in this guide.
A conflict occurs when two or more packages cannot be installed on the same system at the same time. A good example of conflicting packages are mail transfer agents (MTAs). A MTA is a program that delivers electronic mail to users on the system and other machines on the network. Debian GNU/Linux has two mail transfer agents: sendmail and smail.
Only one mail transfer agent may be installed at a time. They both do the same job and are not designed to coexist. Therefore, the sendmail and smail packages conflict. If you try to install sendmail when smail is already installed, the Debian GNU/Linux package maintenance system will refuse to install it. Likewise, if you try to install smail when sendmail is already installed, dselect (or dpkg; see below) will refuse to install it.
A dependency occurs when one package requires another package to function properly. Using our electronic mail example, users read mail with programs called mail user agents (MUAs). Popular MUAs include elm, pine, and emacs RMAIL mode. It is normal to install several MUAs at once because they do not conflict. But MUAs do not deliver mail--that is the job of the MTA. So all mail user agent packages depend on a mail transfer agent.
A package can also recommend or suggest other related packages.
dselect is simple, menu-driven interface which helps install
packages. It takes you through the package installation process in the
order of the on-screen menu:
There are two ways to select an option from the menu: choose it with arrows, or press the key of the corresponding letter in brackets.
To exit the Select screen after all of the selections are complete, press Enter. This returns you to the main screen if there are no problems with your selection. You must resolve those problems first. When you are satisfied with any given screen, press Enter.
Dependency conflicts are quite normal and to be expected. If you select package A and that package requires the unselected package B in order to run, dselect warns you of the problem and will most likely suggest a solution. If package A conflicts with package B, you must decide between them.
The screen scrolls by fairly quickly on faster machines. You can halt the display is by pressing Control-S and restart it with Control-Q. At the end of the run, there will be a list of any uninstalled packages.
where filename is the name of the file containing a Debian package,
like tcsh_6.06-11_i386.deb. dpkg is partly interactive;
during the installation it may ask additional questions, like whether to
install the new version of a configuration file or keep the old version.
You may also unpack a package without configuring it by entering:
If a package depends on an uninstalled package or a newer version of a package you already have, or if any other dependency problem occurs during the installation, dpkg will exit without configuring it.
To configure a package, type:
where package is the name of the package, like tcsh.
(Notice that this is not the original name of the file from which tcsh
was installed, which was longer, included a version number, and ended in
.deb.)
If there are any installed packages that depend on the one you wish
to remove, the package will not be removed, and dpkg will
abort with an error message.
where package-name-pattern is an optional argument specifying
a pattern for the package names to match, like *sh. Normal shell
wildcards are allowed. If you don't specify the pattern, all of the installed
packages are listed.
where filename-pattern is the pattern with which to search the
package names for a match. Again, normal shell wildcards are allowed.
The Debian community is a group of more than 150 unpaid volunteers from all over the world who collaborate via the Internet. The founders of the project have formed the organization Software in the Public Interest (SPI) to sponsor Debian GNU/Linux development.
Software in the Public Interest is a non-profit organization formed when the FSF withdrew their sponsorship of Debian. The purpose of the organization is to develop and distribute free software. Its goals are very much like those of FSF, and it encourages programmers to use the GNU General Public License on their programs. However, SPI has a slightly different focus in that it is building and distributing a Linux system that diverges in many technical details from the GNU system planned by FSF. SPI still communicates with FSF and cooperates in sending them changes to GNU software and in asking its users to donate to FSF and the GNU project.
SPI can be reached by post at:
Software in the Public Interest
P.O. Box 70152
Pt. Richmond, CA 94807-0152
There are several Debian-related mailing lists:
There are also several mailing lists for Debian developers.
You can subscribe to those mailing list by mail or the World Wide Web. For more information, please visit http://www.debian.org/.
To receive more information on the bug tracing system, send e-mail to [email protected] with help in the body of the message.
This section on Red Hat Linux was written by Henry Pierce.
RPM gives system administrators the ability to: upgrade individual components
or entire systems while preserving the configuration of the system or package;
query the database for the location of files, packages, or related information;
perform package verification so packages can be installed properly, or
at all; keep source packages ``pristine'' (provide the package author's
original source and second-party patches separately) so that porting issues
can be tracked. Because RPM does this, you can install, upgrade, or remove
packages with a single command line in text mode or a few clicks of the
mouse in X Package Management Tool. Examples of using RPM from the command
line are:
Take, for example, bash-1.14.7-1.i386.rpm. The name itself
contains useful information: the package is bash (the Bourne Again
SHell), it is version 1.14.7, and it is build 1 of the current version
for Red Hat Linux. It was built for Intel or compatible 80386 or higher
CPUs, and it is in RPM format. So, if you see a package named bash-1.14.7-2.i386.rpm,
you know that it is the second build of bash version 1.14.7, and
probably contains fixes for problems of the previous build and is more
current. While the internal organization of a *.rpm file is beyond
the scope of this section, a properly built package contains an executable
file, any configuration files, the documentation (at least manual pages),
any miscellaneous files directly related to the package, a record of where
the packages files are to be installed, and a record of any required packages.
After successful installation, information about the package is registered
in the system's RPM database. A more thorough discussion of RPM package
management system may be found in the RPM HOWTO (see Appendix A).
It is also available at
Customizing which packages are available for installation is an option when installing the system via FTP, NFS, and hard drive. CD-ROMs (typically) cannot be written to, but you can copy the files to the hard drive and install from there with the customized package list. FTP and NFS installations can only be designed if you have root access to the server(s) on your network or your system administrator is willing to work with you. The following installation situations make custom installation desirable: when obtaining Red Hat Linux via FTP over a low-bandwidth connection or when designing a suite of software to be used by all Red Hat Linux workstations on a network.
To customize the installation, you must obtain the /base/comps file which provides you with the list of packages that a full installation would normally include. Then, the packages you actually want to install from /base/comps need to be downloaded. The /base/comps file must be edited to reflect the packages that you obtained and are going to install.
If you have local RPM packages, you can add them to the comps file as well.
That is a tag to identify the category number, the category, a list of the package names in the category, and the tag ``end'' to mark the end of the category.
Without exception, everyone needs all of the software packages listed in the Base section of the file. The other sections, though, can generally be customized or eliminated to suit a particular need. For example, there are three types of Networked Stations: ``plain'', management, and dial-up. An examination of these sections shows that many of the software packages are listed in all three categories, but some software packages are specific to the category. If you are creating a Dial-up Networked Station, then you can safely eliminate the ``Plain'' and ``Management'' sections and any software unique to those categories. Conversely, if you only need basic networking capability for networked work stations, the other sections can be eliminated from the file as well as the software unique to those sections. All you need to do is make sure that you have all of the software packages listed in that category. If you have local custom packages (those not provided by Red Hat Software), you should add them to an existing category that is appropriate rather than creating a new category.
Because the list of packages in each category only contains the name
of the package (i.e., not the entire package-name-version-build.rpm),
you can substitute any updates Red Hat has made available in the updates
directory on:
or one of Red Hat's mirror sites for the original package found in
the distribution's original /RedHat/RPMS directory. The installation
program is relatively version-insensitive. The only warning here is to
insure that package dependencies are met. When an RPM package is built,
RPM itself tries to determine what packages must be installed for the package
to work (the RPM developer also has direct control of this as well--he
or she can add dependencies that RPM might not ordinarily detect). This
is where a little experimentation or research may be needed. For example,
one way to determine package dependencies (if you have user access to your
NFS server on an existing Red Hat Linux box) is to telnet or login
into it (or if you have the CD-ROM, mount it and go to the RedHat/RPMS
directory) and query the package for its dependencies:
The ``-q'' puts rpm in query mode, the ``-p'' tells rpm to query an uninstalled package, and the ``-R'' tells rpm to list the target package's dependencies. In this example, we see libc.so.5 and libtermcap.so.2 are required. Since libc and termcap are part of the base of required software (as is bash), you must insure that the libc and libtermcap packages (the dependency packages) are present to be able to install bash (the target). As long as you get the entire base system installed, you can boot the system when the installation program completes. You can add additional packages to Red Hat Linux as required even if the installation program reports that a package failed to install because its dependencies were not met.
The table on page describes the categories of software found in /base/comps in Red Hat v4.0:
Table 2.4: Important Red Hat Linux packages.
If you encounter a package during the installation which requires another package that you don't have available, or you make a mistake in the comps file, you can generally finish the installation and have a bootable, working system. You can correct the problem by manually adding the failed packages and their dependencies later. Overall, get the entire Base system and one of the Networked Station packages installed, and you can add anything you need or want later.
Table 2.5: Typical Red Hat Linux disk space requirements.
If you choose SCSI, you must know what kind of SCSI card you have and will be presented a list. Scroll down the list until you find your SCSI card. After you select it, you will be asked if you wish to AUTOPROBE for it or SPECIFY OPTIONS. Most people should choose AUTOPROBE, which causes the program to scan for your SCSI card and enable the SCSI support for your card when found.
After the Installation Program has successfully located the Red Hat CD-ROM, you should read the next section.
If your machine locks up, you must press Ctrl-Alt-Delete to reboot the
system. Most of the time, when this happens, it is because the probing
interferes with a non-Ethernet card. If this happens, try again and choose
SPECIFY OPTIONS, and give the data about your card in this form:
This instructs the probe to look at the location specified by the values
IRQ and IO_PORT for the Ethernet card. If your Ethernet card
is configured for IRQ 11 and IO_PORT 0x300, specify:
After the card has been successfully found, you will be prompted for
TCP/IP information about your machine and the NFS server with the Linux
installation packages. First, you will be asked to provide the target machine's
IP Address, Netmask, Default Gateway, and Primary Name Server.
For example:
After you select OK, you are prompted for the target machine's
Domain name and Host name. For example, if your domain name
is infomagic.com and host name is vador, enter:
The last screen prompts you for the NFS server and the exported directory
containing the Red Hat distribution. For example, if your NFS server is
redhat.infomagic.com, enter:
If you do not know these values, ask your system administrator. After you enter the values, select OK to continue. If the installation program reports an error locating the Red Hat distribution, make sure that you have the correct values filled in above and that your network administrator has given you export permission for the target machine.
If your hardware isn't detected, you may need to provide an override
for the hardware to be enabled properly. You may also want to check:
to see if Red Hat has updated boot diskettes for your hardware.
Where xxxx is the root partition.
After the installation procedure is complet, you are ready to reboot your system and use Linux.
This tells us that ``dos'' is the default operating system,
which will boot if nothing is typed; to boot Linux, type `` linux''.
However, LILO lets you pass parameters to the Linux kernel which override
the default behavior. For example, you may have been experimenting with
start-up configuration files and did something to prevent the system from
coming up properly. If so, you want to boot the system up to the point
where it reads the configuration files and no further . The override for
this is ``single'':
boots the system in single user mode so you can take corrective action.
This is also useful if your system doesn't boot all the way to the login:
prompt for some reason.
This section on Caldera OpenLinux was written by Evan Leibovitch.
This section is intended to be a complement to the Getting Started Guides that Caldera ships with all of its Linux-based products. References to the Getting Started Guide for Caldera Open Linux Base is indicated throughout this section as ``the Guide''.
COL is available directly from Caldera, or through a network of Partners around the world who have committed to supporting Caldera products. These Partners can usually provide professional assistance, configuration and training for Caldera users. For a current list of Partners, check the Caldera web site.
Caldera's Guide provides an installation worksheet that assists you in having at hand all the details of your system that you'll need for installation. It is highly recommended you complete this before starting installation; while some parameters, such as setting up your network, are not required for installation, doing it all at one time is usually far easier than having to come back to it. Sometimes this can't be avoided, but do as much at installation time as possible.
While the Guide recommends that you create the floppies by copying them from the CD-ROM, it is better to get newer versions of the disks from the Caldera web site. The floppy images on older CD-ROMs have errors that cause problems, especially with installations using SCSI disks and large partitions.
To get newer versions of the floppy images, download them from Caldera's FTP site. In directory pub/col-1.0/updates/Helsinki, you'll find a bunch of numbered directories. Check out the directories in descending order--that will make sure you get the latest versions.
If you find one of these directories has a subdirectory called bootdisk, the contents of that directory are what you want.
You should find two files:
The XXX is replaced by the version number of the disk images.
At the time of writing, the current images are 034 and located
in the 001 directory.
After you have these images, transfer them onto two floppies as described for generic installations on page , using the MS-DOS program RAWRITE.EXE from the Caldera CD-ROM or dd from a Linux system.
Caldera's CD-ROM is bootable if your system's BIOS allows it, but use the downloaded floppies if possible. They are newer and will contain bug-fixes that won't be in the CD versions.
To run the Linux fdisk, you must start your system with the boot (and maybe the modules) floppy described above. You must tell COL what kind of disk and disk controller you have. You can't even get as far as entering fdisk if Linux doesn't recognize your hard disk!
To do this, follow the bootup instructions in the Guide, from step 2 on pages 33-36. Don't bother going through the installation or detection of CDROMs or network cards at this time; all that matters at this point is that Linux ``sees'' the boot hard disk so you can partition it with fdisk. A brief description of the use of the Linux fdisk is provided on page 28 of the Guide.
Remember that when running fdisk, you need to set up both your root file system as Linux Native (type 83) and your Swap space (type 82) as new partitions. A brief discussion of how much swap space to allocate is offered on page 10 of the Guide.
As soon as you have allocated the partitions and written the partition table information to make it permanent, you must reboot.
This section on Linux Slackware was written by Sean Dreilinger.
Whether or not to choose Slackware as the flavor of Linux you will use is a serious consideration. It may seem like a trivial decision now, but Linux boxes have a way of taking on more and more responsibility in organizational computing environments. Plenty of Linux experiments have evolved in their first year to become mission-critical machines serving many more users and purposes than originally intended. Slackware is one of the most widely used distributions of Linux. When it comes to finding the newest, easiest, or most carefully planned distribution of Linux, Slackware may be ``none of the above''. Some background on the life and times of Slackware put things into perspective.
By January 1994, Slackware had achieved such widespread use that it earned a popular notoriety normally reserved for rock stars and cult leaders. Gossip spread through the Usenet suggesting that the entire Slackware project was the work of witches and devil-worshippers!
``Linux, the free OS....except for your SOUL! MOUHAHAHAHA!''
Have a look also at the Buyer's Guide published in the Linux Journal, which gives a thorough comparison and evaluation of each major distribution. For a straightforward listing of Linux flavors, have a look at the Linux Distribution HOWTO (see Appendix A).
One thing we don't hear too often with Slackware is the U-word. Slackware's setup program is designed to put a fresh operating system onto empty hard disks or empty disk partitions. Installing on top of a previous Slackware installation can erase your custom applications and cause compatibility problems between updated applications and older files on the same system. When Slackware was first put together, everyone was a first-time Linux user, and the system was always experimental--reinstalling the entire operating system and applications was the norm in a developmental system. Today, many institutions and businesses run mission-critical applications on Slackware Linux. In such environment, a simple reboot is a planned activity and taking down the system and overwriting all the user files or custom applications is absolutely unacceptable.
Teaching you how to finagle a Slackware upgrade is beyond the scope
of this chapter, but it is workable if you are an experienced UNIX administrator
and you've taken precautions to preserve your local modifications and user
files. There is an Internet resource that claims to analyze your distribution
and bring it up to date across the Internet. you might want to have a look
at this URL if you're facing an upgrade situation:
Or read, weep, and learn from the upgrade expertise of Greg Louis in
his mini HOWTO document: Upgrading Your Linux Distribution available
where finer LDP publications are mirrored:
yes or no
yes or no
Do you want setup to use mkswap on your swap partitions? Most likely ``yes'', unless you have less than 4MB of RAM and have already done this to help setup work better.
yes or no
partition name
Last chance to back out! When using the install from scratch option, you must install to a blank partition. If you have not already formatted it manually, then you must format it when prompted. Enter ``I'' to install from scratch, or ``a'' to add software to your existing system.
[i]nstall or [a]dd
(Re)format the main Linux partition. Would you like to format this partition?
[y]es, [n]o, or [c]heck sectors, too
ext2fs defaults to one inode per 4096 bytes of drive space. If you're going to have many small files on your drive, you may need more inodes (one is used for each file entry). You can change the density to one inode per 2048 bytes, or even per 1024 bytes. Enter 2048 or 1024, or just hit Enter to accept the default of 4096.
4096 (default). 2048, or 1024
[y]es or [n]o
These are your Linux partitions (partition list displayed). These partitions are already in use (partition list displayed). Enter the partition you would like to use, or type q to quit adding new partitions. Use a format such as: /dev/hda3 or whatever the device name is.
Partition name or [q]uit
Would you like to format this partition?
[y]es, [n]o, or [c]heck sections, too
Now this new partition must be mounted somewhere in your new directory tree. For example, if you want to put it under /usr/X11R6, then respond: /usr/X11R6 Where would you like to mount this new partition?
Mount point
Would you like to mount some more additional partitions?
[y]es or [n]o
[y]es or [n]o
Please enter the partition you would like to access from Linux, or type q to quit adding new partitions. Use a format such as: /dev/hda3 or whatever the device name is.
Partition name or [q]uit
Now this new partition must be mounted somewhere in your directory tree. Please enter the directory under which you would like to put it. for instance, you might want to reply /dosc, /dosd, or something like that. Where would you like to mount this partition?
Mount point
1, 2, 3, 4, or 5
Partition name or [p]artition list
What directory on this partition can the Slackware sources be found. In the example above, this would be: /stuff/slack. What directory are the Slackware sources in?
Directory name
What type of file system does your Slackware source partition contain?
1, 2, 3, 4, or 5
Directory name
1, 2, 3, or 4
[y]es or [n]o
You will need to enter the IP address you wish to assign to this machine. Example: 111.112.113.114. What is your IP address?
IP address
Now we need to know your netmask. Typically this will be 255.255.255.0. What is your netmask?
IP address
Do you have a gateway (y/n)?
[y]es or [n]o
What is your gateway address?
IP address
Good! We're all set on the local end, but now we need to know where to find the software packages to install. First, we need the IP address of the machine where the Slackware sources are stored. Since you're already running on the network, you should be able to use the hostname instead of an IP address if you wish. What is the IP address of your NFS server?
IP address
There must be a directory on the server with the Slackware sources for each disk in subdirectories beneath it. setup needs to know the name of the directory on your server that contains the disk subdirectories. For example, if your A3 disk is found at /slackware/a3, then you would respond: /slackware. What is the Slackware source directory?
Directory name
1, 2, 3, 4, 5, 6, 7 8, 9, 10, 11, 12, or 13
IDE CD-ROM: Enter the device name that represents your IDE CD-ROM drive. This will probably be one of these (in the order of most to least likely): /dev/hdb /dev/hdc /dev/hdd /dev/hde /dev/hdf /dev/hdg /dev/hdh /dev/hda
Device name
SCSI CD-ROM: Which SCSI CD-ROM are you using? If you're not sure, select /dev/scd0.
1. /dev/scd0
2. /dev/scd1
installation method: With the Slackware CD, you can run most of the system from the CD if you're short of drive space or if you just want to test Linux without going through a complete installation. Which type of installation do you want (slakware or slaktest)?
to run mostly from CD-ROM
Any combination of a ap d e f k n q t tcl x xap xd xv y and other disk sets offered, separated by spaces
[y]es or [n]o
These defaults are user definable--you may set any package to be added or skipped automatically by editing your choices into a file called TAGFILE that will be found on the first disk of each series. There will also be a copy of the original tagfile called TAGFILE.ORG available in case you want to restore the default settings. The tagfile contains all the instructions needed to completely automate your installation. Would you like to use a special tagfile extension? You can specify an extension consisting of a ``.'' followed by any combination of 3 characters other than tgz. For instance, I specify ``.pat'', and then whenever any tagfiles called ``tagfile.pat'' are found during the installation they are used instead of the default ``tagfile'' files. If the install program does not find tagfiles with the custom extension, it will use the default tagfiles. Enter your custom tagfile extension (including the leading ``.''), or just press Enter to continue without a custom extension.
Tagfile extension Enter
[y]es or [n]o
[y]es or [n]o
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. Insert the disk and press Return, or s if you want to skip this step.
Enter or [s]kip
[y]es or [n]o
These are the standard serial I/O devices, Which device is your modem
attached to (0, 1, 2, 3)?
0, 1, 2, or 3
[y]es or [n]o
These types are supported. Which type of mouse do you have (1, 2, 3,
4, 5, 6, 7)?
1, 2, 3, 4, 5, 6, or 7
These are the standard serial I/O devices. Which device is your mouse
attached to (0, 1, 2, 3)?
0, 1, 2, or 3
Host name
Now, we need the domain name. Do not supply a leading ``.'' Enter the domain name.
Domain name
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?
[y]es or [n]o
Enter your IP address for the local machine. Example: 111.112.113.114. Enter the IP address for this machine (aaa.bbb.ccc.ddd).
IP address
Enter your gateway address, such as 111.112.113.1. If you don't have a gateway, you can edit /etc/rc.d/rc.inet1 later,or you can probably get away with entering your own IP address here. Enter the gateway address (aaa.bbb.ccc.ddd).
IP address
Enter your netmask. This will generally look something like this: 255.255.255.0. Enter the netmask (aaa.bbb.ccc.ddd).
IP address
Will you be accessing a name server?
[y]es or [n]o
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 your domain (aaa.bbb.ccc.ddd)?
IP address
The kernels are stored as compressed binary image files that you can access from most any operating system to create a Slackware Boot diskette. On the Slackware FTP site, CD-ROM, or NFS mount, you'll find a subdirectory called bootdsks.144, containing 1.44 MB kernel images for creating boot disks on 1.44MB high density 3.5'' floppy diskettes. If you're working from a 5.25'' floppy diskette drive, look in a directory called bootdsks.12 for kernel images that will fit the smaller diskette format.
The table on page
provides a quick reference of the kernel images available as we went to
press. Information and up-to-date boot disk image information is available
from this URL:
Table 2.6: Slackware IDE boot disk images.
Table 2.7: Slackware SCSI/IDE boot disk images.
Log in as root (no password) and type setup or setup.tty.
Transferring Slackware onto your system from here should involve little more than selecting what you want from the menus. By filling out Section 3 of the worksheet in advance, you should be able progress quickly through each menu in order, until you reach the INSTALL option, at which point things may s l o w down: you are advised to select the PROMPT feature and read about each software package, deciding whether or not you'd like it to end up on your Slackware system. The last part of a regular setup is the CONFIGURE section on the setup menu, and the questions you must answer bear a striking resemblance to the second half of the Section 3 worksheet.
and wondering ``What Next?''
Well, if you're plagued by problems, you'll want to proceed directly to the next section on troubleshooting. If things appear to be in working order, you've still got some details to attend to. It's sort of like purchasing a new automobile--after you select and pay for a car, there are still some things that you need before you can drive it with confidence--insurance, a steering wheel club, and perhaps some luxuries that make the driving experience closer to Fahrvergnügen than FAQ!
At this time, the Slackware-specific help you'll find on the Internet tends to be highly customized--like how to NFS-mount the distribution on computers within a certain university or how to wire your dorm room into a particular residential WAN using Slackware.
There is a general Linux mailing list server, [email protected]. See page for a description of how to subscribe to mailing lists via this server.
A man learns what he needs to know about building his house only after he's finished.If, in the process of installing the system, you had some thoughts about how you might do it differently, now is the time. If your Slackware Linux box will be a multi-user machine or a network server, there may never be such a convenient opportunity to re-install or reconfigure the system in radical ways.
Read Chapter 4 for a discussion of what you should do with the root account (or shouldn't).
After this fix, users who attempt to login in as root across
the network will be denied:
This section on S.u.S.E. Linux was written by Larry Ayers.
The SuSE distribution began a few years ago as an adaptation of Slackware. Patrick Volkerding of Slackware helped the SuSE developers at first, but before too long, the distribution began to assume an identity of its own. Several new features intended to aid the first-time user increase the probability an installation won't need to be immediately redone. Given the cross-pollination endemic in the free software world, I wouldn't be surprised to learn some of these features have shown up in newer Slackware releases.
While no distribution can guarantee a painless installation, the developers at S.u.S.E. GmbH have managed to anticipate several problems that new Linux users are liable to have. One of the more frustrating problems is finding that your CD-ROM drive isn't recognized. Copying the packages needed to get started to a hard drive and installing them from there is a solution, but it's awkward and time-consuming. Rather than provide a selection of several disk images, one of which probably has the CD-ROM drive support you need, the single S.u.S.E. boot disk contains a small, basic kernel with all drivers available-if needed-in the form of modules. The kernel daemon is a background process which ensures the relevant module will be loaded if a modular function is needed. This helps to eliminate one stumbling block. Another common trap is underestimating the disk space which you need. This forces the installation to abort itself due to lack of room. When this happens, the crucial final steps (like LILO installation) haven't yet been reached, and starting over is usually necessary. Script-based installations are necessarily sequential in nature; you may know that skipping one step won't hurt anything, but it's hard to anticipate every eventuality in a shell script, and if things go awry the script usually aborts.
During the S.u.S.E. installation, a running tally of partition space remaining is displayed on the YAST screen; while selecting packages, you can try various combinations while keeping in mind how much free disk space you would prefer to remain free. Partitioning and formatting disks, as well as creation and activation of a swap partition, are processes that aren't much different than in other distributions. They all use the same underlying tools; the procedure has become more or less standardized.
Users familiar with the Slackware layout of initialization files will need to make some adjustments; the files usually found in /etc/rc.d are instead in /sbin/init.d.
After you have S.u.S.E. Linux up and running, it's a good idea to install the kernel source (available on the CD-ROM, it's an optional package which can be installed during initial set-up). S.u.S.E. installs a generic kernel, and you probably need only a few of of the accompanying modules. This is an excellent opportunity to familiarize yourself with the mechanics of source code compilation, and you'll end up with a smaller customized kernel with only the capabilities you need. The gcc compiler and accompanying tools must be installed in order to compile a kernel; these tools are a near-necessity on a Linux system even if you're not a programmer. The YAST dependency checking will help insure that all of the required compilation tools are installed.
Kernel compilation can seem daunting to a beginner, but it is a fairly intuitive process. Three interfaces are available for the initial configuration step. The first (and oldest) is a console-mode script invoked via the command make config. This script asks a series of questions and uses the results to write a file which guides the compiler in its work. You need to know some basic facts about your hardware such as what type of hard disk and CD-ROM drive you have. If you want sound support you'll need to know the IRQ your card uses, as well as a few other parameters that can be gathered from the card's manual or the output of the MS-DOS msd utility.
The other two interfaces are menuconfig and xconfig. The first uses a modified version of the dialog program mentioned above, which runs on a virtual console or a xterm and resembles the YAST setup tool. xconfig is a Tk-based version, designed to run in a X window. All three accomplish the same task. The latter two let you make choices without typing much. The kernel sources are well-documented. The README file in the top-level directory contains enough information to nearly guarantee a successful build.
The S.u.S.E. developers have taken some pains in configuring the various window managers, for example, fvwm95. The first time you start X, many of the applications you elected for installation will be available from the mouse activated root window menu. Another entry on the menu allows you to change the window background.
Many well-designed icons are supplied with the S.u.S.E. distribution. This gives new users something of a reprieve. After getting Linux and X running finally, there is enough to do just learning the system without feeling compelled to customize the environment, in order to make it tolerable to view!
At this point it's a good idea to explain how to reboot and shutdown the system as you're using it. You should never reboot or shutdown your Linux system by pressing the reset switch. You shouldn't simply switch off the power, either. As with most UNIX systems, Linux caches disk writes in memory. Therefore, if you suddenly reboot the system without shutting down ``cleanly'', you can corrupt the data on your drives, causing untold damage.
The easiest way to shut down the system is with the shutdown
command. As an example, to shutdown and reboot the system immediately,
use the following command as root:
This cleanly reboots your system. The manual
page for shutdown describes the other command-line arguments that
are available. Use the command man shutdown to see the manual
page for shutdown.
Note, however, that many Linux distributions do not provide the shutdown command on the installation media. This means that the first time you reboot your system after installation, you may need to use the Ctrl-Alt-Del combination.
After you have a chance to explore and use the system, there are several configuration chores that you should undertake. The first is to create a user account for yourself (and, optionally, any other users that might have access to the system). Creating user accounts is described in Chapter 4. Usually, all that you have to do is login as root, and run the adduser (sometimes useradd) program. This leads you through several prompts to create new user accounts.
If you create more than one filesystem for Linux, or if you're using a swap partition, you may need to edit the file /etc/fstab in order for those filesystems to be available automatically after rebooting. If you're using a separate filesystem for /usr, and none of the files that should be in /usr appear to be present, you may simply need to mount that filesystem. See page for a description of the /etc/fstab file.
Almost everyone runs into some kind of snag or hangup when attempting to install Linux the first time. Most of the time, the problem is caused by a simple misunderstanding. Sometimes, however, it can be something more serious, like an oversight by one of the developers, or a bug.
If your installation appears to be successful, but you received unexpected error messages, these are described here as well.
When attempting to boot the installation media for the first time, you may encounter a number of problems. These are listed below. Note that the following problems are not related to booting your newly installed Linux system. See page for information on these kinds of pitfalls.
The most popular cause for this kind of problem is a corrupt boot floppy. Either the floppy is physically damaged, in which case you should re-create the disk with a brand new floppy, or the data on the floppy is bad, in which case you should verify that you downloaded and transferred the data to the floppy correctly. In many cases, simply re-creating the boot floppy will solve your problems. Retrace your steps and try again.
If you received your boot floppy from a mail order vendor or some other distributor, instead of downloading and creating it yourself, contact the distributor and ask for a new boot floppy--but only after verifying that this is indeed the problem.
After the installation media boots, you will see a number of messages from the kernel itself, indicating which devices were detected and configured. After this, you will usually be presented with a login prompt, allowing you to proceed with installation (some distributions instead drop you right into an installation program of some kind). The system may appear to hang during several of these steps. Be patient: loading software from floppy is comparatively slow. In many cases, the system has not hung at all but is merely taking a long time. Verify that there is no drive or system activity for at least several minutes before assuming that the system is hung.
The cause of many system hangs is hardware incompatibility. The last chapter presented an overview of supported hardware under Linux. Even if your hardware is supported, you may run into problems with incompatible hardware configurations which are causing the system to hang. See page , below, for a discussion of hardware incompatibilities.
This item deals with the amount of RAM that you have available. On systems with 4 megabytes of RAM or less, you may run into trouble booting the installation media or installing the software itself. This is because many distributions use a RAM disk, a file system loaded directly into RAM, for operations while using the installation media. The entire image of the installation boot floppy, for example, may be loaded into a RAM disk, which may require more than a megabyte of RAM.
You may not see an ``out of memory'' error when attempting to boot or install the software; instead, the system may unexpectedly hang, or fail to boot. If your system hangs, and none of the explanations in the previous section seem to be the cause, try disabling the ramdisk. See your distribution's documentation for details.
Keep in mind that Linux itself requires at least 2 megabytes of RAM to run at all; most modern distributions of Linux require 4 megabytes or more.
This is an indication that your installation bootup media is corrupt. If you try to boot from the installation media (and you're sure that you're doing everything correctly), you should not see any errors like this. Contact the distributor of your Linux software and find out about the problem, and perhaps obtain another copy of the boot media if necessary. If you downloaded the boot disk yourself, try re-creating it and see if this solves the problem.
This error message means that the root file system (found on the boot media itself), could not be found. This means that either your boot media is corrupt in some way, or that you are not booting the system correctly.
For example, many CD-ROM distributions require that you have the CD-ROM in the drive when booting. Be sure that the CD-ROM drive is on and check for any activity. It's also possible that the system is not locating your CD-ROM drive at boot time; see page for more information.
The most common form of problem when attempting to install or use Linux is an incompatibility with hardware. Even if all of your hardware is supported by Linux, a misconfiguration or hardware conflict can sometimes cause strange results--your devices may not be detected at boot time, or the system may hang.
It is important to isolate these hardware problems if you suspect that they may be the source of your trouble.
If you experience a problem that you believe to be hardware-related, the first thing that you should to do is attempt to isolate the problem. This means eliminating all possible variables and (usually) taking the system apart, piece-by-piece, until the offending piece of hardware is isolated.
This is not as frightening as it may sound. Basically, you should remove all nonessential hardware from your system, and then determine which device is causing the trouble--possibly by reinserting each device, one at a time. This means that you should remove all hardware other than the floppy and video controllers, and of course the keyboard. Even innocent-looking devices such as mouse controllers can wreak unknown havoc on your peace of mind unless you consider them nonessential.
For example, let's say that the system hangs during the Ethernet board detection sequence at boot time. You might hypothesize that there is a conflict or problem with the Ethernet board in your machine. The quick and easy way to find out is to pull the Ethernet board, and try booting again. If everything goes well, then you know that either (a) the Ethernet board is not supported by Linux (see page ), or (b) there is an address or IRQ conflict with the board.
``Address or IRQ conflict?'' What on earth does that mean? All devices in your machine use an IRQ, or interrupt request line, to tell the system that they need something done on their behalf. You can think of the IRQ as a cord that the device tugs when it needs the system to take care of some pending request. If more than one device is tugging on the same cord, the kernel won't be able to detemine which device it needs to service. Instant mayhem.
Therefore, be sure that all of your installed devices use unique IRQ lines. In general, the IRQ for a device can be set by jumpers on the card; see the documentation for the particular device for details. Some devices do not require the use of an IRQ at all, but it is suggested that you configure them to use one if possible. (The Seagate ST01 and ST02 SCSI controllers are good examples).
In some cases, the kernel provided on your installation media is configured to use certain IRQs for certain devices. For example, on some distributions of Linux, the kernel is preconfigured to use IRQ 5 for the TMC-950 SCSI controller, the Mitsumi CD-ROM controller, and the bus mouse driver. If you want to use two or more of these devices, you'll need to first install Linux with only one of these devices enabled, then recompile the kernel in order to change the default IRQ for one of them. (See Chapter 4 for information on recompiling the kernel.)
Another area where hardware conflicts can arise is with DMA (direct memory access) channels, I/O addresses, and shared memory addresses. All of these terms describe mechanisms through which the system interfaces with hardware devices. Some Ethernet boards, for example, use a shared memory address as well as an IRQ to interface with the system. If any of these are in conflict with other devices, then the system may behave unexpectedly. You should be able to change the DMA channel, I/O or shared memory addresses for your various devices with jumper settings. (Unfortunately, some devices don't allow you to change these settings.)
The documentation for various hardware devices should specify the IRQ, DMA channel, I/O address, or shared memory address that the devices use, and how to configure them. Again, the simple way to get around these problems is to temporarily disable the conflicting devices until you have time to determine the cause of the problem.
The table below is a list of IRQ and DMA channels used by various ``standard'' devices on most systems. Almost all systems have some of these devices, so you should avoid setting the IRQ or DMA of other devices in conflict with these values.
Table 2.8: Common device settings.
When Linux boots, you should see a series of messages on your screen
such as:
Here, the kernel is detecting the various hardware devices present
on your system. At some point, you should see the line
followed by a list of recognized partitions, for example:
If, for some reason, your drives or partitions are not recognized,
then you will not be able to access them in any way.
There are several things that can cause this to happen:
Refer to the documentation for your hard drive and/or controller. In particular, many hard drives need to have a jumper set to be used as a slave drive (the second device on either the primary or secondary IDE bus). The acid test of this kind of condition is to boot MS-DOS or some other operating system that is known to work with your drive and controller. If you can access the drive and controller from another operating system, then it is not a problem with your hardware configuration.
See page , above, for information on resolving possible device conflicts, and page , below, for information on configuring SCSI devices.
Most distributions provide a bootup option to specify the drive geometry.
In general, when booting the installation media, you can specify the drive
geometry at the LILO boot prompt with a command such as:
where cylinders, heads, and sectors correspond to the number of cylinders,
heads, and sectors per track for your hard drive.
After installing Linux, you will be able to install LILO, allowing you to boot from the hard drive. At that time, you can specify the drive geometry to LILO, making it unnecessary to enter the drive geometry each time you boot. See Chapter 4 for more information about LILO.
The Linux SCSI HOWTO (see Appendix A) contains much useful information on SCSI devices in addition to that listed here. SCSI can be particularly tricky to configure at times.
Actually installing the Linux software should be quite trouble-free, if you're lucky. The only problems that you might experience would be related to corrupt installation media or lack of space on your Linux filesystems. Here is a list of these common problems.
If you use a CD-ROM, be sure to check the disc for scratches, dust, or other problems that may cause media errors.
The cause of the problem may be that the media is in the incorrect format. Many Linux distributions require that the floppies be formatted in high-density MS-DOS format. (The boot floppy is the exception; it is not in MS-DOS format in most cases.) If all else fails, either obtain a new set of floppies, or recreate the floppies (using new diskettes) if you downloaded the software yourself.
The solution is usually to re-create your file systems (with mke2fs) which deletes the partially installed software. You can attempt to re-install the software, this time selecting a smaller amount of software to install. In other cases, you may need to start completely from scratch, and rethink your partition and filesystem sizes.
The best advice is to retrace your steps when something goes wrong. You may think that you have done everything correctly, when in fact you forgot a small but important step somewhere along the way. In many cases, re-downloading and re-installing the software can solve the problem. Don't beat your head against the wall any longer than you have to!
Also, if Linux unexpectedly hangs during installation, there may be a hardware problem of some kind. See page for hints.
You've spent an entire afternoon installing Linux. In order to make space for it, you wiped your MS-DOS and OS/2 partitions, and tearfully deleted your copies of SimCity and Wing Commander. You reboot the system, and nothing happens. Or, even worse, something happens, but it's not what should happen. What do you do?
On page , we cover some of the most common problems that can occur when booting the Linux installation media--many of those problems may apply here. In addition, you may be victim to one of the following maladies.
While booting the floppy, hold down Shift or Ctrl. This should present
you with a boot menu. Press Tab to see a list of available options. For
example, many distributions allow you to type
at the boot menu, where partition is the name of the Linux root
partition, like /dev/hda2. Consult the documentation for your
distribution for details.
Another command to try (with MS-DOS 5.0 and higher) is
This command attempts to rebuild the hard drive master boot record
for booting MS-DOS, by overwriting LILO. If you no longer have MS-DOS on
your hard drive, you need to boot Linux from floppy and attempt to install
LILO later.
On the other hand, if you did install LILO, and another operating system boots instead of Linux, then you have LILO configured to boot that other operating system by default. While the system is booting, hold down Shift or Ctrl, and press Tab at the boot prompt. This should present you with a list of possible operating systems to boot; select the appropriate option (usually ``linux'') to boot Linux.
If you wish to select Linux as the default operating system, you must re-install LILO. See Chapter 4.
It may also be possible that you attempted to install LILO, but the installation procedure failed in some way. See the previous item.
Most newly installed Linux systems should not require a password for the initial log in. However, if you are asked to enter a password, there may be a problem. First, try using a password equivalent to the username; that is, if you are logging in as root, use ``root'' as the password.
If you simply can't log in, there may be a problem. First, consult your distribution's documentation; the user name and password to use may be buried in there somewhere. The user name and password may have been given to you during the installation procedure, or they may be printed on the login banner.
One cause may be a problem with installing the Linux login program and initialization files. You may need to reinstall (at least parts of) the Linux software, or boot your installation media and attempt to fix the problem by hand--see Chapter 4 for hints.
The most common initial configuration problem is incorrect file or directory
permissions. This can cause the error message
to be printed after logging in (in fact, any time you see the message
``permission denied'' you can be fairly certain that it is a problem
with file permissions).
In many cases, it's
a simple matter of using chmod to fix the permissions of the appropriate
files or directories. For example, some distributions of Linux once used
the (incorrect) file mode 0644 for the root directory (/). The
fix was to issue the command
as root. However, in order to issue this command, you needed
to boot from the installation media and mount your Linux root filesystem
by hand--a hairy task for most newcomers.
As you use the system, you may run into places where file and directory permissions are incorrect, or software does not work as configured. Welcome to the world of Linux! While most distributions are quite trouble-free, very few of them are perfect. We don't want to cover all of those problems here. Instead, throughout the book we help you to solve many of these configuration problems by teaching you how to find them and fix them yourself. In Chapter 1 we discussed this philosophy in some detail. In Chapter 4, we give hints for fixing many of these common configuration problems.