Arch Linux for the DIY Linux user

691

Author: Mayank Sharma

There’s no dearth of Linux distributions for desktop users or even for running high availability servers. But if you are a do-it-yourself computer user, your choice of Linux distros is fairly limited. You can build Linux from scratch with Linux from Scratch or compile your own set of packages with Gentoo. But if you want a distro that teaches you the basics of Linux as you set it up; is well documented, lightweight, and zippy; and has a dependency-resolving packaging system, you need Arch Linux.

Modern desktop Linux distros hide all the configuration bits behind easy-to-navigate menus and auto-resolving package managers. Old-timers might consider them bloated or resource hogs, but they are popular thanks to good bandwidth, cheap hardware, and the lack of time people have to fine-tune their systems.

Arch Linux is a great mix of the old and the new. From the golden days of Linux, Arch inherits the ability to fine-tune, tweak, and run a customized system, and from the modern era it takes its auto-resolving binary package manager. With an active user and contributor community, what you get is a system that’s completely under your control, doesn’t eat your whole weekend setting it up, and sports a package manager designed to keep you on the bleeding edge of free and open source software.

Exploring Arch Linux 2008.06

The latest Arch Linux version, released last month, is available both as a traditional ISO image and a USB image — both about 300MB in size. If your BIOS allows booting off USB devices, you can use the dd command to transfer the USB image to a USB disk and install using that.

Arch Linux doesn’t have a fancy graphical install interface. You even have to partition your disks using the command-line cfdisk utility, although there is an “auto prepare” option that will erase your disk and partition it into four partitions (/boot, swap, /, and /home). Arch Linux 2008.06 bundles its online beginner’s installation guide under /arch/beginnersguide.txt and a detailed installation guide under /arch/arch-install-guide.txt.

Once the partitions are prepared, the next task is to select packages to install. Unlike a traditional desktop Linux installation, packages in Arch Linux are divided into two categories: Base packages, which are always installed, include the kernel, shell, and bootloader, and the optional Devel packages, which include the GNU toolchain — GCC, autoconf, automake, and so on. In addition to letting you select these package categories, the install procedure lets you choose additional packages by displaying the full list of packages it bundles.

Arch is known for its Pacman package manager, and Pacman comes into play just before your selection of package categories is installed. The installer prompts whether you wish to keep the packages in the Pacman cache. If you choose to do so, you can downgrade packages to previous versions if a new version causes problems or conflicts with other packages.

Installing the packages shouldn’t take much time, irrespective of your system configuration and package selection, since there’s hardly anything to install. Once the install is done you won’t see an easy-to-use post-install account creation screen or a customized login manager, or even a splash screen. Instead, in tune with Arch’s transparent nature, you get a screen full of configuration files that you have to review, tweak, and modify to suit your system and network configuration.

It really isn’t as daunting a task as it sounds. Arch has a BSD-style init system, which means it uses a single /etc/rc.conf file that controls all its basic system configuration: keyboard layout, network configuration, modules to load, daemons to start, and so forth. Additionally, unlike the System V init system, Arch houses all daemons under a single /etc/rc.d directory regardless of runlevels. Also, the configuration files are fairly well documented with comments.

I modified the rc.conf file to make Arch Linux pick up my network details via DHCP instead of using the default fixed IP address. I also commented out the entries for the optical drive in the /etc/fstab file, as suggested in the beginner’s guide, since I wanted the hardware abstraction layer to handle removable media.

You can set a hostname in the /etc/hosts file and configure which hosts to allow or deny with their respective files. Finally, set a root password and configure the bootloader before exiting the setup.

Expanding Arch

When you’re done installing Arch Linux 2008.06 you don’t get a full-blown graphical desktop environment. All you get is a solid base and tools to build your own system. The advantage of this approach is that you can tailor your system from the ground up, in contrast to a traditional distro, wherein you’d get a standard set of packages and have to chop off the excess. Arch lets you avoid surrendering package selection to the distribution vendor.

With Arch, if you want just a Web server, you can install Apache and the other components and libraries that you need, and leave out desktop-related stuff. If you want to use your Arch computer as a jukebox, add MPlayer and a codec package that plays most popular formats, and leave out the rest. If you want to use Arch as your daily-use bleeding-edge desktop, install the latest KDE, 3-D compositing manager, and your favorite desktop applications.

Once again, this might sound daunting, but thanks to Pacman it really isn’t. The install guide covers installing everything from an ALSA sound server to the X server to your favorite desktop environments. There’s really nothing to it. For example, the command pacman -S firefox mplayer mplayer-plugin codecs flashplugin will install the latest Firefox browser, along with the Flash plugin, and the audio/video player MPlayer and its browser plugin along with codecs. Since Arch Linux is a rolling release, which means its releases aren’t separated into different branches or versions and new packages are simply added to the existing repository, you can update the entire system with a simple pacman -Syu command.

I installed Arch Linux both via a CD-ROM and one of its FTP mirrors on a 2.0GHz E4400 Core 2 Duo desktop with 1GB RAM and a wired Ethernet card. The network adapter was detected and configured via DHCP. After installing the base packages I followed the install guide to setup a basic Xfce system and then one with KDEmod, a modular and tweaked version of KDE optimized for Arch Linux. I installed the unstable branch of KDEmod, which is based on KDE 4.1.

The best thing about Pacman is that it installs only what I ask it to. For example, it allows me the freedom to install just the KSnapshot program instead of the complete KDE graphics package. So I not only end up saving disk space, but also get bloat-free, ligtening-fast performance. The Arch Linux 2008.06 install boots and drops me to the KDE desktop in less than 20 seconds, and all apps launch almost instantaneously.

Conclusion

Arch Linux is a distro designed for users who like to be in control of what apps are installed on their systems. Unlike other distros with similar objectives, Arch doesn’t sacrifice ease of use completely. It uses BSD-style init scripts, which eases configuration tasks, and a dependency-resolving package manager that helps keep the system updated. All in all, Arch is a nice distro for users who wish to learn about Linux and mold their Linux systems without breaking into a sweat.

Categories:

  • Reviews
  • Linux
  • Distributions