Installing Red Hat Linux
by Jonathan Arehart

Configuring the BIOS

As your machine boots, it does a few power-on hardware checks. You can access the BIOS settings by pressing the -delete- key during these, though it is easiest to do so during the RAM check. Your machine should then give you the BIOS configuration menu.

Before we go further, please note that since we have used these machines in class before, most of their BIOS settings are probably already set as to match the following information, though when you install Linux on one of your own machines, you will want to check for similar settings.

Now that you're in the BIOS configuration, choose "Standard CMOS Setup" and check the date and time to see that they're correct. If they're not you can use the arrow keys to move around and edit the data. After that, arrow down to the section that lists hard drives. Select the first column for each device and press return. This has the machine auto-detect the hardware that is attached, if any, and store the appropriate information about that hardware. For these machines, the hard drive should be on "primary master" and the CD-ROM on "secondary master," though it may be on "primary slave" instead. The others should be empty unless extra devices have been added to the machine.

Now, press the -escape- key. That takes you back to the menu screen, from which you should choose "Advanced Setup." Once you have the advanced screen up, turn off "Trend ChipAwayVirus." Set the "share memory size" to "2M." These machines have an AGP video controller that uses a portion of system memory to store the screen image. We set this to two megabytes because that is the smallest possible value and because the machine is to be a server; it doesn't need a lot of video memory to do graphics modes. Next set the first boot device to CDROM and the secondary to IDE-0. Then turn on "try other boot devices" and disable "boot from onboard LAN." Finally enable the floppy seek option. The point of this is not only to make the system try to boot from a CD, as we're going to do to start the Red Hat installer, but also to allow you to at least try to boot from a floppy in the instance that your machine has hard drive trouble and won't boot from a CD.

Now, go back to the menu screen and choose "Power Management Setup." Here we want to disable the first option. This turns off all the power management features of the BIOS. As these machines are to be servers, we don't really want them spinning down their hard drives, and so forth. Also, though Linux has power management support, it can be tricky to configure, and I've not yet had a reason to play with it.

Next, choose "PCI / Plug and Play Setup" from the BIOS menu. In this screen we want to set "plug and play aware OS" to "no" and "primary graphics adapter" to AGP. I have you set the plug and play aware OS to no, because Linux doesn't currently configure PNP ISA cards without the help of a tool called isapnp (the development kernel series changes this) and because these machines have no ISA cards installed at the moment.

Finally, from the BIOS menu choose "Features Setup." In this screen, we want to disable the onboard IR (infrared) controller, set the the onboard prarallel port to EPP mode (to save a DMA channel), disable Ultra DMA (UDMA) support, and turn off the USB controller. We're turning off UDMA because in our testing it has caused some IDE bus resets, which aren't a problem except that they litter the console with a message each time a bus reset is performed. Note that we had this problem with the specific chipset and hard drives in the machines, so you may not experience it and therefore may be able to leave UDMA enabled. Either way, I didn't see data corruption with UDMA enabled, though the error messages did annoy me as they would keep wrecking whatever I had on screen.

Starting the Installer

Okay, now that we're done fiddling with settings, save your changes and exit. As the machine reboots, or just before you save your settings, place the Red Hat CD in your CD-ROM drive. When you do save your settings the machine reboots, and should now boot into the Red Hat Installer. If your machine won't boot off the CD, you will need to go back into the BIOS as described above and change the boot order to be Floppy first, and IDE-0 second. Once you've done that, place the Red Hat Boot Floppy in the floppy drive and boot/reboot the machine.

After the machine begins booting from the CD-ROM, you should soon see the SYSLINUX boot screen. This feature of the installer can be used to do emergency repair work on a Linux system in the event that problems occurr. For the moment, just press -return-, and the Red Hat Installer will load. It will then show you a welcome message.

The Red Hat Installer uses several keys to allow you to navigate among the various buttons, check boxes, and text fields it uses as you install Linux. -Tab- will cycle "forward" through the available buttons and fields, while -alt- and -tab- (together) will cycle "backward." You can "press" one of the on-screen buttons by pressing the -space bar- or by pressing -enter- once you have tabbed to the button you wish to activate. Check boxes are a bit different, in that you check or un-check them with the -space bar-. -Enter- doesn't work, and is likely to "OK" the screen you are on and move to the next one.

Press -return- and then use the arrow keys to select the language you would like to use during the install. This should be English, as I don't know enough of any of the others to help you. :-) Also, we are using keyboards with the US layout, so choose "us" on the next screen.

Answering Basic Hardware Questions

After we tell the installer how we wish to communicate, it begins to ask questions about our hardware. First it will ask if you need PCMCIA support. Answer no here and the installer will move on to its next question; that of "where is the set of packages that make up Red Hat Linux?" In our case, the packages are on the CD, so choose CD-ROM and press OK.

Packages are much like ZIP archives used in the Windows world and StuffIt archives used on the Macintosh. They contain a copy of all the files that make up a particular piece of software. They also have information about the other programs on which they depend and where on your hard drive they should to be installed.

