Saturday, September 30, 2006

Why is Linux still unknown?


We've recently celebrated Linux's 15th birthday. Nothing like first billion of users, or highly improved wireless support. No-thing. Imagine a birthday without gifts - It isn't nice by far. Compare this to Windows' 20th last year - there already was a hype about Vista, even if it only comes two years later. But we're not going to talk about Windows™ and make comparisons. We've to focus on Linux!

Bad startup

Linux was a toy at the beginning, a toy of Linus Torvalds', who's just started exploring the whole new Intel 386. Now pick up your fantasy, and imagine you're a beginner and are reading a book about Linux. First paragraph tells you that Linux was initially written by a rookie (an 386 rookie, I mean - no offense Mr. Torvalds) - does it sound good? No, for goodness sake! Here (so not two chapters later, when the reader is getting bored) should always be mentioned that Linux's gone through major changes, and it's totally been rewritten since v. 0.01. Also should be mentioned that Linux tried to meet the latest technology from the first line of code. Frankly, I haven't seen any description which describes it that way.
And do not believe I'm just a poor mortal. Nope, nope! I came from the Andromeda galaxy few millions years ago, and arranged the terrain for men.. (really, I have to laugh when those goofy scientists say dinosaurs were killed by a meteor) And I can also read minds, yours too. I see your brain changing color randomly every millisecond (yeah, my MindReader'95 track milliseconds, and then I replay it slowly), thinking about BSD's startup. It was okay, the problems appeared later, and still continue, in form of letters, where maintainers admit that their projects suck (see NetBSD).

Word of mouth is killiiiin' me! Help!

Ask a Linux user "What is Linux?"! The average reply:
- Well, Linux is a great thing, ya know.. it's the best alternative to Windows™ around.. and it has alternatives to all Windows software, except gaming.. Oh, and I almost forgot, Linux is all about customization.

Let's analyze this answer:
"best alternative": Frankly, Linux should not be treated as an alternative. Does Microsoft treat Windows CE an alternative for wireless devices? Hell, no!
Solution:Linux is a full-featured operating system, which lets you do everything, guess what, in an even cooler manner.
"it has alternatives": Same problem. Linux doesn't have alternatives. It just rules.
Solution: Linux has dozens of software, which lets you do everything the way you want!
"all about customization": this sounds like "Beware, once you've got your Linux thing, you'll have to dive in the command line, and configure it!". Is the command line friendly? Well, some more experienced users say it's user friendly, but it's not ignorant-friendly. That's it. Linux is not widely used because many user ignore it. Why? Because it's presented to the users as a dark tunnel, a mysterious room, an unfriendly operating system.
Solution: Linux is easy-to-use, once it's installed on your computer it's ready to go: you can surf the net, listen to music and play. Also, if you'd like to fine-tune something, you're in the right place - there's nothing better for customization than Linux.

Second question to the experienced user: "I need an office suite.."
Typical answer: Well, there's Basically you can do anything in it, and it also supports alternative formats.
User: Does it run on my old Pentium II?
Answer: Well, not really. It uses Java too, which is a known memory hog.

Let us solve this one too:
"not really": OpenOffice doesn't use Java to make a carriage return, or to print a page. It uses it for complex things.
Solution: For typical home usage, you'll probably won't meet any problems, but since OpenOffice uses Java (which Virtual Machine consumes a lot of memory) for some more advanced features, you'll probably have to wait until a certain operation completes.. But don't forget, the more, the better.

Have it your way!®

Linux? Er, you probably mean distributions, right? Well, that's another problem too. When one asks what distribution should she choose, the experts tell her that it depends of her taste, what she wants, and in most cases that's all. Newbies don't have a taste, maybe doesn't even know what she really wants.
There shouldn't be thousands of distros, clones of each other, and everybody shouldn't make a new distro which can't offer anything new.
Solution: Look ma, you have distribution X, if you want entertainment. You have distribution Y for office work, and distribution Y for development. Oh, and of course, you have distribution XYZ if you want everything at the same time, but that is a bit slower - you have to sacrifice some memory and processing time if you want everything at the same time. If you're ready to customize, you have distribution Q, which is really basic, but it'll become your best friend once it's ready.


