Shewbox.org

sub specie aeternitatis

Guide to Slax on a USB Drive

November 1, 2006

Update 4-20-09: This guide is rather old and out dated.  There is a newer version of MySlax creator at a new address.

I’ve mentioned before how MySlax Creator makes it simple to install Slax to a USB drive. Since I use Slax on my USB key whenever I use the computer lab at school, I thought I would write up a simple guide on how use Slax on a USB drive.

What is Slax? Slax is a lightweight, live Linux distribution based off of Slackware, a distro known for rock stolid stability but not one famous for being newbie friendly. Slax, like most live Linux distros, is a great way to experience Linux without installing it to your system, and also a great portable operating system. Assuming you have access to boot from a USB drive, you can take your operating system with you without lugging around an expensive notebook computer. As I mentioned earlier, I use Slax on computers in the music library at school. These are newer Dell computers, and by pushing F12 after rebooting, I can boot from the USB drive. Not all the computers on campus work this way, however, and I cannot boot into Slax on those machines. But as I said, I use the computers in the music library most often, and using Slax gives me a consistent environment that erases all of my tracks the second I reboot. So I don’t have to worry about nasty programs that might be installed on these often used Windows machines. But on to Slax. .

Step One: Download It

In order to install Slax you need to download it. Head over to the download page for Slax and grab the .iso for Slax standard edition. I recommend downloading via bittorrent as this was the fastest way for me.

one

Since we are installing Slax onto a USB drive, you need to get a copy of MySlax Creator. You can download it from this link. Install MySlax Creator once it is finished downloading.

two
Step Two: Install to USB Drive

Installing other live Linux distros onto a USB drive can be an extremely frustrating experience. Thank God for MySlax Creator. I’m going to cover the most basic operations of MySlax. You can do more if you want, but for just installing Slax onto the USB drive, it is seriously this easy:

1. Start MySlax:

3
2. Click Next

4
3. Under ‘Source Type’ select ‘ISO-Default’. Under ‘Select an Slax ISO image’ click the folder icon and load the .iso file you downloaded in step one.

4. Click the ‘Mount’ button.

5
5. Now click the button ‘USB Stick’

6
6. Under ‘Select USB drive’, select the drive corresponding to your USB stick. In my case, it is drive I. Make sure to copy any important data to a different location before continuing as MySlax will format the drive and install Slax where you data used to be. Now click ‘Create USB Stick’

7
7. MySlax does not have a built in tool to format the USB drive. But since Windows has an easy way to do this, MySlax does not need to reinvent the wheel. In my case, everything is already set to what it needs to be. File System should be FAT32, Allocation unit size should be ‘Default allocation size’, and you do not need a Volume label. Make sure ‘Quick Format’ is selected and click ‘Start’. A warning will appear, noting that this will erase all data. Hit OK, and the format should finish in very little time. Once it is finished, click ‘Close’ on the ‘Format Removable Disk’ window and MySlax should begin installing Slax onto the USB drive.

8
It may take a few minutes to finish, and you will see various files listed in the ‘Status’ box. It will pop up a dialog box when it is finished:

9

Step Three: Extending the Default System

At this point you will have a working version of Slax on your USB key. If you are impatient to get going you can restart your computer at this point and boot from the USB drive. However, before we do that, we want to add some extra applications to our Slax system. Slax allows users to add on applications and drivers by ‘Modules’. You can easily add and remove modules simply by adding or removing them from the ‘modules’ directory on your USB key. Head over to the Modules page, and you can browse the available modules. For this guide, we are only going to grab one:

Firefox 2.0

10
Click the ‘download’ icon to download the module. Once it is downloaded, open ‘My Computer’ and then the drive corresponding to your USB drive.

11
There should be a folder named ‘modules’. Copy the module (.mo) file into the ‘modules’ folder. That’s it. The module is now installed. To remove modules that are older or do not work, just delete the file. You can also do this once you are booted into Slax as well, but we’ll get to that in just a moment.

