The intro on the main page states that "CRUX is a lightweight, i686-optimized Linux distribution targeted at experienced users", and I would suggest to take this seriously. It's unlike installing Linux MInt or Fedora, it's not even like installing a modified Gentoo, more somewhere between Gentoo or Linux from Scratch and Slackware, with the latter being the easy one. Like most advanced distributions CRUX aims at keeping it simple, adhering to the KISS philospohy. For that it uses a straightforward tar.gz-based package system and BSD-style initscripts, again similar to Slackware and Arch for example. The system is configured through manually editing text files. The main repository as small and provides few packages, but users have access to a ports system which suposedly "makes it easy to install and upgrade applications". We'll see how that works, but personally I think this sounds great. If you like something with a similar outlook to Slackware, perhaps a bit more rolling but not quite as much as Arch and not foisting systemd on you just yet, with a BSD-style ports tree then this could be for you. Actually, a lot of the more advanced Linux distributions seem to be modelling themselves on the BSD's in this respect. It's basically a repository with source code that compiles for your machine at install time.
Part 1 - Installation
CRUX 2.8 was released 24/10/2012, and as ever the official build is i686 32-bit only, but the download page also offers contributed images for the x86_64 architecture. Release notes for RC1 of the already upcoming 3.0 suggest x86_64 will be an official build from now on, or the distribution will switch its main supported architecture. Both have been processed with isohybrid and can be extracted for booting from a USB drive or Flash key etc. Other architectures like ARM, PowerPC and Sparc64 are unofficially supported. I went with the official build for maximum compatibility for which the iso file is 266.3 MB in size. Not a lot, it downloads at a good rate in mere minutes, with many local mirrors accessible from the main page. Of course you'll only get a basic system for that which comprises the install base and the ports tree. It's up to the user to shape the system and that means it can be anything you like. I noticed that on Distrowatch CRUX is classed as server, but, being a vanilla distribution, it can be anything you build, from server to desktop. Follow me to see what it's like.
On first boot we are presented with a screen to choose from several options, some useful if your hardware is problematic or you just want to log into the console for some maintenance, otherwise the default entry will do us. After hitting Enter, the usual boot messages scroll by. Some of it in nice color, mind you.
Once finished we are autologged in to the root account. Type 'setup' to proceed and we get a nice little welcome screen which reminds to take a look at the CRUX installation guide before we continue. If you haven't, you really should look at the relevant sections in the handbook. The script will then guide through the rest of the routine, and all in all the steps are very similar to installing Arch.
One potential trap is that if you don't partition the disk and assign mount points before continuing, the text based installer will still go ahead and install packages into the ether, there's no warning about missing mount points or swap partition etc. So type 'cfdisk' and carve up your partitions, then mount them as guided. Essentially you're doing a lot of work manually that in other distributions the installer takes care of in the background, like setting 'swapon'. Now that you're ready you can enter 'setup' for real and progress to installing packages. You get a choice which sets -I chose all three, including Xorg- and after asking you to confirm whether you want to pick every package or just go with the whole subset another prompt finally will install everything to disk. The whole thing barely takes 5 minutes. Once installed, the 'setup' script displays an installation log and will let you know in CAPITAL letters if the install routine was successfull. The nice thing here is that everything is on the CD image and can be installed without network access, no netinstall required, and additional packages can be added from there.
These were only the first steps on the long road to lightweight bliss as now it's time to compile the kernel. Yes indeed, it is more involved than Slackware or Arch. The latest kernel source on the iso image is 3.5.4 and as it is a quite up to date distribution you'll probably have to compile another one once finished, but for now we need a kernel to be able to run in the first place.
I won't go into configuring the kernel here, but readers could check out my post on this subject earlier in the year, or one of these two posts on kernelnewbies.org or one of the many other guides. The CRUX handbook also outlines the basic steps which is probably all you'll need if you've done this before and just need a reminder what to type, but it won't tell you what to select in the configuration steps and which modules and settings your hardware requires to run effectively, so I'ld recommend you know your machine in and out before attempting this. By default the CRUX kernel configuration is extremely slim, in line with the basic and light approach taken, and a default compile results in a kernel of only 1.2 MB. It won't make use of your TV card though.
|Aaah, made a mistake, again.|
For further help, you may want to look at Compiling your kernel during 2.7 installation, or at this guide with plenty nice screenshots. Somebody's also uploaded a video tutorial on kernel compilation in CRUX.
Part 2 - Day to Day Usage
If all went well and Xorg was selected at install time you will get something like this. Not too inviting, but it's a start. We can build the system up from here. Unless of course you only wanted the console anyway.
Before we can install more packages we'll need to connect to and update the ports tree. There's a fair bit of jumping to do in the handbook. As you're most likely using dhcp to acquire a network address but the default service script in /etc/rc.d/net doesn't reflect this, you'll want to configure your network with the script for dhcpcd as shown there in the second box. A simple matter of deleting and retyping some lines. Restart your network or reboot. It's also a good idea to enable the contrib repository in your local prt-get.conf configuration. We're well on the road now to finally getting the latest ports database, and this can be updated with 'ports -u'. Again, refer to the handbook for ports and for package management.
You can list all ports with the -l option or grep for the package you want. This shows that openbox is in opt, but obconf is in the contrib section, so you can't take anything for granted here. The main repos above have a fair amount of packages but none of the bigger desktop environments, Fluxbox and Openbox is what you get. The CRUX website has a ports page with a long list of additional, private repositories where you can also find KDE 4 and Xfce. It's up to you whether you trust them to update your machine from, and the usual disclaimers when using other people's sources apply. Check Building ports as unprivileged user (with fakeroot).
After updating the list of available packages you'll want to install some more stuff to make it usable. I opted for Openbox. prt-get is the utility that actually downloads and compiles software, but trying to add obconf resulted in a dependency error stating that startup-notification was needed first. Not to worry, CRUX supports dependency resolution as long as they're in the repositories and 'prt-get depinst obconf' got me there, bringing in libglade as well. prt-get seems to be the easy option to have it all automated and installed. The other one would be to use 'pkgmk -d' to download the source and build, then use 'pkgadd package#version.pkg.tar.gz'. I built a couple more packages like mplayer which worked well and compiled all codecs using the depinst switch. 'prt-get sysup' updates the entire base install except the kernel and thus replaces the precompiled binaries that were first installed with packages compiled for your machine bit by bit, pun intended. The kernel is not actually installed as a package and is thus not in the database, leaving you free to update separately at your own leisure.
Repositories are fairly limited but as this is a bare bones Linux distribution completely compiled from source it is not difficult to add anything that is missing. Instructions on how to create packages with your own Pkgfile are, as ever, in the handbook. Or you may want to do it the old fashioned way or use src2pkg. The latest images for 2.8 seem to come with the 3.6 kernel instead of 3.5.4. This means the distribution is updated often and it should not be difficult for the experienced user to add anything s/he wants.
At this point I ended my adventure with CRUX until possibly another day. It's a neat little distribution that can give you that raw linux feel of the old days and where the system is yours to shape from the ground up. Needless to say, it's very fast. If that's what you want and you have the time for building it, that's great. You'll need to add everything, from enabling it to mount external USB drives to whatever else you want it to perform. The constant compile time is not to be taken lightly, but it will heat your room in winter.
I really like CRUX, the way it integrates building from ports and dependency resolution without third party unofficial tools, but I prefer starting from a slightly higher level with a more complete system. It appears to be a niche project with only a small core of longer-term users and developers that have settled on it. The documentation is probably all you'll ever need and is updated for every release although most of it is just a straight copy from the previous one if nothing's changed. A basic wiki is accessible from the project's site and forum and IRC channel are available.
Another nice guide to getting started with CRUX by AgentOSS.