The problem isn't Linux, as many state - nowadays we have Ubuntu, SUSE, between others, so Linux is accessible for everyone now. Users just don't dare to switch to it, because it's bad marketing model. Linux guys should encourage people to try Linux, and possibly remain using it!

Sunday, May 07, 2006

Linux's boot process explained

Short history of the UNIX operating system

Linux is an implementation of the UNIX operating system concept. UNIX was derived from AT&T's "Sys V" (System 5). The initialization process is meant to control the starting and ending of services and/or daemons in a system, and permits different start-up configurations on different execution levels ("run levels").
Some Linux distribution, like SlackWare, use the BSD init system, developed at the University of California, Berkeley.
Sys V uses a much more complex set of command files and directives to determine which services are available at different levels of execution, than the BSD's do.

Booting the Linux operating system

The first thing a computer does on start-up is a primer test (POST - Power On Self Test). This way several devices are tested, including the processor, memory, graphics card and the keyboard. Here is tested the boot medium (hard disk, floppy unit, CD-ROMs). After POST, the loader from a ROM loads the boot sector, which in turn loads the operating system from the active partition.
The boot blocks is always at the same place: track 0, cylinder 0, head 0 of the device from which we're booting. This block contains a program called loader, which in Linux's case is LiLo (Linux Loader), or Grub (GNU Grub Unified Boot Loader), which actually boots the operating system. These loaders in Linux , in case of a multi-boot configuration (more operating systems on a computer), permit the selection of the operating system to be booted. Lilo and Grub are installed or at the MBR (Master Boot Record), or at the first sector of the active partition.
In the following we will refer to LiLO as boot loader. This is usually installed in the boot sector, also known as MBR. If the user decides to boot Linux, LiLo will try to load the kernel. Now I will present step-by-step LiLo's attempt to load the operating system.

1. In case of a multi-boot config, LiLo permits the user two choose an operating system from the menu. The LiLo settings are stored at /etc/lilo.conf. System administrators use this file for a very detailed finement of the loader. Here can be manually set what operating systems are installed, as well as the method for loading any of them. If on the computer there is only Linux, LiLo can be set to load directly the kernel, and skip the selection menu.

2. The Linux kernel is compressed, and contains a small bit, which will decompress it. Immediately after the first step begins the decompression and the loading of the kernel.

3. If the kernel detects that your graphics card supports more complex text modes, Linux allows the usage of them - this can be specified or during the recompilation of the kernel, or right inside Lilo, or other program, like rdev.

4. The kernel verifies hardware configuration (floppy drive, hard disk, network adapters, etc) and configures the drivers for the system. During this operation, several informative messages are shown to the user.

5. The kernel tries to mount the file system and the system files. The location of system files is configurable during recompilation, or with other programs - LiLo and rdev. The file system type is automatically detected. The most used file systems on Linux are ext2 and ext3. If the mount fails, a so-called kernel panic will occur, and the system will "freeze".
System files are usually mounted in read-only mode, to permit a verification of them during the mount. This verification isn't indicated if the files were mounted in read-write mode.

6. After these steps, the kernel will start init, which will become process number 1, and will start the rest of the system.

The init process

It's Linux's first process, and parent of all the other processes. This process is the first running process on any Linux/UNIX system, and is started directly by the kernel. It is what loads the rest of the system, and always has a PID of 1.

The initialization files in /etc/inittab