The installer's next question is, "would you like to upgrade or install a new Linux system?" Since the machines have no operating system at the moment, tell it you want to install. Next, you get to choose which type of install to perform. Since we are building the machines to be server/firewall machines, choose "Custom." We do this beacuse we would like to avoid installing extra packages that are not necessary on a server. The primary set of packages this includes are those that make up the X Window System, a graphical interface for Unix computers. The graphical interface is not necessary on a server, since almost all the people who will use the server will be using it via a network.

Dealing With Disks

Ok, now that we've chosen a type of install, the installer wants to know if we have any SCSI disks. We don't, so choose "no," and the installer should prompt you for which program you would like to use to partition the hard drive. We're going to use Disk Druid because it uses the same interface as the rest of the installer, and because the Linux fdisk program is rather different and more arcane than its DOS counterpart.

The navigation in Disk Druid can be confusing at times. Don't worry, you'll get better at it, and I continue to be frustrated by it. :-) Since the drives we are working with are new, they have no partitions. If Disk Druid asks if it may make a blank partition table, say yes. You will then be at the main Disk Druid screen. The top half shows any partitions on your drive, and the bottom half shows the available disks (just the one in this case). Again a note that since these machines have been used in class before, the drive may have an invalid partition table (a remnant of our partition deletion process), so Disk Druid may ask to make a new partition table.

Before we go into making partitions you will need to know a bit about how Linux refers to disks. Each physical device is given a name based on which connector in your computer it has been given. In Linux hda is the master drive on the primary IDE controller. hdb is the slave drive on that same controller, while hdc and hdd are the master and slave drives on the secondary controller. In our case, the one hard drive is hda and the CD-ROM is hdb or hdc depending on how it was cabled.

Once Linux has assigned a device name, it then numbers partitions. It does so much like DOS does, starting at 1 and going up to 8, though to access 5 through 8 an extended partition must be used. These two conventions combine with the /dev directory to give us full partition names such as /dev/hda1 once Linux has booted. /dev is the directory where Linux keeps device information.

Now back to creating partitions... -Tab- over to the "Add" button and press -return-. This will bring up the "Edit New Partition" screen. -Tab- down to the "Size" field and enter 64. Then -tab- over to the type area and choose "Linux Swap." Now -tab- over to "OK." When you move to the "OK" button, Disk Druid should fill in the "Mount Point" field to indicate that the partition is a swap partition. Now press -return-. In a second or two a swap partition should appear in the list of partitions at the top of the screen.

Once that happens, -tab- back down to "Add" and press -return-. This is the last of the two partitions that we are going to make. Once the "Edit New Partition" screen appears, enter "/" for the mount point. In the size field enter 1, and then -tab- to "Grow to fill disk?" and press the spacebar so that there is an asterisk in the checkbox. This will tell Disk Druid that we want this partition to fill all the space on the disk not used by the swap partition. Now, -tab- over to the type area and select "Linux Native" if it is not already. Then "press" the "OK" button. Disk Druid will then make the "/" (or root) partition as hda1, and move the swap partition to hda5. (hda2 is an extended partition created automatically by Disk Druid.) Finally, -tab- over to "OK" and press -return-.

Now that we're done in Disk Druid, the installer asks us to tell it which, if any, swap partitions we want to set up. Since we just have the one, turn on the check box next to /dev/hda5 and press the "OK" button.

