Originally Published: Tuesday, 21 November 2000 Author: Matt Michie
Published to: install_guides/distributions Page: 1/1 - [Printable]

Installing Slackware

Get Slack! Matt Michie takes you on a trip to explore the installation process of Slackware Linux. Slackware is one of the 'elder' distributions in the Linux community, and it might just be what you're looking for. Enjoy!

   Page 1 of 1  

Slackware, one of the older Linux distributions, has gained a deserved reputation as a stable, well-designed system. It is not recommended for new users since it doesn't have a package system as is the case with Debian and Red Hat, but for a moderately advanced user, Slackware may be what you have been missing about Linux.

There will be four basic steps:

  • Documenting your system;
  • Preparing your hard drive;
  • Installing the base Slackware system;
  • Configuring the system.
Documenting your system

From Mark Stone's excellent OpenContent Debian Install Guide: These steps will be the same for all dual-boot Linux installs.

Linux does an excellent job these days of autoprobing your system to determine hardware and settings. Sometimes, however, Linux does need help, and there are occasions where you'll find that you have some component not yet supported by Linux.

To anticipate these contingencies, and to know what to do about them, it's important to document exactly what you have on your machine.

Here's a suitable checklist of the various system components you'll want to know about ahead of time:
DeviceInformation Needed
Hard Drive(s)Number, size, and type of each hard drive. Which hard drive is recognized by your computer as first, second, and so on. Which adapter type (IDE or SCSI) is used by each drive.
RAMThe amount of installed RAM
CDROM Drive(s)Which adapter type (IDE or SCSI) is used by each drive.
SCSI Adapter (if any)Make and model of the card.
Network Adapter (if any)Make and model of the card.
MouseType (PS/2, USB, serial, or bus). Protocol (Microsoft, Logitech, MouseMan, etc.). If serial, the port to which it's connected.
Video AdapterMake and model of the card. Amount of video RAM.
MonitorHighest color depth and screen resolution the monitor supports under Windows. Horizontal and vertical refresh rates.
Modem (if any)If external, the serial port to which it's connected.
Windows can actually provide you with most of the information you need about your system. Select Start -> Settings -> Control Panel -> System. You should see something like:

Most of the information you want will be found in the Device Manager. Selecting that tab should bring up a window like this:

This will show you which devices are installed on your system. Selecting a device and clicking on the "Properties" button will show you the settings for that device.

Preparing Your Hard Drive

Bill Gates reportedly once said, "640k of RAM ought to be enough for anyone." It's that kind of forward-looking view of the world that gives us a peculiar DOS contrivance now turned into a useful tool: the disk partition. DOS, Windows 3.1, and even the initial release of Windows 95 had limitations on how much hard drive space they could recognize. If a drive were larger than this recognizable limit (two Gigs under Windows 95, I believe), then the operating system simply couldn't "see" the rest of the drive.

To work around this limitation, drives could be formatted into logically separated segments, called partitions. Once formatted in this way, each partition was treated by the operating system as if it were a separate hard drive. Under Windows, if you started with hard drive C: and partitioned this, the first partition would appear as C: and the second partition would appear as D:.

We'll exploit this construct to leave one partition formatted as a Windows partition and to create a second partition formatted as a Linux partition on which to install Slackware.

Windows 98 can recognize large disk sizes, so these days most computers ship with a hard drive formatted as a single partition. This means that you'll need to:

  1. Defragment your hard drive
  2. Resize the existing partition to fill only part of the drive
  3. Add a second partition on the newly freed up space
The trick is to resize your Windows partition without destroying any of the data. This used to be an arduous task. These days it is fairly straightforward using a simple tool called GNU Parted. Here's what we're going to do:
  1. Create a boot floppy disk containing the absolute minimal Linux components needed to run Parted;
  2. Boot your computer with this floppy disk;
  3. Run Parted to shrink your Windows partition;
  4. Reboot the computer and start the Slackware installation.
Resizing your hard drive nondestructively will be easiest, and least likely to cause problems, if you defragment your hard drive first. Windows doesn't store all files in contiguous sectors on your disk. As a result, files can end up scattered across a much larger portion of your hard drive than the amount of drive space you're actually using. Defragmenting simply packs all sectors being used as efficiently as possible onto the beginning of your hard drive. You can use Windows' native defragmenting tool by selecting Start -> Programs -> Accessories -> System Utilities -> Disk Utilities. More effective defragmentation programs come with utility suites like Norton Utilities.

Creating a Parted Boot Floppy

Initially, your hard drive will look something like this if you select My Computer -> C: -> Properties:

To create the Parted floppy, you'll need:

  • a blank floppy disk,
  • the Parted disk image,
  • a program for writing raw files to disk called Rawrite.
You can get the Parted disk image from http://www.gnu.org/software/parted/. It's the file ending in the .img extension. There should be a copy of Rawrite on your Slackwaret CD. If you can't find it, you can always download it from ftp://ftp.debian.org/debian/tools/. When you run Rawrite it will prompt you for the source file. Give it the path to where you've downloaded the Parted disk image. This will be something like "C:\Windows\Desktop\parted.img". It will then prompt you for the target location, meaning your floppy drive. Enter in "A:". Now simply reboot your computer with this floppy disk in the drive.

Running Parted

When this floppy boots, you'll see a lot of unfamiliar messages scroll by that are a routine part of the Linux boot process. You'll eventually come to a command line prompt, something reminiscent of running DOS, and you'll see a message that says "You can run parted by typing 'parted DEVICE' where device is the name of the drive you wish to partition."

Linux has a different naming scheme for disk drives. All devices, including disk drives, are listed in a directory called "/dev". IDE hard drives -- the most common type -- start with the letters "hd". The first hard drive will be "a", the second "b", and so on. Each partition on a drive gets a number, starting with "1". Linux would refer to the first partition on your first hard drive as "/dev/hda1" and would refer to the whole first hard drive as "/dev/hda".

The command we're looking for, assuming you have an IDE drive, is: parted /dev/hda.

This will bring you to a new command line with a prompt like this:


If you hit enter, type "?", or type "help" at this point, you'll get a list of all the parted commands, like this:

Let's assume we want to shrink our partition down from 10 Gigs to, say, four Gigs. Then we want to resize minor partition number 1, starting at the beginning, and ending at 4000. The command would look like this:

(parted) resize 1 0 4000

That's all you have to do.

You may see some warning messages appear when running Parted that have to do with either small discrepancies in the way Windows and Linux measure disk size or that have to do with moving Windows system files. In our experience, these warnings can safely be ignored.

If you reboot your computer at this point, Windows 98 will come up just as before and all your programs and files will be intact. The only difference you'll notice is that Windows now thinks it has a smaller hard drive:

Installing the base Slackware system

Your system should now be ready to have Slackware installed. Most newer computer BIOS and CD-ROM drives allow you to boot from a CD-ROM. All you need to do is insert your Slackware disk one into your drive and reboot your computer. If your CD-ROM is not bootable, you'll need to make a boot disk using a floppy boot image and rawrite.exe.

Either way, after some initial system checks, you should see a screen like this:

At the boot prompt, press enter to begin the installation process. Next, you should see some text scroll by the screen as a basic Linux kernel is loaded.

Next, Slack will show you a login prompt and some initial configuration information. It is always a good idea to read all messages the installer gives you. The installer won't try to outguess you. The program will always assume that you know more than it does; make sure you have all the information you need to make the right choices.

Slackware first needs the Linux partitions properly prepared. At the login, prompt type root and press enter. The standard Linux partitioning program is called fdisk. At the prompt, type "fdisk /dev/hda" and hit return. If /dev/hda is not your primary hard drive, enter the device of your hard drive instead. Fdisk will load and present you with a simple command prompt. Enter "?" or "m" to get a help menu.

First type "p" to print out a list of your current partitions. You should find your previous partitions, including the shrunken FAT partition. Create a Linux partition after the Windows partition by typing N and creating a new primary partition. Mark it as type 83, the Linux partition ID. At this time, you can also create a swap partition, though you are not required to. Once you've completed your changes, print out the current partition table again to verify your changes, and then type "w" to write to disk. If you've made a mistake, type "q" to quit without saving changes, and start over. Be aware that you can lose all data, so be sure to have backups!

Once you've completed the partition and are back at the root prompt, type setup to continue the installation process. Slackware will present you with a text menu with several options. First familiarize yourself with the help file. Next, if you created a swap partition in fdisk, select the addswap menu option to set it up properly.

Once this is finished, move to the next option presented in the menu, Target, which sets up the target partition. There will be three choices in the next menu: Format, Check, and No. We will want to select either format or check. Both will format the Linux partition, but check will check for bad blocks. The safer method is to do a check. You'll have greater assurance that your file system is created correctly. After you make your choice, you'll need to select the inode density. The default, 4096, should be fine for most setups.

The partitioning will continue, and Slackware's installation program will ask if you'd like to continue to select your source media. Select yes and press return. At the following menu, select install from Slackware CD-ROM and hit okay.