First time the initialization process (init) examines the file /etc/inittab to determine what processes have to be launched after. This file provides init information on runlevels, and on what process should be launched on each runlevel.
After that, init looks up the first line with a sysinit (system initialization) action and executes the specified command file, in this case /etc/rc.d/rc.sysinit. After the execution of the scripts in /etc/rc.d/rc.sysinit, init starts to launch the processes associated with the initial runlevel.
The next few lines in /etc/inittab are specific to the different execution (run-) levels. Every line runs as a single script (/etc/rc.d/rc), which has a number from 1 to 6 as argument to specify the runlevel.
The most used action in /etc/inittab is wait, which means init executes the command file for a specified runlevel, and then waits until that level is terminated.

The files in /etc/rc.d/rc.sysinit

The commands defined in /etc/inittab are executed only once, by the init process, every time when the operating system boots. Usually these scripts are running as a succession of commands, and usually realise the following:

1. Determine whether the system takes part of a network, depending on the content of /etc/sysconfig/network

2. Mount /proc, the file system used in Linux to determine the state of the diverse processes.

3. Set the system time in fuction to the BIOS settings, as well as realises other settings (setting of time zone, etc), stabilized and configured during the installation of the system.

4. Enables virtual memory, activating and mounting the swap partition, specified in /etc/fstab (File System Table)

5. Sets the host name for the network and system wide authentication, like NIS (Network Information Service), NIS+ (an improved version of NIS), and so on.

6. Verifies the root fily system, and if no problems, mounts it.

7. Verifies the other file systems specified in /etc/fstab.

8. Identifies, if case of, special routines used by the operating system to recognize installed hardware to configure Plug'n'Play devices, and to activate other prime devices, like the sound card, for example.

9. Verifies the state of special disk devices, like RAID (Redundant Array of Inexpensive Disks)

10. Mounts all the specified file systems in /etc/fstab.

11. Executes other system-specific tasks.

The /etc/rc.d/init.d directory

The directory /etc/rc.d/init.d contains all the commands which start or stop services which are associated with all the execution levels.
All the files in /etc/rc.d/init.d have a short name which describes the services to which they're associated. For example, /etc/rc.d/init.d/amd starts and stops the auto mount daemon, which mounts the NFS host and devices anytime when needed.

The login process

After the init process executes all the commands, files and scripts, the last few processes are the /sbin/mingetty ones, which shows the banner and log-in message of the distribution you have installed. The system is loaded and prepared so the user could log in.

Linux's execution levels

The execution levels represent the mode in which the computer operates. They are defined by a set of available services at any time they are started. The execution levels represent different ways Linux uses to be available to you, the user, or eventually the administrator.
As daily user you don't have to bother with the execution levels, although the multi-user level makes the services which you need while using Linux in a network (though in a transparent mode) available.
In the next few sentences I'll present the execution levels, one by one:

0: Halt (stops all running processes and executes shutdown)

1: Known under the name "Single-user mode". In this case the system runs with a reduced set of services and daemons. The root file system is mounted read-only. This runlevel is used when the others fail while booting.

2: On this level run the most of the services, with the exception of network services (httpd, named, nfs, etc). This execution level is ideal for the debug of network services, keeping the file system shared.

3: Complete multi-user mode, with network support enabled.

4: Unused, in most of the distributions. In Slackware this level is equivalent with 3, the only difference is that this has graphic login enabled.

5: Complete multi-user mode, with network and graphic subsystem support enabled.

6: Reboot. Stops all running processes and reboots the system to the initial execution level.

Modification of execution levels

The most used facility of init, and maybe the most confusing one, is the ability to move from an execution level to an other.
The system boots into a runlevel specified in /etc/inittab, or to a level specified at the LiLo prompt. To change the execution level, use the command init. For example, to change the execution level to 3, type
init 3

This stops most of the processes and takes the system into a multi-user mode with networking enabled. Attention, changing the init level might force several daemons used at the moment to stop!

The directories of execution levels

Every execution level has a directory with a symbolic links (symlinks) pointing to the corresponding scripts in /etc/rc.d/init.d. These directories are:


The name of the symlinks are semnificative. It specifies which service has to be stopped, started and when. The links starting with an "S" are programmed to start in various execution levels. The links also have a number in their name (01-99). Now some examples of symlinks in the directory /etc/rc.d/rc2.d:

K20nfs -> ../init.d/nfs
K50inet -> ../init.d/inet
S60lpd -> ../init.d/lpd
S80sendmail -> ../init.d/sendmail

When operating systems change the execution level, init compares the list of the terminated processes (links which start with "K") from the directory of the current execution level with the list of processes which have to be started (starting with "S"), found in the destination directory.


When the system boots into runlevel 3, will execute all the corresponding links starting with "S", in an order accorind to their number:

/etc/rc.d/rc3.d/S60lpd start
/etc/rc.d/rc3.d/S80sendmail start
(and so on)

If the system now changes to runlevel 1, will execute:

/etc/rc.d/rc3.d/K20nfs stop
/etc/rc.d/rc3.d/K50inet stop
(presuming that nfs and inet are NOT in /etc/rc.d/rc1.d)

After that it will start all the processes mentioned in /etc/rc.d/rc1.d except which are already running. In this example there's a single one only:


Changing the current execution level

To change the current execution level for example to level 3, edit /etc/inittab in a text editor, and edit the following line:


(do not change the initial runlevel to 0 or 6!)

Booting into an alternative execution level

At the LiLo prompt you have to write the number of the wanted execution level, before booting the operating system. This way to boot into the third level, type for example:

linux 3

Eliminating a service from an execution level

To disable a service from a runlevel, you might simply delete or modify the corresponding symlink.
For example, to disable pcmcia, and don't start in the future, type:

rm /etc/rc.d/rc3.d/S45pcmcia

Adding a service to an execution level

To add a service, it is needed to create a symlink pointing to the corresponding scripts in /etc/rc.d/init.d. After the symlink is created, be sure to assign it a number, so it would be started in the right time:

To add "lpd" to runlevel 3, type:

ln -s /etc/rc.d/init.d/lpd /etc/rc.d/rc3.d/S64lpd

P.S.: This article has been originally written by Ovidiu T. He gave me the permission to translate and publish it, and since I found the article interesting, I did that way as well, although I don't treat myself responsible about the content of it.

Saturday, May 06, 2006

Sebastian Trueg @ K3B interview

I saw the success of my MPlayer review, and I looked for another open-source project, which developers I should interview. The first name came to my mind was "K3B". I dropped the maintainer a mail, and today evening we were ready. So who's the guy on the picture on the left?

Sebastian Trueg - K3B project founder, maintainer, and main programmer

Me: Please introduce yourself!

Trueg: I live in Freiburg, Germany since I moved here from northern germany for my studies of computer science which I finished this year. :)

Me: I bet you were among the first students.

Trueg: Not really. I never attended that much lessons but I am quite happy with my final score. And it could not have been that bad becasue my prof offered me a job and the opportunity to make my PhD. so at the moment I am employed at the University of Freiburg.

Me: When did you start the K3B project? Why?