The next screen lists any native Linux partitions found by the installer. In our case, this should be /dev/hda1. Turn on the check box next to it and press the "OK" button. This will format the partition. (We're finally really getting somewhere, huh?) :-)

Packages... Packages...

Now, the meat of the installer... Here you get to tell the installer what software you would like it to install on your system. The list you see has only broad categories. It is possible to select individual packages, though doing so takes a lot of time and can be confusing because of the sheer number of available programs. I know very few people who can tell what most of them do without consulting the descriptions, myself not included.

So, to build your firewall/server machine, turn on the categories in the left column:

Mail/WWW/News Tools e-mail, Usenet News, and Web client software.
File Managers File management tools such as the GNU version of Midnight Commander.
Networked Workstation Support, utilities, and so forth for a networked machine.
Dialup Workstation Support, utilities, and so forth for a machine using SLIP or PPP.
NFS Server Software to allow your machine to be an NFS server or client. NFS is the standard Unix way of doing file sharing.
SMB (Samba) Connectivity Software to allow your machine to be an SMB server or client. This allows connections to (or from) Windows 95/98/NT machines.
IPX/Netware(tm) Connectivity Software to allow your machine to be an IPX server or client.
Anonymous FTP Server An FTP server that only allows anonymous connections. The full ftp server is included in one of the other categories listed here.
Web Server The Apache web server.
DNS Name Server The Berkley Internet Name Daemon (BIND). The most often used name server.
C Development The GNU C compiler.
Development Libraries Shared libraries and their header files useful in programming.
C++ Development The GNU C++ compiler.
Kernel Development The Linux kernel sources and tools for kernel development work.
Extra Documentation Add-ons for the /usr/doc directory such as the Linux Network Administration Guide. Much of this comes from the Linux Documentation project.

After you select the categories of packages to install, -tab- down to "OK" an press -return-. The installer now begins the process of installing all the softare we've just selected. This take anywhere from 12 to 25 minutes, depending on the number of packages and system speed. You get something of a break. :-)

Of Mice and Networking

Once the packages have been installed, the installer will try to find a mouse connected to your computer. It is often too good at finding mice, and will likely tell you that it found a PS/2 mouse that doesn't really exist. Tell it that you have no mouse, and then that you do want to configure networking.

The installer should then attempt to find Ethernet cards in your computer. Since the Red Hat Installer doesn't support the on board 10/100 Ethernet controller, it should find the PCI NE2000 Ethernet card and let you continue on from there. For the purpses of this class we want to use a static IP address. The address you will use today will work while you are in this room, and will not work later. You will need to talk to your internet provider to be sure you have the correct values to use once you are installing on your own computer.

So, for now, your IP address should be something like "". IP addresses have two essential parts, the address itself and a mask. For the address above one would use a mask of "". Hostnames are of the form, with as the domain. The DNS (name) server is "".

Note: At this point, you should begin choosing two names; one for your computer, and one for your private network. The network name should be something that you won't visit or a domain that is not yet registered. If you name your private network and you want visit, it will get a bit inconvenient! For example you could choose to name your computer lorax and your network, making the computer's full name The best way I've found is to find a domain that you like that is also not yet registered. This may take you some time, so don't worry if you have no idea what you want to use. And remember, you can always change it later.

Next, the installer asks what time zone we are in. We want to answer "US/Central" and be sure that the "hardware clock in GMT" checkbox is empty.

System Startup

Now, we need to tell the installer which server programs we would like Linux to start each time it boots. We have a list worked out for you, so go ahead and make the list on your screen match the left column below:

atd atd is one method for starting a program/script at a pre-specified time.
crond crond is a second, and more popular, method for starting software at specified times.
httpd httpd is the Apache web server.
inet inet is the program that starts the telnet server and several others when they are needed. Starting them this way keeps them from using system resources when they're not in use.
keytable keytable sets the keyboard layout to match the language you specify. In our case this isn't really necessary, but it won't hurt to have it if you change your default language later.
linuxconf Adds some extra modules to the list Linuxconf reads as it loads so that Linuxconf can configure more aspects of your Linux system.
named named is the name server which translates IP addresses to the much easier to remember hostnames.
network network is the script that sets up network interfaces as your Linux machine boots.
random random is the script that saves information related to the random number generator.
sendmail sendmail is one part of the mail server software.
syslog syslog is the script that starts the kernel and system logging software.

Go ahead and "OK" the list of programs to start, and then tell the installer that you have no printer. It should then ask you to set a password for "root". "root" is the name of the administrative user on Linux systems, and as such can do anything on/to the system. After we finish the install we'll do some more work with "root" and also make a non-root user. For now, set the password to "testing". But be aware that you will want to change the password later. The word "testing" is far too easy to guess.

Now we have several options as to how passwords are stored on the system. We want to turn on shadow passwords, disable NIS (a method for sharing user and password information across a network of Unix systems), and enable MD5 passwords.

Since we will be using LILO (the Linux Loader) to start Linux when your computer boots, we don't need a boot disk, so answer no there. The installer should then ask where we want to install LILO. We want LILO where the computer will see it each time is starts, so /dev/hda is just perfect. Say "OK" to that screen, and then "OK" to the screen asking about special LILO options, of which we have none.

Dealing with X

Earlier in the install we asked the installer to leave out X Windows (the graphical interface used on Linux) since it is not necessary for a server. However, the Red Hat Installer is set up to always install at least part of X Windows. So, now we're going to give it just enough information to finish the install, but not necessarily have X Windows work correctly.

After you "OK" the screen about special LILO options, you should see a very long list of video cards. Use the page down key on your keyboard to move to the bottom of the list. Then move up a little with the up arrow key until you find "Unsupported VGA compatible video card." When you find it, "OK" the screen. You should then see a list of monitor types. Select "Custom monitor." Then the installer needs to know what resolutions the custom monitor supports. Tell it that the monitor can do the standard VGA resolutions (640 by 480, in 16 colors).

Ok, we are almost done dealing with X Windows. After which we will reboot and see Linux running. :-) Next the installer wants to know what refresh rates are supported (how quickly can the monitor redraw the image). Tell it 50 - 70 and "OK" the screen. Now the installer wants to ask the video card how much memory it has. Tell it "Don't Probe" and then choose "256kb" when it asks for your input.

The final question from the installer is, "which clock chip setting should I use for your video card?" Tell it none, which is what it actually recommends, and then it will ask if it can test the settings we've just given it. Answer with the "Skip" button, and then again (it asks twice).


Finally we are done with the installer. It will give you a message to this effect, at which point you should say "OK" and let the installer reboot your machine. Once it starts to reboot, you should be able to take the CD-ROM disc out of the drive so that your computer won't try to start the install program again. Instead it should boot Linux, start the server programs, and then give you a login prompt.