Troubleshooters.Com and T.C Linux Library Present

Damn Small Linux (DSL)

Copyright (C) 2004 by Steve Litt, All rights reserved. Material provided as-is, use at your own risk. 



Knoppix is a Linux distribution engineered to run from a bootable CD. The idea is that a Windows user could experience Linux simply by booting the Knoppix CD. OpenOffice, email, web browsing, audio and video are all right there for the user to enjoy, without any change or compromise to his system. What a great advocacy tool!

Advocacy just scratches the surface of Knoppix' usefulness. It's a computer buyer's friend, a supreme configuration tool, and it's the best rescue CD ever made.

CONTENTS:

What is DSL?

Knoppix is a Linux distribution optimized to store and boot on a single CDrom, without requiring any space on the host computer's disk. This means that Knoppix is the ideal distro with which to test out Linux without making a committment. It also makes Knoppix an ideal configuration tool, rescue tool, forensics tool, and computer evaluation tool (testing computers before purchase).

Running Knoppix is usually as simple as placing the Knoppix CD in the CD drive, setting the bios to boot from the CD, and rebooting. Occassionally you need to use some of the Knoppix "cheat codes" at the boot prompt. These are codes that set video refresh rate, memory and other boot parameters.

Where to Get DSL

The home page for DSL is http://www.damnsmalllinux.org/. From there, you can either buy a CD, download a 50MB ISO for a DSL CD, buy a bootable tiny USB drive. The download page is at http://www.damnsmalllinux.org/download.html.

Once you have the .iso file, you can use the procedures in my Coasterless CD Burning page to create the bootable/runnable CD.

Using DSL from the CD

Place the CD in the CD drive, reboot the computer. Upon initial bootup, go into the bios and enable booting from CD. During the boot process it will probably get this error message:

You passed an undefined mode number.
Press <RETURN> to see video modes available, <SPACE> to continue or wait 30 secs.

If you press Enter you can see and choose the number of lines and columns on a CLI screen. If you press the spacebar or wait thirty seconds, it defaults and boots.

When the boot process is complete, you're in a GUI screen with the fluxbox window manager. Fluxbox is one of those window managers with no taskbar or start button, so you obtain the menu by right-clicking the desktop.

If your network has a working DHCP server, and your network has a gateway to the Internet, the box will be granted an IP address by DHCP, and will therefore be able to get out to the Internet.

Here is a partial list of programs that ship with DSL:


