COMP 3000 2011 Report: SliTaz

From Soma-notes

Guidelines

-Text in bold within the text body is used to make commands, paths and programs used in SliTaz more apparent.
-The quick-launch menu will be referred as QLM within a path.

Part 1

Background

The Linux distribution that I have chosen is called Simple Light Incredible Temporary Autonomous Zone(SliTaz). It is developed by the SliTaz GNU/Linux Association with the main developer being Christophe Lincoln. The main goal of its developers was to create one of the smallest capable Operating system(OS) available today. SliTaz can be obtained here.

Being just about 30 megabytes(MB) and taking approximately 16 MB of Random-access memory(RAM), this distribution is perfect for use on older computers. As little as 16 MB of RAM is required, but is only recommended if SliTaz is installed on the hard disk. Otherwise, with the LiveCD, you will have to either use a text based interface, upgrade to 80 MB of RAM and use the "loram-slitaz" LiveCD version, or get 192 MB of RAM if you would like to use the default version. This is good news for people that would like to use their decade old computer as a web server or a secondary workstation for the family. Another useful application for this OS is to use it on netbooks; these machines often come with bloatware and an operating system that is too resource hungry for its own good, making the experience very slow and frustrating for the user. Finally, users that want to keep their working environment on a usb key would most definitely be interested in this piece of software. Although it has many similarities to Damn Small Linux, SliTaz decided to create a new distribution instead of building on older ones. It really makes sense when you think about it because the very nature of their goals forces the developers to design from the bottom up, making sure that every component is as small as possible. Building on another distribution makes this much more difficult.

Installation/Startup <ref name="SliTaz installation">SliTaz installation (2011, Nov. 28). Retrieved October 14, 2011 from http://doc.slitaz.org/en:handbook:installation</ref>

Running SliTaz for the first time

Steps :

1. Download the International Organization for Standardization(ISO) image here.
2. Burn the ISO image on a compact disk(CD).

I used Burn's burning software for Mac, but any should do. Burning an ISO file using this program is simply a matter of dragging/finding the file while in data mode. If you are a Windows user, CDBurnerXP is a popular and free burning program.

3. Reboot the computer.
4. Make sure that the boot order is configured properly in the basic input/output system (BIOS).

Here is a guide that shows how to do this.

5. SliTaz should now be asking you two questions: What language you would like SliTaz to boot in and which type of keyboard you would like to use. Answer them.
6. SliTaz is now fully booted.

If you don't waste any time, this whole process should take about 10 to 15 minutes. The boot itself is very fast but you still need to burn the ISO image onto a CD.

Installing SliTaz on a hard drive

SliTaz's default root password is "root". It might come in handy during the installation! These steps are done from the LiveCD.

Steps :

1. Create a new partition.

SliTaz includes a program called GParted for this purpose; you can access it by going in the quick-launch menu(the red ball in the lower left of the desktop) and navigating to System tools > GParted Partition Editor. It has a graphical interface which makes it very easy to use. To create the new partition, you have to :
1. Select an unallocated section of the disk.
2. In the menu, select Partition -> new partition or click on the New button.
3. Specify the desired size for the new partition. You can either use the slider or change the values directly.
4. Leave the default filesystem, since the installer will reformat the partition to third extended filesystem(ext3) anyway.
5. Click Add.
At this point, the partition has not been created yet; it is only in the operation queue. Do not forget the last step!
6. Click Apply.
The new partition has now been created.

2. In the quick launch menu, navigate to System tools > SliTaz Installer.
3. Choose <Install>.
4. If you remember the partition name, type it in and select <OK>. If you can't remember it, go see the list of available partitions by selecting <List>.
5. The installation will then ask you a few questions, such as the default root password and your account name. Answer them accordingly and then select <Yes> to start the installation.
6. When the installer asks you if you would like to install GRUB, choose <Yes> unless you already have a bootloader installed.

To add an OS entry to GRUB, you will have to find the file /boot/grub/menu.lst and add the correct lines for your OS. For example, I had to add these in order to boot in Windows:
title Windows 7
root (hd1,0)
savedefault
makeactive
map (hd0) (hd1)
map (hd1) (hd0)
chainloader +1
You can easily find the ones you have to use for your specific OS with a simple search on google.