Trueg: K3b, well here comes the main reason for me not being among the best students... I started working on K3b in 1998, shortly after I arrived in Freiburg, and A LOT OF TIME was spent on K3b, at times way more than on my studies. The reason for K3b... Well, when I came to Freiburg I had never tried a linux system and didn't know anything about it. A friend gave me, I think it was SuSE 5.something. I gave it a try, but at the time I was not too interested. Some time later I tried again, became curious to see if I could perform all the tasks I use a computer for on a linux system. To be honest: it were not that many tasks. ;) CD-burning was one of them, especially MP3->Audio CD. And that's when it started. There was simply no program around which satified my needs. You either had to use cdrecord on the command line or do the exact same thing in xcdroast (which was a real front-end, nothing more). I wanted to burn mp3 files to an audio cd without converting them beforehand, so I thought: "Well, try it yourself!". I had never programmed something this big but I was eager to learn so I started and it went quite well (mainly becasue of the good QT/KDE documentation). At some point (I don't think the first version of K3b could actually burn mp3 files on-the-fly...) I heard of sourceforge and put it online. The response was incredible, I had never thought that this many people would use my program... the rest is history :)

Me: How much time do you invest in developing K3B?

Trueg: Hard to say. There were times when I worked on it every day for many hours, but there was also a year in which I did nothing at all (that's the reason for the 500+ open bugs on :) At the moment I do not have that much time for K3b since I work full time at the university, but I hope that I will find a way to tend to K3b more often in the future.

Me: What is your favourite feature in K3B?

Trueg: Well, my favorite feature. There is, of course, the audio decoding which is nicely integrated using the plugin structure. Since it was the main reason I started K3b it is one of my favorite features since it works so well (IMHO). But then there is one thing in K3b which you don't fin in any other burning app (at least I know of none): the "auto" modes which I try to implement for as many things as possible. There is the auto-writing mode selection, the auto-multisession-mode selection, the auto-data-mode selection (for data cds). I think that's a very cool feature becasue it allows K3b to provide the parameters for advanced users on the one hand while being simple for beginners on the other hand. Oh, yeah, CD-Copy for multisession CDs. I don't think there are that many applications that do that. :)

Me: Speaking of other applications, have you ever tried any other CD-burning software except the mentioned XCdRoast and cdrecord?

Trueg: I knew Nero from Windows. It was my reference which probably shows... I tried KCDsomething, Arson, CDBakeoven, and GnoeToaster, but all of them did not get very far. At least Arson and CDBakeoven seem to be dead.

Me: Do you fear NeroLinux? I mean, do you treat it as a powerful competitor, or trust in the open source community which tends to use mainly open source software (and Nero isn't open-source).

Trueg: I do not trust in all linux users to use open-source. They will use what works best. I do fear NeroLinux a little. For the time being they do not put very much effort in NeroLinux, but that might change and if that day comes I might have a problem... But for now NeroLinux is far from being as powerful as K3b, (which I only know from feature descriptions since it never finds any devices on my system..)

Me: You had a fundraiser.. What success have you had?

Trueg: Incredible! Awesome! I set out to raise 1000 euros and was not sure at all if I would get that far... But the community prooved me wrong: within two days! the goal of 1000 euros was reached and by the end of the fund-raiser I received nearly 5000 euros. It was such a great feeling to be appriciated in such a way. The reson I started the fund-raiser was a new computer system. With that kind of money I was able to get a really cool one: a silent PC which does not make a sound (except if you put your ear to it you may hear the harddisk spinning). Most of the money came from private users, but I received two big donations from Mandriva and Linspire. I have to say that I had never dared to dream about such a success.

Me: At the announcement of the fundraiser, you promised K3B 1.0 as a "reward". Are you planning to release it soon, or it needs some more work?

Trueg: I am planning on releasing a preview soon. K3b 1.0 is almost feature-complete but there are still some quirks to work out. I am planning on releasing a preview soon. K3b 1.0 is almost feature-complete but there are still some quirks to work out. Data Project verification has been an issue for many years and I did not get it right yet. And I'd like to close most of the bugs on before releasing k3b 1.0 final. But it's not that far away. :) K3b 1.0, that is. I hope to release the first preview by the end of May, but who knows...

Me: There were some gossips about porting KDElibs to Windows. Will you release a Windows version if that will need some extra coding to do (or will you anyways release a Windows version)?

Trueg: I never had any plans for a Windows version. If anyone is interested in porting K3b, be my guest. I don't know if it would be that hard, probably there is only one file which needs to be changed (as was done for the FreeBSD port) and that is k3bscsicommand.cpp. Well, of course one had to have the kdelibs installed on the Windows system...

Me: What would you like to transmit to the OSS community, in particular to my readers?

Trueg: Well, especially after the fund-raiser I think the OSS community is an incredible bunch. ;) I find it astonishing how this many different people come together and create something with (mostly) only one reward: compliments. The free distribution of knowledge and the impact that this distribution has on the world (even the commercial one) is just incredible. I really hope that I can be a part of it for a long time to come and there is one thing I missed up to now: I've never met any of "the big guys" in person. I've never attended any of the KDE meetings and such. I really have to change that. As for your readers: support Open-Source. Install latest versions and help out where ever you can. :)

