Hack 3 Use Knoppix Cheat Codes 
Cheat codes are extra instructions you type at
boot time that change many of Knoppix's settings. On
some hardware, use of these codes may be necessary to get the most
out of Knoppix.
Knoppix is good at automating many of the
tasks that Linux users often conduct manually, such as hardware
configuration, setting up the network, and logging into a desktop. If
you want to customize options or change what Knoppix automatically
runs, you can enter special commands at the boot prompt, which
Knoppix refers to as cheat codes. Cheat codes
are a reference to the secret passwords or key sequences entered in
video games to get unlimited lives or other special items.
Fortunately, cheat codes in Knoppix are simple words you type at the
boot prompt, and not complicated joystick sequences like up, down,
up, down, left, right, left, right, B, A. The cheat codes
aren't secret either. Open the Knoppix CD under your
current OS and browse to the KNOPPIX directory.
The cheat codes file is called
knoppix-cheatcodex.txt. You can also reference a
list of the most frequently used cheat codes by pressing F2 at the
boot prompt.
To use cheat codes at
the boot prompt, type knoppix to select the
default kernel, followed by the cheat codes you wish to use. For
example, if your Knoppix CD doesn't work the way you
expect, test for any physical errors on the disc; at the
boot: prompt, type the following command:
knoppix testcd
The following table lists many of the
settings and options you can change from the boot:
prompt using cheat codes:
|
Cheat code
|
Purpose
|
|---|
knoppix testcd
|
Check CD data integrity and MD5sums
|
knoppix desktop=fluxbox|icewm| kde|larswm|twm|wmaker|xfce
|
Use specified window manager
|
knoppix 2
|
Runlevel 2, Textmode only
|
knoppix noeject
|
Do NOT eject CD after halt
|
knoppix noprompt
|
Do NOT prompt to remove the CD
|
knoppix splash
|
Boot with fancy background splashscreen
|
For example, if you want to use the fluxbox window manager instead of
the default KDE desktop, at the boot: prompt type:
knoppix desktop=fluxbox
Look at the list of cheat codes to see a number of other
window
managers, including icewm, larswm, twm, wmaker, and xfce. Each of
these window managers offers different features, and most of them
offer a completely different environment from what a Windows user
might be used to. In addition, these other desktop environments load
faster and use less memory than the default KDE desktop.
The text mode cheat code (type
knoppix 2 at the boot:
prompt) is useful in circumstances when you don't
need a full graphical environment or your graphical environment does
not work. This cheat code goes through the full hardware detection
but leaves you at a simple prompt instead of launching a desktop
environment. On machines with less than 64 MB of RAM (less than 82 MB
if using KDE), this mode lets you boot into Knoppix and take
advantage of all of Knoppix's command-line
utilities—just without the desktop environment. This mode is
also useful because it quickly boots into a full shell without the
wait for X and a desktop environment to load. After you boot into
text mode, you can switch into a full desktop environment by changing
your runlevel; at a prompt, type the
following command, and Knoppix will start up the default desktop
environment:
root@tty1[/]# init 5
The splash cheat code adds some extra eye candy
to the boot process. This cheat code replaces the colorized text
output with a fancier graphical background as the system is booting,
reminiscent of loading Windows. Hit the
Esc
key to drop back to the default
text output.
The noeject and
noprompt cheat codes are useful when, the next
time you boot, you plan to use the Knoppix CD in the same system. By
default, when Knoppix shuts down, it ejects the CD and prompts you to
hit Enter to complete the shutdown. Use these cheat codes to disable
these two convenience features, and when Knoppix shuts down, it
leaves the CD in the drive for the next boot.
Experiment! Try out new desktops. Test different cheat code
combinations. Remember that changes you make with
cheat codes do not persist across reboots,
and desired changes must be entered at the boot:
prompt each time. To make settings persistent, save them on media,
such as a USB drive, a floppy diskette, or an existing hard drive.
(Saving persistent settings is covered in detail in [Hack #21] .)
|