And that is all there is to it! The whole process was very straightforward and I did not run into any problems.

SliTaz's initial boot screen

Since my new partition was 1.6 gigabytes and the file manager showed that only 1.3 gigabytes was left, I concluded that the whole installation took about 300 megabytes, which is very reasonable. All in all, I was very impressed with the speed and simplicity of the installation.

Basic Operation

As a programmer, there is some value in having an emergency development environment in case anything happens to your main computer, because it allows you to still meet some deadlines. SliTaz would be a very good candidate because of the fast installation process, the low system requirements and the flexibility offered by its package manager.

As a normal user, all of the mentioned properties are also advantageous because it allows me to use old computers and netbooks as perfectly acceptable recreational stations.


Scenario 1 : The deadline

The situation
I am a web developer and my computer just died on me. Fortunately, all my files are synchronized with a File Transfer Protocol(FTP) server, so no work is lost, but I still have a deadline to meet in 5 hours. I go downstairs to my 8 year old computer, on which I installed SliTaz, and turn it on. I program and design using PHP, Javascript, Hypertext Markup Language(HTML) and Cascading Style Sheets(CSS)

Getting my files back
I get to the desktop within 1 minute and immediately try to find the FTP client. I can't find it, so I open Midori, SliTaz's web browser, and browse to the OS' website. In the "About" section, it clearly says that an FTP client is included. Confused, I try to dig a little deeper and end up finding this page; turns out that I need to individually install some of the applications that serve specific purposes. After typing tazpkg get-install gftp in the terminal, I get a new application in the quick-launch menu under Internet called gFTP client. I open it, enter the correct values for the host, port, username and password, and download my files.

Programming
SliTaz's default code editor is called Beaver and is designed to be lightweight, fast and flexible. The fact that it supports syntax highlighting and proper tabbing is all I need to be able to code comfortably. If I ever need more, I know that I have the option of adding plugins.

Designing
Since I am also expected to design the sites that I develop, I need some kind of image editor. I check under the Graphics tab in the quick-launch menu and decide to try out mtPaint Image Editor. It is exactly what I need: a per pixel image editor with support for the Portable Network Graphic(PNG) format. Another program, Gcolor2, serves the purpose of choosing colors and getting their respective hexadecimal value. It was very useful when designing CSS styles.

Testing
Since I did not have time to set up a local testing environment, I decided that it would be better to upload the modified files to the server and test remotely. Since the only browser available in SliTaz is Midori, I had to download Firefox and Chrome in order to make sure that my code was compatible with every browser possible. Unfortunately, I had no way of testing under Internet Explorer.

Conclusion
Considering the urgency of the situation and the size of the OS, I must say that I was pretty impressed at how fast I could start working. Although it is not the most extensive development environment around, it has everything I need to do my work properly.


Scenario 2 : Party!

The situation
I would like to plan a huge party but my girlfriend needs the main computer for work, so I am stuck using the netbook, on which SliTaz is installed. I will need access to Facebook, Google Talk, Microsoft Messenger(MSN), and an Internet Relay Chat(IRC) client.

Setting up
I will be here for while so I should have some music to listen to. I have a Universal Serial Bus(USB) key which holds my music, but I need something to play it. I easily found an application called Alsaplayer Audio Player under QLM > Mutimedia, so I created my playlist and started listening to my music.

At this point, I had to find an IRC client and the required messengers so that I could contact all my friends. Under QLM > Internet, SliTaz already has an IRC client called LostIRC. When the application had finished loading, I immediately got asked which server I would like to join. I entered all the required information, join my friends' channel, and start chatting.

The Internet tab also had a menu item called Chat which, upon clicking it, would download a cross-platform, universal messenger named Pidgin. This was perfect since I had to be able to contact friends on both the Google Talk and MSN interfaces. After setting up my accounts, which simply involved entering my username and password for each service, I connected to both messengers and could start talking to everyone. The list of friends is initially sorted by the categories that you have specified within each service first, then in alphabetical order. This system is fine for me, but you can customize it to your liking if you wish to; friends are easily dragged and dropped between categories as if they were all part of the same service and you can choose to sort the list by status, recent log activity, or manually. As I did not have much time for customization, I simply went on with my invitation process.