Me: Thank you for the interview, for your time spent with me. I wish you success in life and with your project!

Trueg: Thanks a lot. It was a pleasure!

Thursday, May 04, 2006

Gentoo GNU/Linux - Speed, Stability, Reliability.

I guess most of those, who are familiar with linux already heard of the fierce beast, which seeks for its prey in the Linux jungle, the Gentoo GNU/Linux distribution. Despite of what most of the people think, Gentoo is not about building everything from source, optimization flags, and text-mode installation.
What really defines Gentoo is the philosophy behind it, the idea of letting the user make the choice. Yepp, that's great isn't it? But what does it mean? Basically, it means that one can customize his/her system as she/he wishes -- Using Gentoo, noone will ever force you to share someone else's concept (and this includes the developer too) of how a Linux system should look like, that is you are free to decide which and how many programs you will use, what features should they contain, what architectures should they support, etc.

As far as I know, the newest(2006.0) release also contains a program, which provides a graphical interface for installing Gentoo. It is non-sense to discuss the gui installer, so i'll carry on with giving you a view-in to the nemesis of all ignorants, the text-mode installation.
It is far from being so complicated as it would look like for the first time. It's kinda like compiling a kernel - it sure _is_ hard for the first time, and you'll probably mess something up - but once you have done it, you'll find it easier than pushing the shiny little reboot button on your PC.
The installation can be divided to 10 easy steps:
1. Choosing the installation medium
2. Configuring the network devices (optional)
3. Preparing the disks
4. Extracting the stage archive and configuring it
5. Installing the base system
6. Configuring the kernel
7. Configuring the system
8. Installing system tools
9. Configuring the bootloader
10. Adding some users
Well... that would be it. After you've done it, you can't even imagine an installation without the command line. But why is the CLI installation better than the GUI one anyway? In the first place it gives you a clear overview of the installation process, it lets you make some important choices about how your system will work in the future.

One of the greatest features of Gentoo is Portage, the package managment system it provides, about which I, intentionally, haven't spoken yet.
Portage is a very powerfull and versatile system for adding, removing and updating software packages(at the moment of writing it features more than 10000 packages). It was originaly designed with ports, the BSD package managment system, in mind. Gentoo's Portage system works similarly to Debian's APT. Portage is written in the Python programming language.
The main idea behind Portage is to compile every package from source, with the ability of choosing between wanted and unwanted features(USE flags), and of predefining compiler flags for the package manager to use. Though the system itself is known as Portage, operations are actually done with a command line program called "emerge". A GUI front-end is also available, known as "Kuroo".
The init system is another important feature of Gentoo. It is similar to the System V init system that most distributions use, however the Gentoo one uses dependency based scripts and named runlevels.

If you are the type of person, who prefers somebody else making choices suitable for you, rather than making your own, or simply you don't have enough experience in the *NIX world to decide which programs, which security model, what layout fits you the most, you generally shouldn't bother with using Gentoo. In the rest, I strongly recommend it for anyone, who is looking for a stable, reliable, fast and highly configurable operating system.

Saturday, April 22, 2006

Agama Lizard RC2


The SuSE guys got in the pool.. They just brought out the RC1, here I have RC2 and RC3 of 10.1 (codename: Agama Lizard) is coming next week. By the way this is the 14th development release since september 2005, which means they are really active, and they really care about the opinion of the consumer (why on Earth would they bring 14 dev-releases if not so?); the final release will hopefully be out in a few weeks.
They do not provide full images, only "delta" isos, which cover the differences between the two releases, and can be "installed" with the applydeltaiso command.