Step Four: Booting into Slax

Not all computers can boot from a USB drive, and those that can have varying ways of doing so. On my Dell at home and at school, I push ‘F12’ before the computer boots into Windows, and I have the option to boot from USB. Some computers may require you to change a BIOS setting, or push other keys for a boot menu. I can’t list all options here, so if you aren’t sure, google your computer make and boot to usb and you should be able to find directions for your particular setup.

Assuming you have figured out how to boot from USB, the next screen you will see once doing so will be a black screen with white text saying ‘Boot:’. Just hit ‘Enter’ and Slax should begin to boot. (note: for some reason on my Dell and the school Dell, I sometimes would get a repeating text with an error message of ‘mutex something or other’. If you see this during bootup, the next time you start to boot from the USB drive, at the boot: screen, type ‘slax acpi=off’. This fixes this problem for me)

Step Five: Running Slax

Once the system is booted, you are greeted with a text screen, looking something like this:

16
To login, type ‘root’, and then ‘toor’ for the password. Linux does not provide ** characters when you type the password so you will see nothing as you type the password ‘toor’. From this point, what you do with your system in really entirely up to you. I could write a very long book on what you can do in Slax, but there are already many great guides out there on using Linux, so I won’t get into great detail past this point. I will just cover a few steps I take in my Slax usage.

1. KDE. Once you are logged in, type ‘xconf’ and hit enter. This should automatically configure your system for using KDE. Now type ‘startx’ and KDE should automatically load. Once you are in KDE you can change the screen resolution by right clicking on the blue icon withe white arrow in the lower right hand corner of the screen.

12
2. Viewing files from another partition. Slax automatically mounts NTFS partitions (where you store your windows files) as read only. You cannot write to your windows paritition, but you can view files stored there. Load up Konqueror (the file browser, click on ‘Home’ on the desktop), and in the address bar type ‘/mnt/’ The directories within here will probably be listed such as ‘hda1’, ‘hda2’, ‘hdb1’, or even ‘sda1’ if you have a SATA drive. This is also where you can add files to the USB key. In my case, it is called ‘sdb1_removable’.

13
You can add/remove modules from the ‘modules’ directory just as you did in Windows. If you copy a module into the ‘module’ directory, it will not be active until you reboot. To add a module without rebooting, just double click the file and select ‘insert module into live filesystem’. Also, if you plan on saving files in Slax that you want to view later in Windows, I recommend adding a folder in the USB directory (again, /mnt/sdb1_removeable for me). Something like ‘storage’ perhaps. Then, when you are back in Windows, you can easily view these files.

Step Six: Saving Your Settings

Any changes you make within Slax such as customizing toolbars and menus and changing the wallpaper will disappear once you turn off the computer. The great thing about using a live Linux distro on a USB key is the ability to save all your settings on the drive which hosts the operating system. In Slax, if you save your settings once, then every time you boot back into Slax, you will see an option to load settings as the system is booting up. Also, as you shutdown, you will see an option to automatically save settings before the computer turns off. But in order to get these auto loading/saving options you must first manually save your settings (I think, someone please correct me if I’m wrong). First, load up the console (the big black icon next to the KDE menu button). Next, you need to know which drive corresponds with your USB key. As mentioned above, it will be under /mnt, and in my case it is called ‘sdb1_removable’. Once you know which folder in /mnt corresponds to your USB key, substitute ‘sdb1_removable’ with the name of your folder in the following command:

‘configsave /mnt/sdb1_removable/slaxconf.mo’

14
slaxconf.mo is the actual name of the file which you are saving your settings to. If you want to experiment with different settings, but want to keep slaxconf.mo as a safe settings file, then you can always use something like ‘slaxconf_backup.mo’ or whatever you want to name it. So long as it ends in .mo, it doesn’t really matter what you name the settings file.

And that’s about all I have to say on Slax. If you find you need help beyond this little guide, be sure to check the Documentation or Forums for more help. If you have any questions or comments for me, please drop me a line.