PROGRAM
WHAT IT DOES
COMMAND LINE
Scite An editor
scite
Vim The world's best editor
rxvt -rv -e vi
Zile EMACS-clone An emacs clone
rxvt -rv -T "Zile" -e zile
Nano An editor
rxvt -rv -T "Nano" -e nano-tiny
xzgv Image Viewer An image viewer
/usr/bin/xzgv
Xpaint A paint program
/usr/bin/X11/xpaint
Ted Extremely simple word processor
ted-gtk
Xpdf PDF viewer
/usr/bin/xpdf -geometry 640x480
Xcalc Calculator
xcalc
ABS spreadsheet Spreadsheet
abs -geometry 640x480
SQLite Book Database front end
/usr/local/bin/sqlitebook.pl
PIM using Index Personal Information Manager
rxvt -rv -T "PIM using Index" -e /usr/bin/index
Net Dictionary Text based internet dictionary -- very cool
rxvt -rv -T "Internet Dictionary" -e /usr/local/bin/getword
gPhone A sound app
gphone
Xmms Audio/MPEG mpeg/wav/ogg player
xmms
Download High Bandwidth Mp3 Streams Download mp3 streams
rxvt -rv -T "Grabbing streams..." -e /opt/.xmms_streams_grab.sh highbandwidth
wMix Mixer
wmix
Microcom Serial port front end
rxvt -rv -T "Microcom" -e /usr/bin/microcom
nAIM
rxvt -rv -fn fixed -T "nAIM" -e /usr/bin/naim
nIRC #DamnSmallLinux IRC client
rxvt -rv -fn fixed -T "nIRC" -e /usr/bin/nirc dsl$$ irc.freenode.org
nICQ ICQ client
rxvt -rv -fn fixed -T "nICQ" -e /usr/bin/nicq
gLinks hacked GUI version of Links text browser
links -g
Links hacked Links text browser
rxvt -rv -fn fixed -cr yellow -T "Links Haked" -e links
Dillo patched Dillo fully graphical editor
dillo file:/usr/share/doc/dsl/getting_started.html
Sylpheed mail client Mail client
sylpheed
AxY FTP (GTK+\) FTP client
/usr/X11R6/bin/axyftp-gtk
FTP FTP client
rxvt -rv -fn fixed -cr yellow -T "FTP" -e ftp
Telnet Telnet client
rxvt -rv -fn fixed -cr yellow -T "Telnet" -e telnet
Mutella ?
rxvt -rv -fn fixed -cr yellow -T "Mutella" -e /usr/local/bin/mutella
VNCviewer VNC remote terminal client
/usr/bin/vncviewer
Get Flash Plugin Get flash plugin
rxvt -rv -fn fixed -cr yellow -T "Get Flash Plugin" -e /opt/.grab_flash
Bash Bash shell
rxvt -rv -fn fixed -T "Bash" -e /bin/bash
Sh sh shell
rxvt -rv -fn fixed -T "Sh" -e /bin/sh -login
Csh C shell
rxvt -rv -fn fixed -T "Csh" -e /bin/csh -l
myDSL Click and Load) Config and repackaging utility
mydslgui.sh
Net MAN man command that gets its info from the internet
rxvt -rv -T "Internet MAN" -e /usr/local/bin/getman
CD Burn App CD burner
rxvt -rv -fn fixed -T "BashBurn" -e bashburn
emelFM File manager
emelfm
emelFM as super-user File manager run as root
sudo /bin/bash -c emelfm
Midnight Commander File manager
rxvt -bg blue -fg white -cr yellow -fn fixed -T "Midnight Commander" -tn xterm -e mc -b
MC as super-user File manager as root
rxvt -bg brown -fg white -cr blue -fn fixed -T "MC as super-user" -e sudo su -c 'mc -b'
Editres X resource editor
editres
X Window Snapshot Screenshot utility
xwd -out myscreen.xwd; xwud -raw -in myscreen.xwd
Xkill Kill gui app
xkill
bbpager monitor
/usr/bin/bbpager
wmnet monitor
wmnet -w
asmem monitor
asmem -withdrawn -bg black -fg white
wmcpuload monitor
wmcpuload
mount.app monitor
mount.app
Install to Hard Drive Install to hard disk
rxvt -rv -T "DSL Hard Drive Installation" -e sudo dsl-hdinstall
Frugal Install Minimal install to hard disk
rxvt -rv -T "DSL Frugal Install" -e sudo frugal_instal.sh
Install to USB Pendrive Install to a pen drive
rxvt -rv -T "DSL USB Pendrive Installation" -e /usr/sbin/dsl-usbinstall
Enable Apt Download enough software to enable apt-get and dpkg
rxvt -rv -T "DSL Apt and Dpkg Restore" -e sudo dpkg-restore
Rxvt Light Light colored terminal emulator
rxvt -fn fixed -cr blue -T "Bash" -e /bin/bash
Rxvt Dark Dark colored terminal emulator
rxvt -rv -fn fixed -cr yellow -T "Bash" -e /bin/bash
Root Access Terminal emulator as root
rxvt -rv -fn fixed -cr yellow -T "Bash" -e sudo /bin/bash
Full Enhanced Desktop Enhance desktop
enhance &>/dev/null
Icons Only Icons only
xtdesk
No Icons No icons
killall -9 xtdesk
Control Panel Linux control panel
dslpanel.sh
Backup/Restore Back tool
sudo /usr/sbin/filetool.lua
start Start lpd
sudo /usr/sbin/lpd
stop Stop lpd
sudo killall -9 lpd
reload Reload lpd
sudo /usr/sbin/lpc reread
configure printer Printer configuration
rxvt -rv -fn fixed -cr yellow -T "apsfilter" -e sudo /usr/share/apsfilter/SETUP
netcardconfig Network card configuration
rxvt -rv -fn fixed -T "Netcardconfig" -e sudo -H /usr/sbin/netcardconfig
dial-up PPP Configure dialup
sudo /usr/sbin/pppdial
PPPoEconf Configure PPOE connection
rxvt -rv -fn fixed -T "PPPoEconf" -e sudo -H /usr/sbin/pppoeconf
Pon PPOE on
sudo -H /usr/bin/pon
Poff PPOE off
sudo -H /usr/bin/poff
iwconfig
rxvt -rv -T "iwconfig" -e sudo -H /sbin/iwconfig
wlcardconfig Wireless networking setup
rxvt -rv -T "wlcardconfig" -e sudo /usr/sbin/wlcardconfig
ndiswrapper NDIS setup
ndissetup
prism2 ?
prism2_setup
ssh start ssh start sudo /etc/init.d/ssh start
ssh stop ssh stop sudo /etc/init.d/ssh stop
ssh restart ssh restart sudo /etc/init.d/ssh restart
ssh reload ssh reload sudo /etc/init.d/ssh reload
ssh force-reload ssh force-reload sudo /etc/init.d/ssh force-reload
nfs start nfs start sudo /etc/init.d/nfs-common start
nfs stop nfs stop sudo /etc/init.d/nfs-common stop
nfs restart nfs restart sudo /etc/init.d/nfs-common restart
monkey start web server
sudo /opt/monkey-0.8.2/bin/banana start
monkey stop web server sudo /opt/monkey-0.8.2/bin/banana stop
monkey restart web server sudo /opt/monkey-0.8.2/bin/banana restart
betaftpd start ftp server sudo /usr/sbin/betaftpd
betaftpd stop ftp server sudo killall -9 betaftpd
Sound Config Sound configuration
rxvt -rv -T "soundcardconfig" -e sudo /usr/sbin/soundcardconfig
Keyboard keyboard configuration
rxvt -rv -T "kbdconfig" -e sudo /usr/sbin/kbdconfig
X Setup X setup
rxvt -fn fixed -rv -cr yellow -T "X Setup" -e /usr/sbin/xsetup.sh
Top The top process watcher
rxvt -T "Top" -e /usr/bin/top
pstree Processes as a tree
/etc/alternatives/rxvt -e /usr/bin/pstree.x11
AddUsers User add utility
sudo /usr/sbin/addusers.lua
Shutdown Halt the computer
sudo /sbin/halt
Reboot Reboot the computer
sudo /sbin/reboot
Run Program Run a program
grun