Some of the most annoying bugs still present in this release:

  • Language dependent packages for the default language are not installed (Bug 162064)

  • Every update from a 10.1 Beta/RC adds another selection to the system Bug (160792)

My first SuSE distribution was v9.2, I bought it with a magazine around a year ago, and remained with open when saw the "$90 retail value" text. Well, since then many things changed, from inner project philosophy through default background to version number :-) So what is really OpenSuse? According to it's "a worldwide community program sponsored by Novell that promotes the use of Linux everywhere. The program provides anyone with free and easy access to the world's most usable Linux distribution, SUSE Linux."
SuSE used to be my distribution what I show to my newbie friends, and they always used to say "Wow, I wouldn't imagine linux can do that!". Even if it was (and still is unfortunately) a bit slow, and it uses the RPM package management, which is considered by many people (including me) obsolete, it's the best distribution for newbies, and I always recommend it for that purpose.


Installing SuSE always was an easy task. It provides a bunch of drivers, you don't have problems not even with bluetooth devices or USB webcams. Some people say that YaST (yet another setup/system tool), the SuSE installer is an Anaconda clone, although that cannot be possible, since SuSE uses graphical installer since 1999, and RedHat only since 2000; the only common in them is that both are based on GTK..
I'll relate RC1's installation, since RC2 only needs the delta iso to be applied.
By the way, it seems that they didn't change anything in the install process anything since 9.2, it really looks the same, maybe I forgot how it looked like. As any other install, it starts with collecting information: Time zone, packages, desktop selection, partition layout, hardware. Apropo, partition layout: for a typical installation 2-3 GBs will be enough, though you should sacrify around 5 GBs if you even want to use it.. using a common /home partition with your another (if exists) distribution might solve the problem. The install process itself takes around an hour, so it isn't that short..

Applications and the desktop

