How I set up new computers with Slackware Linux

Page created: 2023-02-25 , updated: 2023-08-09

Back to my Slackware pages Related: Software I Use

Creating install media (USB stick)

You’ll want to grab the "DVD ISO" from the Slackware mirrors:

Download slackware64-15.0-install-dvd.iso.

Write it directly to a USB drive. Here’s how I do it:

$ lsblk  # make note of the device for your USB drive
$ sudo cp slackware64-15.0-install-dvd.iso /dev/sdx  # change to YOUR device!

You’ll note that I use a simple cp rather than some arcane dd incantation. When I was writing this epic survey of coreutils, I discovered that there is absolutely no need to use dd to copy an ISO to a block device like a USB "thumb" drive.

This USB installer will be valid as long as Slackware 15.0 is current. Package (and kernel) updates are done online via slackpkg. I’ve learned to dedicate a USB stick for the Slackware installer and not re-use it for anything else. It comes in suprisingly handy for rescuing systems, etc.


If you can, do an EFI install. The spec is one of those hideously complicated big committee industry things. But, the simple parts are really, really simple and they make kernel upgrades pretty logical and painless.

However, I have an Acer brand laptop that just absolutely will not allow me to install Linux the EFI route. I’ve tried every UEFI "bios" combination on multiple occasions. As near as I can tell, it’s been locked down on purpose or by accident to only boot Windows from the EFI boot menu.

On systems like that, setting the UEFI "bios" to do a "legacy boot" (which should be enough of a keyword search to find out what it’s called on your system) and installing Slackware with LILO (the Linux Loader!) as a bootloader and writing it to the Master Boot Record is no problem. It works fine and probably will for many, many years to come.

Boot it

Now you’ll need to boot from the USB drive. Obviously, I can’t help you much with this, but most motherboard firmware these days seem to be converging on DEL for the main menu and F11 for a boot menu.

I have one computer that needs me to plug my USB keyboard in at just the right time and then press the correct key for some stupid reason.

If given a choice, you’ll probably want to pick the "(UEFI)" boot option, even for the installer. I believe Slackware will need this in order to write the EFI boot option to firmware. But I barely know how any of that works, so I invite someone to send me any additional details others should know!

When asked, you’ll probably just want to go with the "Huge Kernel". It’s very reliable. Follow the keymap and root login instructions.

Now Slackware dumps you at a command line. Feel free to read any messages and explore. It’s just regular Linux, with a limited but complete set of tools.

EFI partition scheme

Before you run the install script, you’ll need to prepare your disk for installation.

With the price of SSDs so astoundingly low these days, I often install to a completely fresh drive and keep my old one around as a just-in-case backup of whatever I was previously running.

I like the cfdisk tool for a menu-driven partitioning experience.

If you run cfdisk with no options, it usually picks the drive you want. If you’ve got a lot of drives, you may want to use something like lsblk or fdisk to list them and then provide that device as a parameter (e.g. cfdisk /dev/sda).

Here’s the partitions I like to make:

  1. 100Mb EFI System

  2. 16Gb Linux swap

  3. 60Gb Linux filesystem

  4. ___Gb Linux filesystem (the rest of the drive)

The Slackware installer will format all of these for you (with your permission).

The EFI partition is where the Slackware bootloader and kernel are going to be written. The Slackware installer will detect this partition by its type and write the bootloader here (again, with your permission).

Feel free to make the swap partition bigger or smaller. There’s lots of "advice" on the Internet about this, enjoy!

The 60Gb partition is where I’ll have Slackware mount the root (/) of the filesystem. The "rest of the drive" partition is where I’ll have it mount /home.

Feel free to change the size of these last two partitions (or add more) to suit your application.

(I used to just install the OS and everything else to one big partition, but I’ve since learned to regret that. Separating the OS from user data is much more flexible. You can fix a messed up OS by just doing a fresh install without having to worry about your data. Just skip the cfdisk step next time!)

To accomplish this, Delete any existing partitions as needed (CAREFUL!!!) and then create the new ones with New followed by Type. When you’re happy with it, choose Write followed by Quit.

Thoughts on full disk encryption (why I don’t)

I’ve been asked why I don’t mention full disk encryption. Slackware does have a guide for doing this, but it’s not a simple button press:


The above link comes from a mirror. You can see the whole Slackware file tree, with the above file at the root here:

Here’s why I’ve never bothered (yet):

  • I mostly use desktop computers in the comfort of my own home.

  • I also use laptops, but as a way to compute on the couch or porch, not for coffee shops or travel.

  • My "real home" isn’t actually on these computers, it’s on a headless box in the basement via SSH.

  • Most of the things on my computer are for public sharing anyway (open source projects, this website, etc.)

  • Truly sensitive things go into my encrypted password store.

  • I remember when hard drives weren’t as reliable as they are now.