Installing DSL on the Hard Disk

Installing DSL on the hard disk is very simple. Right click the desktop, then Apps->Tools->Install to Hard Drive. It first asks the target partition. You counter with something like hda1. For some reason, it rejects /dev/hda1. Go figure.

Next it asks if you want the standard or enhanced install. The standard install if 50MB, and installs entirely off the CDRom. The Enhanced install pulls files off the Internet, requiring a working Internet connection. Also, the Enhanced Install takes quite a while if you have a dialup connection.

The standard install is sufficient for appliance type setups, or cursory web/email clients. You'll probably want the Enhanced install otherwise. Keep in mind though, no matter what install you perform, a broken cpp program prevents you from compiling a lot of apps.

Finally, it asks if you have a working Internet connection. Answer truthfully. If you chose an enhanced installation without a working network, the install will terminate after a while, telling you it will only do the standard install.

Once you answer about the Internet connection, it will ask you whether you're sure you want to install, thereby wiping out the partition. Make sure you are ready to wipe out the partition, and if so, answer yes.

The install program now takes many minutes (depending on processor and web connection) to complete its work, and then asks you if you'd like to run the boot installer. Say yes. Finally, it asks you if you'd like to reboot. Say yes.

When it reboots, you have a very simple machine. A few web clients, VI (a crippled Vim), several other apps. Enough for simple computer usage, but not what you'd call a real desktop machine.