For Facebook, I opened Midori, SliTaz's default browser. Midori's Wikipedia page mentions that it passes the Acid3 test, a webpage that determines a browser's compliance to the web standards. However, the Acid3 test was released in 2008, and therefore does not guarantee correct rendering of pages using new technology. As predicted, Facebook did not let Midori render its desktop targeted page and instead forced it to show the dumbed down mobile version, which I am not quite comfortable using. Fortunately, downloading Firefox is quite easy. And since it supports many of the latest standards, rendering Facebook's webpage should not be a problem.

A look at Midori's rendering of Facebook

A Look at Midori's rendering of Facebook

Logging the results
I needed to know how many people would be coming to my party so that I could estimate how much money it would cost as well as what type of food each person would eat. The obvious tool for this purpose is a spreadsheet, and SliTaz holds one by default. Residing in QLM > Office, Gnumeric is an open sourced spreadsheet aimed at becoming the best application possible, without copying other similar ones. From what I have seen, it does everything you would expect from a spreadsheet and therefore was completely suitable for my purpose.

Conclusion
Other than Midori's lack of support to newer standards, the whole process was pretty painless. It is my opinion that SliTaz is as good as any other OS for light usage such as surfing the Internet, chatting, etc.

Usage Evaluation

SliTaz is no doubt a very useful package because it starts very slim, an important trait to have when running on slow computers, but it can also easily scale up to the desired balance of speed, memory usage and utility. The package manager makes this process quick and simple, with the only inconvenience being that the packages' information must be maintained. If, however, an application cannot be found on it, there is nothing stopping you from downloading and installing it manually; it is a win-win situation.

The only thing that I would change would be the browser, simply because most other options out there are better. The opportunity cost of going with Firefox or Chrome is very minimal, if not relatively insignificant.

Being that the goal of this distribution was to make the smallest possible OS, I think that the developers have succeeded. Its small memory footprint makes it ideal for old computers and netbooks, while its fast boot time makes it a good contender in the "OS on a usb" market. While it is a good thing that SliTaz is only 30 megabytes, what makes it stand out is the thought that was put into the design, making sure that every feature was optimally minimal.

References

<references />

Part 2

Software packaging

The packaging software used by SliTaz is called Tazpkg. It is a lightweight package manager with a size of about 35 kilobytes and is built from scratch using SH's shell script (SHell script). The packages are archived in a format called "cpio" and are embedded with a filesystem. This "cpio" file format has been used almost universally in Unix and Linux based kernels since 1976 and is a good contender to "tar". Right now, Tazpkg contains approximately 2085 installable packages.

Before we can do anything with the package manager, we need to request a list of available packages. SliTaz includes a graphic interface that makes Tazpkg very easy to use. Simply opening the interface will give you this list. Double clicking on one of the entries will spawn a modal window containing information pertaining to the package, such as its version, category, size, website and receipt. The window also allows the user to choose between installing, downloading or viewing the content of the package. If the package is already installed, the option to install is replaced with the option to remove.

To install a package, choose the package that you want and click on the install button. It will automatically download and install the package, and will then be visible under its respective category in the quick-launch menu. To uninstall, select the package within the package manager and click on uninstall.

Major package versions

Linux kernel
SliTaz's version : 2.6.30.6
Age : 2 years, 2 months and 5 days
Latest version : 3.1.1, nov 11, 2011
Time between latest version and used version : 2 years, 2 months and 3 days
Source : http://www.kernel.org/pub/linux/kernel/

Modifications

According to SliTaz's release notes, the kernel was patched to support LZMA (Lempel-Ziv-Markov chain-Algorithm) compression and display correction for the virtual console. Only the minimal parts of the kernel are available but modules can be added by the user through the packaging system. This was done to ensure compatibility with a wide range of computers while keeping the distribution lean. In version 3.0, additional drivers were added to the kernel in order to speed up boot speed.

Speculations

I believe that Linux was chosen because of its high customizability, unparalleled stability through years of testing, and wide adoption by the community.

Being able to customize the kernel allows the developers to make it as lean and fast as possible while giving the end users the possibility to add new modules to fill their needs. In addition, Linux is one of the most stable operating systems because it has been tested for many years by a lot of different people. For the same reasons, a lot of documentation and help is available online which makes it much easier to fix potential problems. There is no doubt in my mind that using the Linux kernel was the right choice in this situation.