I used to take laptops on trips and vacations. But I’ve since learned to not do that. I leave computing behind now when I travel. I concentrate on my family and/or the place I’m visiting.

If I did need to travel with sensitive information, I would put it in my password store. For this, I use a program called pass:

It’s really a lightweight front-end for GPG (GNU Privacy Guard) OpenPGP cryptography. The store is a directory of encrypted files. The files can be document-sized or just a couple lines for a username and password. The program cares not.

I’ve intentionally limited how much sensitive stuff I actually keep on any of my computers anyway, but I understand that others will will have different needs. Someone hacking this website, for example, will only have access to…​this website.

I’m reminded of this tangentially related quote:

"Backups are for wimps. Real men upload their data to an FTP site and have everyone else mirror it." --Linus Torvalds

I guess this next one shows my age: I’ve had plenty of experience with failed storage media. Floppy discs were the absolute worst, but I’ve had tons of spinning platter hard drives go bad as well. Of course, the real solution to this is to always make backups, but things happen. I’ve been able to recover lots of data from otherwise messed-up unencrypted drives.

Finally, I just like to keep things simple. The vast majority of the data my computer shuffles around does not need to be encrypted, so I don’t. I’m well aware that this may someday bite me in a surprising way. But everything is a trade-off between complexity/convenience/security.

I’m always open to ideas. It wouldn’t surprise me at all to find myself using full disk encryption some day in the future.

Okay, now on with the install…​

Slackware install

Once your disk is partitioned, you’re ready to start the Slackware installer. This is a simple menu-based script based on dialog for the TUI display. Hope you like blue and teal! Start it with:

# setup

Then I let it guide me through the installation steps starting with setting up the swap space.

The rest of this is in no particular order:

As mentioned, the installer will detect your partitions and offer to format them for you. The ext4 filesystem (default) is the "no regrets" option. The btrfs option will give you all sorts of cool features, but then people on the Internet will yell at you and make you sad.

As mentioned, I have it mount root / and /home to separate partitions, but this is totally optional. And of course you can have more partitions than that.

The network setup is really simple for hard-wired machines. You can setup WiFi after installation with NetworkManager. In fact, these days, I choose the NetworkManager, even if the machine doesn’t have WiFi.

Slackware should also detect your EFI partition and offer to format it.

Later, it will ask if you would like to use ELILO and add Slackware as an EFI boot option. I go with these. People on the Internet will yell at you for not using Grub, but ELILO works just fine like LILO did before it, so I’ll wait until it doesn’t. Running Slackware means you are in charge.

(By the way, if you have brief instructions for installing Slackware with Grub as the bootloader, I’d love to include or link to them here!)

Always do a full install of the packages (this is the default). Slackware is a complete system and it assumes that you have installed everything. The package-making scripts at and all forum help, etc. will assume you have installed everything. Slackware is a true general-purpose desktop operating system.

(Of course, you can, and I have, made minimal installs of Slackware for constrained storage setups. But know that you may have some challenges.)

On the window manager/desktop environment selection, I always pick "xfce". I’m a big fan of xfce and related tools. (While I’m giving out accolades, I’m also a huge fan of the KDE "k"-prefixed software like kstars and ktuberling (the potato editor!) and especially Krita!) I always switch over to dwm, the tiling window manager, once everything’s working. But xfce gives me a great initial X11 test.

At the end of the installation, you can remove the USB installer drive (when instructed) and reboot.

First boot

If the installation went well, you’ll now boot into the fresh install.

The first thing I do is run the adduser script to create my regular non-root account:

# adduser

When prompted, I add the "wheel" group to my account (much easier than remembering this incantation to add it later: usermod -a -G wheel dave).

Then I edit the sudoers file to allow users in the "wheel" group to have sudo rights. I like the NOPASSWD option on my personal computers. That’s one of the commented options, so I just need to uncomment one of the lines.

# visudo

Hope you know the vi basics!

Second boot

Now I restart (I could just logout, but I like to have a new install start up a couple times) and log into my new "dave" account.

I immediately start X Windows (yes, yes, the "X Windows System") with:


That lets me know if the video drivers are working. I’ll also pop open Firefox (ESR version already installed with Slackware, of course) and make sure the network looks good. Now’s also the time I’ll try connecting to WiFi if I’m on a laptop or other wireless machine.

slackpkg upgrade

Now it’s time to finish updating Slackware. There will have been many upgraded packages since the installer was made.

