Maximum PC

Building and Configurin­g

Assemble and pray to $DEITY for the happy beeps. Then install Debian

-

NOT THAT LONG AGO, we would have needed to spend a good page talking about hardware considerat­ions. Back then, hardware support was something of a minefield— here, we’ve squished it all into a box (below).

Things still aren’t perfect on Linux, but serious hardware incompatib­ilities tend to be reserved for laptops, so any issues you run into elsewhere are usually pretty minor and easily corrected. In theory, you could cobble any old bits together and make a server, but old components (particular­ly hard drives and power supplies) have a habit of breaking, and broken is generally not a good state for a server to be in. Further, when these components do break, replacemen­ts are often only available second-hand (and often at a vastly inflated price), so may not last long. Also, that 10-yearold IDE drive that’s been sitting on your desk all year is unlikely to be fast or capacious enough to be useful. Add to that the fact that old gubbins is inefficien­t, and tends to get hot and noisy (and nobody likes inefficien­cy, fires, or disturbanc­e), and our “perils of relying on old hardware” talk is done. By all means use spare parts that you have lying around, but only if you’re confident they will last.

We’re going to use Debian for our server, though all the packages we refer to are available on other distros, so you can use whatever you like. If you really must, this includes desktop distros, but we have no need of GUIs where we’re going. So things like Ubuntu Server, CentOS, or Arch Linux are more reasonable choices. We’re going to have a really simple partition set up for our OS drive— just an ext4 partition for the OS, and a swap partition— basically, what you get if you accept the defaults on a standard install. While some people would be tempted to do something more exotic, such as snapshots, rescue partitions, and LVM, we’re working on the theory that if the worst does happen, our configurat­ion will be easy to replicate with a fresh install. Backing up a couple of key configurat­ion files will make this process even easier.

Debian is easy to install—just grab the ISO (either the small Network Install, or the first CD from the install set) from www.debian.org, and away you go. You’re prompted to set a password for the root user—setting this to blank disables the root account and installs sudo, which you may prefer. You’ll certainly want at least one user account at this stage; others can be added as required (with draconian storage quotas, if you want to be that kind of sysadmin). The “Guided—use entire disk” option sets up an ext4 and a swap partition, which is all our server needs.

Once everything’s installed, reboot into the new system, and log in as root (or your user if you disabled the root account; we’ll use the # prompt to indicate commands that require sudo usage). It’s good practice to keep your server up to date, so our first act is to update package lists, and catch any last-minute upgrades:

# apt-get update # apt-get upgrade

 ??  ?? Our server, the wonderful services it will provide, and its place in the wider network.
Our server, the wonderful services it will provide, and its place in the wider network.
 ??  ?? This is the minimal Debian collection set we started with. The installati­on took up just over a gigabyte.
This is the minimal Debian collection set we started with. The installati­on took up just over a gigabyte.

Newspapers in English

Newspapers from United States