The next menu allows you to customize the installation type. The default Slackware will perform an normal installation to your hard drive. This is the best option and gives optimal performance. Slacktest allows you to run your binaries from the CD-ROM. This is mostly to give you a feel for Slackware. Choose the default and continue.

Package selection is the next step. Slackware puts its packages into categories such as Base, Development, KDE, GTK, etc. You'll always need at least the A(Base System), and it is recommended you add at least the D (Program Development) packages. Most Slackware programs need to be compiled after installation. You won't get far unless you have the tools to do this later.

Next, you'll be asked to select which type of prompts you want to see during installation. The best choice is full, which will install everything without any prompting.

After the files have been installed, select the default Window Manager for X and press okay. Finally, you may select a root password.

In order to select a good password, you'll need a sequence of at least six characters. In order to protect your system against malicious hackers, the password needs to be a combination of letters, numbers and characters. It also needs to be something you can easily remember. It does no good to come up with an obscure password that you must write on a note taped to your monitor because you can't remember it.

A good way to choose a password is to take a phrase you can easily remember, and use the first letter from each word plus some numbers of symbols at the end. For example, "Use The Force Luke!" could be changed into "U,TFL!1977". Of course, it is best to choose a less common phrase. Remember that Linux passwords are case sensitive, and you are allowed to use numerals and symbols.

Finally, select exit, and reboot.

Configuring the System

Most of Slackware is done through editing the text configuration files in /etc. For instance, to edit the servers running through inetd, open /etc/inetd.conf in your editor of choice. To comment out a line, precede it with a '#'. Once you've completed this, save the file, and at the prompt, type: killall -HUP inetd. This will restart inetd with the changes you've added. Be sure to read the man pages for exact syntax information. It is always a good idea to make backups before you implement any changes that affect the system.

Connecting to the Internet via dialup is not a simple task in Slackware. To start, you'll need to have all of your ISP's configuration settings right at hand. You'll need to edit the text configuration files in /etc/ppp.

First, review the Linux Network and PPP HOWTOs. They will give you a more in-depth overview of what needs to take place to get your system onto the Net. Your kernel should already have PPP support compiled in, but if you get messages about PPP not being available, you'll need to download a new version of the kernel and add support for PPP. Next, you'll need to make a symlink from the com port device to /dev/modem. If in Windows your modem is on COM1, /dev/cua0 will be the device, COM2 maps to /dev/cua1, and so forth.

Finally, open up the sampe ppp.conf in /etc/ppp. It will contain default settings, simply change the phone number, user name, and password to your defaults. Make sure the ppp-on script is correct and attempt to run it. Your modem should dial out and connect to your ISP.

Make sure you also edit /etc/resolv.conf with your ISP's DNS numbers. The format looks like this:


(Where the IP addresses are the actual IPs of the primary and secondary DNS servers.)

If you are still having problems connecting, use the minicom utility to dial into your ISP. You may have to change the chat script if your ISP uses a different login and password prompt.

Give yourself a pat on the back. You've become a part of the bigger Linux community. You'll be able to find more resources at Linux.com, Slackware.com, and other Open Source Software Sites. Be sure to check out IRC and Newsgroups for further assistance.


the Internet Domain Name System, for changing a domain name like 'linux.com' into a unique IP number, like When installing linux, you need to tell the system the address of your ISP's DNS server; something that your ISP should have given you when you signed up.
Global network of computer systems, originally funded from the US Department of Defense.
A program to shrink partitions, if they contain unused free space.
'Segments' of your hard drive. Using partitions, you can split your hard drive into space for Linux and Windows at the same time.
'Point-to-point protocol'. A way of connecting to the Internet, usually through a modem.
A program for DOS/Windows that lets you create a bootdisk - Slackware uses this program to create the install boot disks.
A way of packaging files; like a .zip file on a Windows system, but containing more information. Slackware uses RPM files by default for packaging.
Stable, simple, mature Linux distribution, has a BSD flavor
Window Manager
KDE/Gnome are both window managers. They make X (which is normally fairly ugly) look nice and pretty, and give you a means of managing applications.
X Window
'The X Window System' (or X) is the system a typical linux system uses to display a GUI (Graphical User Interface). No matter whether you use KDE, Gnome, or any other Window Manager, X is there.

Matt Michie exists in the New Mexican desert. Please visit his web site at http://daimyo.org/.

This article is made available under the terms of the Open Publication License. You are encouraged to comment on it, and to make your comments available for future versions of this article. Like software, documents serve the community best when they are open and living documents. Portions of this article were adapted from Mark Stone's Debian Installation Guide.

   Page 1 of 1