I’ll typically open up a terminal in xfce to do this. The -i option for sudo starts a "login shell" for root, which I find to be nearly identical to actually logging in as root.

First, we need to update slackpkg’s list of packages.

$ sudo -i
# slackpkg update

At this point, slackpkg will complain that we haven’t uncommented a mirror and will list the path of the file where we should do this. I always uncomment the main mirror redirector URL rather than trying to find one from the big list at the bottom (which is subject to change).

# vim /etc/slackpkg/mirrors
# I uncomment this:

Now I can do the update followed by install-new.

# slackpkg update
# slackpkg install-new

WARNING: The next step is controversial! Feel free to look this up. No matter how you go about this, someone on the Internet will yell at you. With that in mind I do the easiest thing: I let slackpkg upgrade my kernel!

(In brief, if you don’t want to live dangerously like me, take a look at /etc/slackpkg/blacklist for some comments about keeping slackpkg from updating the kernel.)

So here goes (this may take a while):

# slackpkg upgrade-all  # did you read the warning above?

It’ll download and perform an upgrade on all packages with upgrades (including the kernel!!!)

(Hey, did you hear the one about how Slackware has no package management? If not, just wait about an hour. Slackware absolutely has package management tools. The difference is that they respect you and believe in you.)

Kernel upgrade

If you’ve followed along, you have definitely just upgraded your kernel. If you just reboot now, it’s not gonna work.

(If you’ve done an MBR install with lilo, slackpkg will see that the kernel has been updated and re-run lilo(8) for you to update the MBR bootloader. You should be good-to-go. Update: Actually, I just did this on a machine with no EFI support and it did not do this automatically. The important thing to know is that the 'huge' kernel (default) does not need an init ramfs, so all you have to do after a kernel upgrade is run the command lilo. You can confirm that you’re running huge by checking what the symlink /boot/vmlinuz points to.)

Before you restart, all you’ve got to do is copy the new kernel and bootloader files to the EFI partition.

On your still-running system, that’s as simple as:

# cp -L /boot/vmlinuz          /boot/efi/EFI/Slackware/vmlinuz
# cp    /boot/elilo-x86_64.efi /boot/efi/EFI/Slackware/elilo.efi

A couple notes: The -L option tells cp to copy the linked file, not the symlink. Don’t just copy my commands without double-checking these filenames are correct for your system!

By default, you’ll continue to run the "huge" kernel (see where your symlinks point in /boot)! This does not require an initrd ramdisk image, so just the kernel and bootloader are needed, as shown above.

Continuing to use "huge" just works, so I stick with it. But be advised that doing this will cause people on the Internet to yell at you.

There are perfectly good reasons to use "generic" with the initrd. This looks like a great place to start learning why and how to do that:

Reboot and make sure everything works.

I log into my "dave" account now and do a startx to load up xfce again and make sure I can still surf the Web and that sort of thing before I invest any more time on customizing my setup.

Oops, the kernel won’t boot now

Dang, maybe you shouldn’t have followed me like a lemming right off this slackpkg kernel upgrade cliff. Sorry. At least it’s still just a new install, right?

Don’t despair yet! Put that USB stick back in to get back to a usable command line.

You can mount your new Slackware root and your EFI partition and examine them for any mistakes:

# mkdir /myroot
# mkdir /efi
# lsblk
# mount /dev/sda3 /myroot
# mount /dev/sda1 /efi
# ls /efi/EFI/Slackware

You can compare kernel and bootloader files with md5sum:

# md5sum /myroot/boot/vmlinuz-huge-5.15.80 /efi/EFI/Slackware/vmlinuz

If everything else looks good, you might have to downgrade the kernel. You can probably do it by getting the old packages from the USB stick and manually doing upgradepkg to downgrade them (upgradepkg also does downgrades because it trusts you and loves you).

But unless you know the exact combo of packages to get and how to perform a chroot or other equally arcane things, it’s probably faster just to reinstall. And then try other people’s instructions for properly upgrading the kernel safely!

Once you know what you’re doing, you can fly through the Slackware setup process (just walk away when it starts installing packages) in minutes.

Sbopkg (a helpful installer for!)

Okay, everything went great with the kernel upgrade and all of our packages are up to date.

Now I trust that I can invest the time in doing the rest of my personal setup.

I use to build and install packages for Slackware from the repository.

I download the pre-built package (Update this URL for the current version):

$ wget

Then I go superuser and copy this from my user home to root’s home and install the package.

$ sudo -i
# mv /home/dave/sbopkg-0.38...tgz .
# installpkg sbopkg-0.38...tgz

Update sbopkg and install some tools I can’t live without:

# sbopkg -r
# sbopkg -i the_silver_searcher
# sbopkg -i stow
# sbopkg -i dmenu