Standard or enhanced, your installation does not have a functional apt-get or dpkg. You need those if you want to do anything more than browse the net and get email. To enable them, be sure your Internet connection is working and connected, then right click the desktop, then Apps->Tools->Enable Apt. The computer will take quite a bit of time downloading more stuff.

If you simply need an appliance, you can probably

asks some simple questions such as whether you want to do the extended install, and whether you have a working Internet connection.

Installing IceWM

The Fluxbox window manager is nice, but if you're like me you prefer a taskbar and start button. The IceWM window manager is almost as efficient as Fluxbox, and it has a start button, task bar, and network and CPU monitors on the taskbar. Install IceWM as follows:
apt-get install icewm
The computer will download and install IceWM. To enable IceWM, edit the /home/dsl/.xinitrc file. Comment out the line that runs fluxbox, and substitute the following:

# set mouse speed
xset m 5 2

# start xterm by default
xterm &

icewmtray &

# silently check if icewm is in your $PATH and start icewm when found
# or a red colored xterm when not found or execution of icewm fails
which icewm >/dev/null 2>&1 && exec icewm || exec xterm -bg red


The result is a rather hard to see black version of IceWM. You need to change the theme. Do so by creating a .icewm directory under the home directory, and creating a preferences file containing the following:
ShowThemesMenu=1 # 0 / 1
Theme="Nice/default.theme"



Enabling C/C++ Compile


Using Knoppix to Test a Computer Before Purchase

If you're a Linux user, buying the right computer, especially a laptop, is a problem. Follow the logic...
Enter the Knoppix CD. Go to the computer store, find a computer you like, ask the salesman for permission to boot your Knoppix CD in that computer. Knoppix has one of, if not the, best hardware detection systems around, so if a computer is capable of running Linux at all, it will probably run Knoppix.

Once booted, you can test office products, sound, and many other functions. If you bring a DHCP server and a hub and a couple network cables, you can also test the computer's networking.

Your Knoppix CD can be used in stores, computer shows and swapmeets, and in used-computer purchases. A Knoppix success doesn't guarantee you'll be able to install and enjoy your favorite distro on a computer, but it certainly reduces the odds of buying the wrong computer.

Knoppix as a Configuration Tool

Knoppix's hardware detection and configuration are second to none. Imagine if your X configuration becomes broken, and you can't fix it with your distro's tools. Knoppix to the rescue. Insert the CD, reboot, and if your system is capable of X, Knoppix will run it. You might need to use one of Knoppix's "cheat codes" on boot, most notably the xvrefresh= cheatcode, but one way or another if your system is capable of X, you'll run X.

Once X is running, right-click one of your partitions, set it read-write, and copy /etc/X11/XF86Config-4 to that partition. Be sure to also mount the root partition read-write long enough to set the default runlevel down to 3 in /etc/inittab. Reboot, remove the CD, back up your original X configuration file, and copy the one from Knoppix over it. Most likely you'll now have a working X. Tweak as necessary.

This same method can be used for any configuration file -- sound, network, whatever. If Knoppix detects it, you can mount a partition read/write, save the config file created by Knoppix, then use that config file in your distro, and slowly experiment to make it even better.

Knoppix as a Rescue CD

This subject is so incredibly helpful that it has its own page.

Using Knoppix for Forensics

If you're in law enforcement and want to scan a computer's hard disks for kiddie porn or terrorist activities, consider Knoppix. You can quickly and easily mount all the computer's drives and partitions read-only, and then, at your own pace, use commands dd, strings and grep to peruse the hard disk as a device (see deleted files), and the files themselves. This works for both Linux and Windows computers.

If some script kiddie busted into your computer and you want to investigate without further damage, take it off the Internet and boot up a Knoppix CD. You can now look at all your log files through a known good operating system.

Knoppix as a Working Distro

All I know about this is more and more LEAP members are going beyond Knoppix' "boot from CD" roots and using it as an actual distribution on the hard disk. It's based on Debian, so it can be maintained with apt-get, etc. I'll tell you more when I know more.

Back to Troubleshooters.Com * Back to Linux Library