glibc
SliTaz version : 2.10.1
Age : 2 years, 5 months and 27 days
Latest release : 2.14, June 1, 2011
Time between latest version and used version : 2 years and 15 days
Source : http://ftp.gnu.org/gnu/libc/

Speculations

There is not much to say here. Pretty much every Linux distribution contains this library so it is not surprising that the SliTaz team decided to include it. It is one of the most complete c libraries out there.


X.Org
SliTaz version : 1.5.2
Age : 3 years, 1month and 3 days
Latest version : 1.11.2, nov 4 2011
Time between latest version and used version : 3 years and 25 days
Source : http://xorg.freedesktop.org/archive/individual/xserver/

Speculations

Xorg was introduced in SliTaz version 3.0 to replace Xvesa. The overall feeling that I got while researching both of them was that Xvesa is leaner than Xorg, but very limited in several aspects, such as video playback, refresh rate control and GLX compatibility. My hypothesis is that the SliTaz development team wanted to increase compatibility with a higher number of setups and was ready to sacrifice on size and resource allocation. It must be noted that Xvesa is still supported and that the only drawback to including Xorg is the increased size of the ISO. I definitely think that the advantages added by this move far outweigh the small bump in size of the operating system.


GTK+
SliTaz version : 2.16.5
Age : 2 years, 3 months and 26 days
Latest version : 3.2.2, sept 26, 2011
Time between latest version and used version : 2 years, 2 months and 8 days
Source : http://ftp.gnome.org/pub/GNOME/sources/gtk+/

Speculations

I think that GTK+ was chosen by the developers because it has much better potential than the competition for smaller applications. It does not need to pull in the whole GNOME framework and is the graphical backbone of most applications aimed at being lightweight, such as Abiword, Midori, GIMP and Pidgin. Given SliTaz's goal to be very small, it makes sense for it to use an environment that does not have a big footprint.


Busybox
SliTaz version : 1.12
Age : 3 years, 2 months and 24 days
Latest version : 1.19.2, sept 12, 2011
Time between latest version and used version : 3 years and 23 days
Source : http://busybox.net/downloads/

Speculations

Busybox was undoubtedly chosen because of its design philosophy, which is to work with systems that are very limited in resources. Again, this philosophy fits perfectly well with SliTaz's goal to be as lean as possible.


Tazpkg
SliTaz version : 3.2.2
Age : 1 year, 7 months and 17 days
Latest version : 3.2.2, March 28, 2010
Time between latest version and used version : 0 days
Source : Tazpkg is part of SliTaz and cannot be downloaded as a standalone application

Speculations

It is hard to say why they would want to write their own package manager given the relatively big amount of free ones out there. I assume that none of them could run on the barebone configuration that SliTaz provides considering that Tazpkg is completely written in SHell script. It is also said to work well with Busybox, ash shell(BSD-licensed replacement for Bourne Shell) and bash - another reason why they might have needed a custom package manager.


Midori
SliTaz version : 0.2.4
Age : 1 year, 6 months and 11 days
Latest version : 0.4.2, nov 11, 2011
Time between latest version and used version : 1 year, 6 months and 8 days
Source : http://archive.xfce.org/src/apps/midori/

Speculations

Midori is designed to be lightweight and fast. It uses the GTK+ 2 interface and renders the webpages using webkit, the same engine used by Safari and Google Chrome. All of these properties possessed by the browser go hand in hand with SliTaz's philosophy of being as small as possible without sacrificing on usability.


Pidgin
SliTaz version : 2.6.5
Age : 1 year, 3 months and 13 days
Latest version : 2.10.0
Time between latest version and used version : 1 year and 12 days
Source : http://sourceforge.net/projects/pidgin/files/Pidgin/

Speculations

For SliTaz to be a proper workstation, it needs to have the necessary applications to communicate through the internet. This is where Pidgin comes in handy. It is a multi-platform messenger which understands almost all the protocols used by popular messengers, such as MSN Messenger, Google Talk and Facebook chat. It uses the GTK+ interface and the fact that it supports all these protocols means that the OS does not need to include all the other applications.