Once the installation is finished (you'll get a bit tired if you don't look for other occupiation looking at the self-advertisements), you'll face GDM, with several (depending on what you've selected) optional windows managers, however, the default is either Gnome, either KDE (again, it depends what you've selected). OpenSuse provides a lot of applications, although it somehow doesn't give that "bloat" feeling which I felt using Fedora. It's just a handful set of software for all categories, so you don't really have to download anything to be able to use OpenSuse daily. Anyways, if you're still unsatisfied, or your packages simply went out of date, you can use YOU (Yast Online Update) to solve these problems. One thing I felt missing was 7.0.. Don't know.. Maybe only because all the distros I've reviewed lately had it, and because Xgl "needs" it (maybe it would run on 6.9.0 too, but 7.0 would be better), and I'm so disappointed I can't have XGL under SuSE. SuSE! The distribution of Xgl's company, Novell!


SuSE is the ideal distribution for beginners and for those who do not have an internet connection. It's plenty of packages, it contains all the documentation, to only mention two from the bunch of awesome features offered by this new release candidate - and previous releases as well. Advanced users might also find SuSE to be their distro of dreams, but they'll have some work to do, since the default SuSE era is kinda customized for beginners. I'm looking forward for the stable 10.1 release, and hopefully I'll review it as well! Good luck SuSE, and keep working!

Monday, April 10, 2006

CRUX 2.2 - Taste matters

According to the wikipedia article CRUX is a lightweight, i686-optimized Linux distribution targeted at experienced Linux users. The primary focus of this distribution is keep it simple, which is reflected in a straightforward tar.gz-based package system, BSD-style initscripts, and a relatively small collection of trimmed packages. The secondary focus is utilization of new Linux features and recent tools and libraries. CRUX also has a ports system which makes it easy to install and upgrade applications. But here is missing something! CRUX by philosophy is similar to Gentoo Linux or NetBSD: it's users have an easy-to-distinguish taste, which is reflected by the distribution. CRUX is not the "ordinary" distro, where you install everything with next-next-next-yes. It's far from it, it has a specific style, which requires some experiences as well.

Hardware architecture

Unlike you might think after looking at the Handbook, there are several architectures supported: PPC (last version: 2.1), SPARC (last version: 2.1rc1), x86_64 (last version: 2.2test1), i586 (last version: 2.1) however there's only one official release, i686.


Packages on the official CRUX ISO image are compiled with optimization for i686 (Pentium-Pro/Celeron/Pentium-II or better) processors. Do not try to install it on an i586 (Pentium, AMD K6/K6-II/K6-III) or lower processor, since it simply will not work. I will only touch here the CD-ROM installation method, since it's the most common, but you should know that you can install CRUX from network, and with your own bootkernel too.
First, of course, you have to download crux-2.2.iso (El Torito), and check its integrity (check its MD5 checksum). If it's OK, you should then burn the images, and boot into it (set your primary boot device to CD-ROM!). Now you can login as root (no password required), and create the necessary partitions (at least a root and a swap). After making some directories and mounting the corespondent partitions you arrive to the setting of the root password (attention, this will be very important later). Edit your config files like /etc/fstab, /etc/rc.conf, /etc/rc.d/* and /etc/hosts.
Now it's time to compile your kernel.. CRUX 2.2 has linux- included, which is very new compared to the release date. After you compiled your kernel succesfully, you must set your /etc/lilo.conf (or grub.conf if you plan to use GRUB) so that you can boot to your new CRUX installation in the future. You can execute now your script, which lets you select the packages you want.


CRUX organises packages in three groups:
-core: as it's name says, these are the base, necessary packages (like gcc, cron, zlib and binutils)
-opt: optional packages, which may be installed by the user if wanted (like WMaker, cdrtools, X.Org)
-contrib: user contributed packages (there aren't such on the official release disc)

There aren't too much packages on the disc, which can be seen by its size (2.2-i686: 230 MB), but no problem, there's ports and you can install thousands of packages later if you want.


According to the CRUX 2.2 Handbook a port is a directory containing the files needed for building a package using pkgmk. This means that this directory at least has the files Pkgfile (which is the package build description) and .footprint (which is used for regression testing and contains a list of files this package is expected to contain once it is built). Further, a port directory can contain patches and/or other files needed for building the package. It is important to understand that the actual source code for the package is not necessarily present in port directory. Instead the Pkgfile contains an URL which points to a location where the source can be downloaded.
If you've used BSD before, you might know (you have to know by the way..) what are ports, and how to use them (though there are some differences at CRUX). On your first-boot you should synchronize your ports collection, so that you can install the latest available packages then. Use this:
ports -u
To see all your ports, so list them, use ports -l.To see if you should install a new port (so if there's a new port appeared) simply execute ports -d, where d mean "difference". Once you've found a port you might need, cd the directory of the respective port, and execute pkgmk -d, where d mean "download". Then you can install it with pkgadd -portname-#-portversion-, or simply executing pkgmk -d -i to install, or pkgmk -d -u to upgrade the port (note: this way you don't need the first command, but you still have to execute this in the port's directory).


After going through the installation procedure, I think you already know that CRUX doesn't have graphic configuration tools, you have to do yourself everything, just like during the installation. As I said, CRUX is for experienced users, so if you just began, and installed it using the handbook for every little step, you have two chances: you'll spend a LOT of time learning linux, or you'll simply feel CRUX annoying and delete it. I recommend the first, since if you don't learn using linux with pain and time, you'll never be able to use a fully graphic-enabled system well. CRUX doesn't modificate software packages, so you can optimize everything for your needs. If you're an advanced user, CRUX is the ideal ditribution for you.


As CRUX is the absolute antonym to bloat, it's amazingly fast. If you know what you do, you'll never have any problems with it, everything is in your hands, made by your hands. You have secure packages, since the CRUX ports collection is made of the latest stable releases, nothing unstable enters it. Final sentence: CRUX is wonderful.

Later edit: This post has been criticised by DevOne. Read his thougts here