Slax - A small, complete and 'nice-looking' Linux live distribution

How can I learn how to use Linux? Simple, you grab a copy of any of the twelve thousands different 'distros' available out there, and you install it on your PC, hoping not to damage your existing Windows installation (if any). Or there's a more lazy and safe way, get one of the few dozens of 'Linux live CDs', burn the cd, boot from it, and you're all set...It's true, nowadays the best solutions for Linux newbies is trying out a few live CDs before installing the real deal on their machines: it's safe(r), takes less time and it's much more fun. Yes, some people may object saying that the fun in learning Linux is installing it on your hard drive first, but a few people I know who 'accidentally' overwrote their Master Boot Record or 'accidentally' damaged their Windows installation might disagree there...

A live distribution[1] basically is a CD (or DVD or USB drive) containing a fully working operating system - Linux in the specific - which can be run directly from the CD itself and does not require an hard disk installation. The drawback is that normally some part of the operating system are loaded and run from a ram disk and therefore the data written there will be erased once the system reboots. Due to the nature of CDs, saving data on the CD itself is obviously not possible, and this limitation can normally be bypassed by saving changes within a file to store either on your hard drive, remotely, or on some other media which allows read/writing like a floppy disk or USB stick.

Linux is well known for the many different distributions available, each with its own features, pros and cons. The same happens for live distros: in the last few years the number grew a lot[2] and nearly all major distributions now have a live counterpart, mostly to allow new users to preview their product.

The most famous, and possibly one of the first LiveCD ever made was Knoppix[3], a Debian[4]-based CD featuring a KDE[5] desktop environment and many useful applications squeezed into 700MB of space which can be used as a fully functional operating system. Add to this a truly impressive on-the-fly hardware detection ability, and there's the best (arguably) multi-purpose linux Live distribution ever made.
If Knoppix is "so perfect", why do other distributions exist at all? Well, some people noticed that they wanted to remove something from the collection of applications Knoppix included in the default CD, others wanted to add other bits, so soon a long list of Knoppix-based customized distros followed[6]...

This is another story, I'd like focus my attention on perhaps the most valid Knoppix-alternative out there: Slax[7].

Size vs. Features
Knoppix was the first Live CD I tried, but I didn't like one thing about it: its size. 700MB means one CD, and one CD means that I can't carry it in my pocket now can I? Not literally, anyway, at least not comfortably. So I started looking for a smaller alternative, and I found various possible candidates. Damn Small Linux[8] was one of the most extreme: 50MB in total, nothing more, nothing less, and it worked! Alright, I must say that now it's much better than it was when I first tried it but, it was more or less functional at the time (2003), although relatively new on the scene.
I liked it, really but, due to its size self-limitations the user interface wasn't too pretty, and the applications included weren't exactly what I was looking for: when you're used to Firefox (or better, Firebird, at the time) to browse the Net, Dillo[9] doesn't really look exactly appealing and feature-rich - although remarkable for its size.

I decided that I wanted something more than that, also because I was planning to burn the live-linux distro on a brand new (at the time) 8cm CD-RW with 180MB of space available. The best solution I could find, at the time and still now, perhaps, was Slackware Live CD, a very promising live distribution based on Slackware Linux[10].
I was very impressed at the time, especially for the effort the developer put to create a mini-distribution which is also user-friendly and nice-looking as well, incorporating the KDE Desktop. These are not the only strengths of the project, as we'll see in the next sections but, certainly the first thing everyone can notice.

After a while the project changed names and became "Slax", perhaps to create its own identity and expand itself following a different direction than its non-live predecessor: while the 'real' Slackware is often quite cautious on using latest technologies and normally includes stable packages, Slax does quite the opposite, including more recent applications and solutions.


Overview
Slax website[7] evolved quite a bit through the years, and now it's a true example of clarity and exhaustiveness. An essential clean design, access to a lot of information on how to use the live CD, solutions to common problems and also something for developers interested in creating their own live distro: the truly remarkable thing is that the biggest part of the work is done - apparently - by one single person, Tomas Matejicek[11], the founder of the project.