Sqlite
SliTaz version : 3.6.16
Age : 2 years, 4 months and 17 days
Latest version : 3.7.9, November 1 2011
Time between latest version and used version : 2 years, 4 months and 4 days
Source : http://www.sqlite.org/download.html

Speculations

SliTaz would be a good candidate to build a webserver on an old machine which could be used, for example, by a web developer to test his work or by a small company to run its intranet application. Sqlite can be used for purposes that don't require a high volume of requests. Since SliTaz is designed to run on old, slow computers, it will not be used for high traffic websites and therefore will not need anything more complex than Sqlite. It is important to note that Sqlite has been shown to work flawlessly with websites getting up to 1 million requests per day.


Lua
SliTaz version : 5.1.4
Age : 3 years, 2 months and 27 days
Latest version : 5.1.4, August 18 2008
Time between latest version and used version : 0 days
Source : http://www.lua.org/ftp/

Speculations

Lua is a lightweight (150 kb) scripting language designed to be very extensible, which means that it can be used for pretty much any purpose. Given SliTaz's goal to be very slim, it makes sense to include a scripting language that can be customized by the users depending on their needs. The alternative would be to include many languages that fill different roles, but that would not be very practical.

Initialization

SliTaz does not use the usual initialization structure. Every script that must be run is specified in the $RUN_SCRIPTS variables and all deamons in the $RUN_DAEMONS variable. The initialization file /etc/init.d/rcS then uses the configuration file /etc/rcS to run the processes specified in the variables. This means that SliTaz does not use the runlevels to order the execution of the processes; instead, the boot order is specified in the script itself. The purpose of this is to centralize the main system boot initialization in one configuration file. Everything about the process is explained in /etc/init.d/README.

Here is a list of all running processes right after the booting process.

A look at Midori's rendering of Facebook


Daemons
Processes : udevd, syslogd, klogd, dbus-daemon, hald, hald-runner, hald-addon-input, hald-addon-storage, hald-addon-acpi, gam_server

Daemons are special processes that run in the background. They are not interactive and serve specific purposes such as logging(syslogd, klogd), event management(udevd), and device management(hald, dbus). Some daemons are more important than others, such as udevd, hald and dbus, that take part in providing an Application programming interface(API) to other processes. In other words, any process which communicates with the hardware through these APIs should be started after the mentioned daemons. Out of the three, udevd must be started first because it is responsible for hotplug events(hardware recognition), then dbus, a system used for inter-process commucations, and finally hald, the hardware abstraction layer.

User interface
Processes : Xorg, xterm, openbox, lxpanel

These are processes that allow users to effectively interact with the computer. Xorg is an open source software that serves as a hardware abstraction layer based on the X Window System. It was initially designed to create efficient and portable interfaces between terminals and servers running client applications. This client-server architecture is, however, also usable on a single computer and is therefore used by many operating systems as their basis for graphical interfaces. Operating systems use window managers in order to create a proper desktop environment by having a properly managed windows system. Openbox is one of those window managers and is based on the Xorg API. The process lxpanel is part of a bigger desktop environment, LXDE, also based on Xorg, and is used to manage SliTaz's quick-launch menu.

Utility processes
Processes : pcmanfm, gam_server, udhcpc, slim

These are processes that help make the user experience more efficient. They can include file managers, internet protocols, login managers, or any other software that may help the usability of the distribution. PCMan File Manager is the default file management system used by LXDE. It is detrimental for an OS to have such a system because dealing directly with the filesystem would be unmanageable. The process gam_server is a daemon associated with Gamin, a monitoring system for files and directories. It is used to change the state of the files' meta information whenever they are being used. Both of these processes work together to provide a meaningful way of working with the filesystem. Udhcpc is a lightweight Dynamic Host Configuration Protocol(DHCP) client and is necessary in order to communicate over most networks.

Analysis
As you can see, only the necessary processes for basic functionalities have been started. The first processes to be initialized are the daemons responsible for hardware management tasks, then processes that provide a basis for user interfaces, followed by the interfaces themselves, and finally the utility processes. This order is important because each layer is the basis for the one above it. This architecture is necessary in order to ease code portability, maximize code reuse and facilitate innovation. SliTaz is a very good example of this; the developers have only been able to achieve their goal because they could take advantage of modular design, giving the best options for their needs.