GNU Stow is used below. dmenu is used by dwm (both are Suckless tools), which is installed further below.

It’s not needed for any of these packages, but some slackbuilds have other slackbuilds as dependencies. sbopkg comes with a utility to create "queue file" for a package so that dependencies are recursively installed in the correct order for a package. Run sqg -p <package> to generate the queue file. Then, when you run sbopkg -i <package>, it will see the queue file and use it (with your permission).

Dotfiles and ~/bin

Note that I installed stow in the step above.

At this point, I’m performing the rest of my "dotfiles" install procedure from my Git/Stow setup as outlined more thoroughly in Personal Linux Setup with Git Repos and Stow. Here’s the quick version:

$ git clone phobos:repos/dotfiles.git
$ cd dotfiles
$ stow bash
$ stow git
$ stow vim
$ stow xinit
$ stow ssh

That last one, ssh, needs an additional fix for permissions. I made myself a silly little script in the directory to fix 'em:

$ cd ~/.ssh
$ ./

All of my home-grown scripts and utilities are in another repo. When installed in my home dir, they’re immediately available via $PATH:

$ git clone phobos:repos/bin.git

Vim also needs plugins installed (from 3rd party repositories). I put a note in ~.vimrc to remind myself how to do that.

By the way, all of this stuff is also documented in README files I’ve plastered all over my most important directories and personal repos. I find these READMEs (as well as my own website) to be invaluable resources when I’ve forgotten how to do things.

dwm (window manager) install and setup

I’m a big fan of this tiling window manager:

There is an entry for dwm on Slackbuilds, but I don’t use it because you customize dwm by editing the source and recompiling it!

So I’ve got my own repo. To put this on a new computer, I just do the same thing to get it from Phobos as I did for my dotfiles above:

git clone phobos:repos/dwm.git

Then I compile and "install" it and make a link from xfce’s excellent terminal to st. (The terminal command is hard-coded into dwm’s source. I could change that, of course, but symlinks let me swap out terminals at a whim or change them per-machine without changing my dwm settings.)

$ cd dwm
$ make
$ sudo cp dwm /usr/bin/
$ sudo ln -s /usr/bin/xfce4-terminal /usr/bin/st

(Note that in addition to st, dwm also expects to use dmenu to launch applications. I installed dmenu using sbopkg above.)

Then I reboot again (gotta shake out the bugs!), log in as "dave", and do a startx (the .xinitrc from my dotfiles starts dwm).

All is well and I’m happily slacking!

Browser 1: Firefox

Slackware ships with the ESR (Extended Support Release) version of Firefox but I, alas, am a Web developer. So I kinda need to be able to test with the latest version.

I use Ruario’s script to create a new Firefox Slackware package from the latest binary release from

(From the github gist, click the Raw button and save the script.)

# chmod +x
# ./
Slackware package <path> has been created.
# installpkg <path>

And just now reading the source, I see that there’s an auto-install option as well:

# ./ --install

This package will install Firefox to /usr/lib64/firefox-latest and a symlink the executable at /usr/bin/firefox.

To allow auto-updates, I set the group ownership to wheel (above, I put my regular user account in the wheel group) and give all of the files group write permission like so:

$ sudo chgrp -R /usr/lib64/firefox-latest
$ sudo chmod -R g+w /usr/lib64/firefox-latest

(Note that the -R option on both of the commands makes them recursively apply to files in the directory and any sub-directories.)

If you choose not to allow auto-updates, you’ll need to make a new Firefox package with the script and upgrade it with upgradepkg each time there’s an update. And Firefox will hound you about it until you do!

Browser 2: chrome

As for google chrome, I have to use it at work for testing. Slackware has an "official" package-maker in the extra/ directory:

The README there has instructions.

In brief: Download the .deb package from the chrome website. Then put the .deb file, slackbuild script, and description file in the same directory and run the script:

# ls

# chmod +x google-chrome.SlackBuild
# ./google-chrome.SlackBuild
Slackware package /tmp/google-chrome-<version>.txz created.

Install the package:

# installpkg /tmp/google-chrome-<version>.txz

If I’m on a non-work computer, I skip the chrome install and just use Firefox.


Slackware isn’t for everyone. But it’s right for me and if you have enough Yeti blood ( - the "slack" in "Slackware" - an essential ingredient of the Internet of the 1990s, folks!), it might be right for you.

I made this page because I’ve recently installed Slackware 15.0 on a whole bunch of computers and I have the whole process pretty fresh in my mind. These computers are going to quietly perform their duties without any problems for years and I am likely to start forgetting how some of this install stuff works (especially the EFI-related things).