The strength of Slax - as I anticipated before - is perhaps its ability to compress a few carefully selected, commonly used applications which allow the user to fully enjoy his live experience in 177MB of space. Certainly the choice of using the K Desktop Environment instead of a more lightweight one like Fluxbox or Xfce may seem illogical, but for sure new Linux users would feel more "at home" with KDE, especially if coming from Windows XP. KDE is by far the most user friendly desktop environment available for Linux, and Slax made it even more user friendly by carefully organizing menus in an optimal way without cluttering the desktop with a myriad of icons and overly-crowded navigation bars.
When it comes to the applications included, Slax offers nearly everything the average desktop user needs: word processor (KWord), spreadsheet (KSpread), browser (Konqueror), multimedia player (Kplayer), editors, games and much more[26]! In its simplicity and especially for its size, Slax is a well-rounded, multi-purpose distribution. There's an interesting article available on tuxs.org[12] which documents the author's personal challenge of using only Slax (version 4.1.4 at the time) for a whole week. Surprisingly, the writer was really impressed of the features offered by this little distro: he was able to connect to the Net, browse the web, check his mail, write and do various other "everyday task", with no difficulty or extra hassle.

Slax is also very fast: normally some other live CDs compress the whole operating system on a single file, or a few, while Slax developed an optimized modular architecture: groups of programs or even single applications are compressed separately into .mo files: this technique sensibly increases the performance and speed of the operating system: whenever I open KWord, for example, to write an article, the OS will access just the KWord module on the disk, without touching other modules.
Surely there's a way to add/remove modules... - Yes, there is, and this will be discussed later on.

Finally, like various other live distros, Slax supports some handy "cheatcodes" which can be used to boot customize some options when booting the operating system.

Some of the most interesting codes include:


boot: slax webconfig=passphrase
boot: slax webconfig=ask

This is a recent feature: Slax allows users to save their settings remotely, directly on Slax server. Every user has to choose a 10+ characters password in order to use this feature[27].


boot: slax toram (just alias for copy2ram)
boot: slax copy2ram

This code can be used to copy the entire operating system to your computer's RAM: this may make the booting process slower, but Slax will run faster than light afterwards (256MB+ ram required)


boot: slax changes=/dev/device

Saves changes to a specified device using any linux filesystem, like a hard drive or a usb stick.


boot: slax load=module

Load optional modules stored in the /optional/ directory. For further information about modules, see the "Make your own!" section below.

For a full list of all Slax cheat codes, see the cheatcodes page[13] on Slax website.

Different flavors
I defined Slax a multi-purpose mini distribution, but as always different people have different needs: some users may want to be able to run some windows applications through Wine[14], for example, or may prefer a more lightweight Desktop Environment. The huge - and logical - limitation of all live CDs is that they normally don't offer the possibility of adding applications and packages: when the operating system starts the "root" partition is transferred onto a ramdrive which allows - even if until reboot - read/write access. Although this limitation can be overcome at least through using some of the cheatcodes described before, having the application already installed could be much easier.

That's why Slax developers decided to start creating different flavors of Slax. Some of them are not available at the moment (the current slax version at the time of writing is 5.0.6), and others can be already downloaded from the official site[15].

Slax "Kill Bill" - This is the first Slax customization which became available, and came out more or less at the same time as Tarantino's movie. Bill Gates didn't seem to mind at all, even if this version actually allows users to run some Windows applications like notepad on linux. Basically Wine[15] dosbox[16] and qemu[17] can make this possible, with limitations... nothing too exciting but, definitely fun to try out.


Slax "Server"
SLAX SRV is a pocket operating system with many internet services ready to use. Includes DNS, DHCP, SMB, HTTP, FTP, MySQL, SMTP, POP3, IMAP, SSH.

Unfortunately, this flavor of Slax is not yet available for download, but some updates concerning its status are available on the developer's TODO list[18]:

SE: mysql up and running
SE: httpd up and running, with PHP with MySQL
SE: DNS server up and running as a cache server
SE: DHCP server included but not started automatically, could confuse local network
SE: SSH server up and running
SE: MAIL server up and running, needs testing
SE: FTP server up and running


This is definitely going to be an interesting project, and I'm really looking forward to it. In the meantime, there are two server-oriented live distribution available, which is also based on Slax: Slampp[19] and in particular Slampp Lite[20]. I tried Slampp Lite and I was really satisfied with its features: support for PHP, Perl, Python on Apache (basically includes XAMPP for Linux[21]), xfce desktop environment, the latest Firefox browser, antivirus, firewall, and more.

Slax "Popcorn"
This Slax flavor is more minimalist, and substantially different from the Standard Edition. For a start it features the more lightweight xfce Desktop Environment[22], and thus removes all KDE-based applications making more room for Firefox browser and Abiword, which are not included in the Standard version due to the presence of their KDE counterparts (Konqueror and Kword).
Very fast, simple, and fits 128MB: suitable for small USB keys more than anything.

Slax "Frodo"
As the name implies, this version is smaller again (47MB), and it's basically the base for all other flavors as it includes just a Linux console and some scripts for hardware detection and setting up the live environment.

Make your own!
Nice! But I'd have included X instead of Y, then added Z as well, perhaps...
That's a common feeling: the truth is that people are never happy with what they get! If you're still not happy with what Slax in all its different flavors can offer you, well, you can make your own. Although some might want to start more or less from scratch, creating Slax-based customizations (this was the only option until the more recent versions), now there's an easier way: modules and the documentation present on the official site is complete enough and describes the necessary steps to take to create, modify and use them[23]. Modules are basically files with .mo extension containing an application which will be loaded by Slax at startup, if placed in the /modules/ directory, or only if required by the user (see the corresponding cheatcode) if placed in the /optional/ directory. The easiest way to create a module which requires no particular skill is converting a Slackware package, by issuing this command:

tgz2mo application.tgz application.mo

Of course there are other ways to create modules without converting Slackware packages, further details in the documentation[23]. There are also a lot (currently 576!) of user-contributed modules ready for use available for download and hosted on the Slax site[24], the only problem is that inevitably some of them seem to be out-of-date, and not constantly updated by their maintainers.

Last but not least, the dream of all Windows users: MySlax Creator and MySlax Modulator[25], which allow Windows users to create their own Slax distribution with custom modules both for CD and USB drive and create Slax modules on windows respectively. Two really nice additions which make this project even more (Windows-)user-friendly!

Conclusions
Slax is exactly how advertised on its website: "[a] fast and beautiful Linux operating system which fits on small (3.14") CD-ROM disc", nothing more, nothing less. Personally, I'd like to emphasize its user-friendliness, as it seems the most valid alternative to Knoppix, and perhaps even better: it does not include as many applications as possible which could confuse Linux neophytes but, just a bunch of useful programs for everyday use to give users a taste of what Linux is capable to do.
Normally, as Slax is mostly maintained by one person, Slax releases are not too frequent: normally 2-3 per year maximum. The version which was tested for this article was the 5.0.6 and (un)luckily a new one just came out while I was writing the article: version 5.0.7b is now available for download[15] and features KDE 3.5. A few bugs were discovered immediately after its released and quickly fixed with a patch-module (hence the "b"): This YOUR chance to try it out before I do...

Happy Slaxing!


[1]Linux Live CD - Wikipedia: http://en.wikipedia.org/wiki/Linux_live_cd
[2]DrozenTech's LiveCD List: http://www.frozentech.com/content/livecd.php
[3]Knoppix Official Site: http://www.knoppix.org/
[4]Debian Official Site: http://www.debian.org/
[5]K Desktop Environment: http://www.kde.org/
[6]Knoppix Customizations: http://www.knoppix.net/wiki/Knoppix_Customisations
[7]Slax Live CD: http://slax.linux-live.org
[8]Damn Small Linux - Official Page: http://www.damnsmalllinux.org/
[9]Dillo Browser, Official Page: http://www.dillo.org/
[10]Slackware Linux, Official Page: http://www.slackware.com/
[11]Slax - Developer's page: http://slax.linux-live.org/credits.php
[12]Barney Matthews, "A week with Slax 4.1.4" - Tuxs.org: http://www.tuxs.org/slax.htm
[13]Slax cheatcodes: http://slax.linux-live.org/cheatcodes.php
[14]Wine HQ: http://www.winehq.com/
[15]Slax download page: http://slax.linux-live.org/download.php
[16]Dosbox Project: http://dosbox.sourceforge.net/news.php?show_news=1
[17]Qemu Project: http://fabrice.bellard.free.fr/qemu/
[18]Slax TODO list: http://slax.linux-live.org/todo.php
[19]Slampp Official Page: http://slampp.abangadek.com/wiki/wikka.php?wakka=HomePage
[20]Slampp Lite page: http://slampp.abangadek.com/wiki/wikka.php?wakka=SlamppLite
[21]XAMPP for Linux: http://www.apachefriends.org/en/xampp-linux.html
[22]Xfce desktop environment, official page: http://www.xfce.org
[23]Slax Documentation - Modules: http://slax.linux-live.org/doc_modules.php
[24]Slax modules page: http://slax.linux-live.org/modules.php
[25]MySlax Projects: http://myslax.bonsonno.org/
[26]Slax - installed packages: http://slax.linux-live.org/installed_packages.txt
[27]Slax - Webconfig: http://slax.linux-live.org/webconfig.php