<?xml version="1.0"?>
<?xml-stylesheet type="text/css" href="https://mail.knoppix.net/wiki3/skins/common/feed.css?303"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
		<id>https://mail.knoppix.net/wiki3/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=125.238.255.237</id>
		<title>Knoppix Documentation Wiki - User contributions [en]</title>
		<link rel="self" type="application/atom+xml" href="https://mail.knoppix.net/wiki3/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=125.238.255.237"/>
		<link rel="alternate" type="text/html" href="https://mail.knoppix.net/wiki/Special:Contributions/125.238.255.237"/>
		<updated>2026-09-18T07:18:06Z</updated>
		<subtitle>User contributions</subtitle>
		<generator>MediaWiki 1.23.3</generator>

	<entry>
		<id>https://mail.knoppix.net/wiki/Wireless_Networking</id>
		<title>Wireless Networking</title>
		<link rel="alternate" type="text/html" href="https://mail.knoppix.net/wiki/Wireless_Networking"/>
				<updated>2008-10-02T23:34:27Z</updated>
		
		<summary type="html">&lt;p&gt;125.238.255.237: revert&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==== General Information On Wireless Card Setup Under Knoppix ====&lt;br /&gt;
&lt;br /&gt;
This is a stub for this section, to be added shortly&lt;br /&gt;
NdisWrapper: This seems to be a way many people are useing windows drivers to run their wireless equipment. This is done to allow Linux to talk through a wrapper that emulates windows calls to the windows driver. It asks for the driver X.inf and maby X.sys Then 2 other things ...id and wep key.&lt;br /&gt;
&lt;br /&gt;
If instructions of what to enter into these fileds and where to find it and what version of knoppix the GUI interface being used is found and maby a genaric BA shell interface for doing this.&lt;br /&gt;
&lt;br /&gt;
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -&lt;br /&gt;
&lt;br /&gt;
Short and sweet (but incomplete)&lt;br /&gt;
&lt;br /&gt;
ndiswrapper -l (lists all the present drivers)&lt;br /&gt;
&lt;br /&gt;
ndiswrapper -e (do for each driver)&lt;br /&gt;
&lt;br /&gt;
modprobe -r ndiswrapper (unload old module)&lt;br /&gt;
&lt;br /&gt;
nsidwrapper -i mywindowswirelessdriver.inf&lt;br /&gt;
&lt;br /&gt;
ndiswrapper -l (my.. is there only one there? :)&lt;br /&gt;
&lt;br /&gt;
modprobe ndiswrapper&lt;br /&gt;
&lt;br /&gt;
dmesg | grep ndis&lt;br /&gt;
&lt;br /&gt;
iwconfig (Gottcha!!! wlan0)&lt;br /&gt;
&lt;br /&gt;
ifconfig wlan0 etcetc&lt;br /&gt;
&lt;br /&gt;
iwconfig wlan0 etcetc&lt;br /&gt;
&lt;br /&gt;
dhclient wlan0&lt;br /&gt;
&lt;br /&gt;
ping google.com&lt;br /&gt;
&lt;br /&gt;
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -&lt;br /&gt;
&lt;br /&gt;
My two bits of information added here could be edited for readability but&lt;br /&gt;
I definitely believe it will help people (it helped me!)...&lt;br /&gt;
&lt;br /&gt;
Here's one example of how to use ndiswrapper (http://ndiswrapper.sourceforge.net[http://ndiswrapper.sourceforge.net])&lt;br /&gt;
READ the Install directions (at least twice) until all the commands and the REASON&lt;br /&gt;
you're typing these things in makes sense because you may have to modify it for your&lt;br /&gt;
particular situation (as I had to do) AND read Troubleshooting if you have troubles.&lt;br /&gt;
&lt;br /&gt;
Note: My wireless usb hardware was listed under List of cards known to work, this may &lt;br /&gt;
make redundant the section below.&lt;br /&gt;
&lt;br /&gt;
Copy the whole folder (you definitely need the .inf and the .sys file but &lt;br /&gt;
maybe .cat or .dll helps too) with the windows drivers (e.g. DRIVERS containing&lt;br /&gt;
DELLNIC.inf and PRISMA02.sys)&lt;br /&gt;
&lt;br /&gt;
UHHH... check that, you actually first need the drivers for the Motherboard&lt;br /&gt;
USB Controller (ah Knoppix how could you let me down? :) &lt;br /&gt;
in this case: Silicon Integrated Systems Winxp/2k drivers for usb 2.0 &lt;br /&gt;
&lt;br /&gt;
Go into root shell (not just terminal console)&lt;br /&gt;
&lt;br /&gt;
Type 'lspci' at the prompt to see a listing of USB bridges (the way usb devices &lt;br /&gt;
get to the motherboard).  Look for your USB controller &lt;br /&gt;
(e.g. 00:03.0 USB Controller: Silicon Integrated Systems [SiS] uSB 1.0 Controller (rev 0f) etc.&lt;br /&gt;
&lt;br /&gt;
type: 	ndiswrapper -i filename.inf&lt;br /&gt;
&lt;br /&gt;
Hint you might have to type &lt;br /&gt;
&lt;br /&gt;
ndiswrapper -i /home/knoppix/tmp/DRIVER/DELLNIC.inf&lt;br /&gt;
&lt;br /&gt;
or first I learned I had to install&lt;br /&gt;
&lt;br /&gt;
ndiswrapper -i /home/knoppix/tmp/SiS/SISUSB2X.INF &lt;br /&gt;
&lt;br /&gt;
and &lt;br /&gt;
&lt;br /&gt;
ndiswrapper -i /home/knoppix/tmp/SiS/USB2X.INF &lt;br /&gt;
&lt;br /&gt;
I then tested it:&lt;br /&gt;
&lt;br /&gt;
ndiswrapper -l&lt;br /&gt;
&lt;br /&gt;
which showed me 'driver invalid' (But the USB was finally ok) so I had to remove the old one&lt;br /&gt;
(which also included browsing with root privileges to /etc/ndiswrapper and deleting the dellnic&lt;br /&gt;
folder)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
ndiswrapper -r /home/knoppix/tmp/DRIVER/DELLNIC.inf&lt;br /&gt;
&lt;br /&gt;
then  again type (actually for insurance I rename DELLNIC.INF to dellnic.inf):&lt;br /&gt;
&lt;br /&gt;
ndiswrapper -i /home/knoppix/tmp/DRIVER/dellnic.inf&lt;br /&gt;
&lt;br /&gt;
then finally:&lt;br /&gt;
&lt;br /&gt;
ndiswrapper -l&lt;br /&gt;
&lt;br /&gt;
showed me &lt;br /&gt;
dellnic: driver installed&lt;br /&gt;
	device (413C:8104) present&lt;br /&gt;
&lt;br /&gt;
I tested it and&lt;br /&gt;
&lt;br /&gt;
modprobe ndiswrapper&lt;br /&gt;
&lt;br /&gt;
came up without any response (before it gave me some crappy error)&lt;br /&gt;
but futher investigation&lt;br /&gt;
&lt;br /&gt;
dmesg | grep ndis&lt;br /&gt;
&lt;br /&gt;
gives me ndiswrapper version 1.32 loaded...&lt;br /&gt;
ndiswrapper: driver dellnic (...) loaded&lt;br /&gt;
usbcore: registered new interface driver ndiswrapper&lt;br /&gt;
&lt;br /&gt;
Now that we've installed the hardware we've got to get the software working...&lt;br /&gt;
&lt;br /&gt;
iwconfig&lt;br /&gt;
&lt;br /&gt;
shows me wlan0 is already setup!&lt;br /&gt;
Notice the interface name is wlan0, so you should issue the following command to associate to your &lt;br /&gt;
&lt;br /&gt;
nearest (unprotected, unencrypted) access point:&lt;br /&gt;
 &lt;br /&gt;
dhclient wlan0&lt;br /&gt;
&lt;br /&gt;
BUT in my case I need to start WPA Supplicant (necessary to use WirelessEncryptionProtocol)?&lt;br /&gt;
At least Knoppix button -&amp;gt; KNOPPIX menu -&amp;gt; Network/Internet -&amp;gt; Wireless LAN&lt;br /&gt;
Kwlan does a lot of the work but is incomplete - it doesn't have a quick gui to configure the WEP and everything so...&lt;br /&gt;
&lt;br /&gt;
iwconfig &lt;br /&gt;
&lt;br /&gt;
shows me how my wireless is working (IEEE, ESSID, Mode, Freq, AccessPoint, etc.)&lt;br /&gt;
but it doesn't configure anything by itself... instead:&lt;br /&gt;
&lt;br /&gt;
wlcardconfig&lt;br /&gt;
&lt;br /&gt;
starts a set of gui prompts which will configure my wireless:&lt;br /&gt;
ESSID (network name/id)		type in name&lt;br /&gt;
NWID (cell identifier?)		left blank&lt;br /&gt;
Mode				left blank (defaults to Managed)&lt;br /&gt;
channel number			left blank (defaults to auto)&lt;br /&gt;
frequency			left blank &lt;br /&gt;
encryption key			. . . . . .&lt;br /&gt;
&lt;br /&gt;
additional paramaters?&lt;br /&gt;
iwspy&lt;br /&gt;
iwpriv&lt;br /&gt;
&lt;br /&gt;
Which is close - but now I need an IP (since my AccessPoint does DHCP),&lt;br /&gt;
&lt;br /&gt;
pump -i wlan0&lt;br /&gt;
&lt;br /&gt;
gives me an ip address!  All finished.&lt;br /&gt;
&lt;br /&gt;
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -&lt;br /&gt;
&lt;br /&gt;
'''The below sections are specific information on specific make and models of Wireless Networking Adapters and  information we currently have on if they are supported in Knoppix or not. Please add your results with your card to the list, and please try to keep the list in alphabetical order. Please do not post questions about wireless adapters here, those should be submitted in the Networking Forum.'''&lt;br /&gt;
&lt;br /&gt;
==== Belkin ====&lt;br /&gt;
&lt;br /&gt;
===== Belkin 802.11b 11Mbps PCMCIA card F5D6020 =====&lt;br /&gt;
&lt;br /&gt;
This 802.11b pcmcia card (pc card) was detected by Knoppix 3.7 (maybe by prior versions too), but I could not get it to operate properly. Starting with Knoppix 3.8.1 it was detected and worked perfectly. ndiswrapper is not needed. My card is marked ver. 2101 on the box. If your card is not ver. 2101 it may or may not use a different chip set.&lt;br /&gt;
&lt;br /&gt;
==== D-Link ====&lt;br /&gt;
&lt;br /&gt;
Here is a link to a D-link page that claims to tell you which D-link cards have &amp;quot;open source&amp;quot; drivers and which do not.&lt;br /&gt;
&lt;br /&gt;
http://support.dlink.com/faq/view.asp?prod_id=357&amp;amp;question=General%20Wireless&lt;br /&gt;
&lt;br /&gt;
However, it is worth mentioning that in most or all of these cases the drivers are not really &amp;quot;open source&amp;quot;, they are precompiled modules that the source code is not available for. And in some cases they are insanely bloated, the &amp;quot;driver&amp;quot; for my card is about 2 megs in size just for a driver! Note that not all of these cards are supported by Knoppix and it is extremely unlikely that even if the license permits it that a sepcific card driver will ever be included in Knoppix if it is several megs in size.&lt;br /&gt;
&lt;br /&gt;
===== D-Link DWL-650 =====&lt;br /&gt;
&lt;br /&gt;
This is a very common and inexpensive 801.11b pcmcai card offered by D-link. Unfortunately, D-Link has actually released a number of different versions of this card that use completely different chipsets from different intigrated circuit manufacturers all under the same model number. The D-Link website can be used to identify which version you have, but the version number may not be marked on the outside of the box when you buy this card, so it may be a problem to find one that works under Knoppix.&lt;br /&gt;
&lt;br /&gt;
There are reports that some versions of this card are detected and work under Knoppix. See this thread in the forums: http://www.knoppix.net/forum/viewtopic.php?t=19759&amp;amp;highlight=dwl650&lt;br /&gt;
However, I have two DWL-650 cards and so far they have not been detected by Knoppix.&lt;br /&gt;
&lt;br /&gt;
===== D-Link DWL-G650 =====&lt;br /&gt;
&lt;br /&gt;
This section detais how to get this card working with WPA-PSK enabled. All you need to do is follow three easy steps.&lt;br /&gt;
&lt;br /&gt;
1. Configure wpa_supplicant by creating a configuration file. The configuration file should like something like this&lt;br /&gt;
&lt;br /&gt;
   network={&lt;br /&gt;
      ssid=&amp;quot;qshot&amp;quot;&lt;br /&gt;
      scan_ssid=0&lt;br /&gt;
      proto=WPA&lt;br /&gt;
      key_mgmt=WPA-PSK&lt;br /&gt;
      psk=20d57f08127c079f599df23a13513c8708028b73d49860c9b3b7d00b3a8c1a96&lt;br /&gt;
   }&lt;br /&gt;
&lt;br /&gt;
The psk variable value is obtained by running the command: &lt;br /&gt;
&lt;br /&gt;
   wpa_passphrase &amp;lt;ssid&amp;gt; &amp;lt;passphrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
2. Next start wpa_supplicant by invoking the following command: &lt;br /&gt;
&lt;br /&gt;
   wpa_supplicant -D madwifi -c wpa_supplicant.conf -i ath0 &lt;br /&gt;
&lt;br /&gt;
By runnning this command you are able to authenticate with your wireless router.&lt;br /&gt;
&lt;br /&gt;
3. After you have authenticated the final step is to obtain an IP address via DHCP. The command to use is: &lt;br /&gt;
&lt;br /&gt;
   pump -i ath0&lt;br /&gt;
&lt;br /&gt;
At this point you can type ''ifconfig'' to verify your IP address assignment.&lt;br /&gt;
&lt;br /&gt;
==== Orinoco Gold ====&lt;br /&gt;
&lt;br /&gt;
This was one of the first and best supported wireless 802.11b pcmcia cards under Linux. &lt;br /&gt;
It is still one of the best cards for compatability, not just with Linux, but with several networking programs that work under Linux like NETstumbler and airsnort. Unfortunately, it tends to be very overpriced and can usually not be found at major retailers, but must be obtained mail order, if available at all.&lt;br /&gt;
&lt;br /&gt;
==== Linksys ====&lt;br /&gt;
&lt;br /&gt;
===== Linksys WPC55AG =====&lt;br /&gt;
&lt;br /&gt;
Here is a link to a forum discussion about this card:&lt;br /&gt;
http://www.knoppix.net/forum/viewtopic.php?t=12351&lt;br /&gt;
&lt;br /&gt;
==== Netgear ====&lt;br /&gt;
&lt;br /&gt;
===== Netgear WG111 =====&lt;br /&gt;
&lt;br /&gt;
&amp;lt;b&amp;gt;Configuring the WG111 to use WPA-PSK on a wireless network&amp;lt;/b&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This card works very well in Knoppix 3.9 using ndiswrapper, but is as of yet untested in other versions of Knoppix (to my knowledge).&lt;br /&gt;
&lt;br /&gt;
*'''Commands:&lt;br /&gt;
Assuming that the drivers are on the cd in /dev/cdrom, then&lt;br /&gt;
 mount /dev/cdrom/ /mnt/cdrom/&lt;br /&gt;
&lt;br /&gt;
Find '''ndiswrapper configuration''' under Knoppix-&amp;gt;Network/Internet and select '''netwg111.inf''' from '''/mnt/cdrom'''.  After that finishes, create the configuration file that you will need shortly using the following command:&lt;br /&gt;
 wpa_passphrase MySSIDHere MyPassphraseHere &amp;gt; /home/knoppix/wpa_supplicant.conf &lt;br /&gt;
Now, use your favorite text editor (if you don't have one, try Kate under the menu item '''Editors''') and edit the&lt;br /&gt;
'''/home/knoppix/wpa_supplicant.conf''' you just created (see sample below).&lt;br /&gt;
&lt;br /&gt;
With that completed, run the following command. '''Warning:''' As it is, the command will monopolize your current command window with potentially useful debugging output, including your encryption key; add '''-B''' if you would rather run it in the background (useful when you know it works already), remove '''-K''' to hide your key.&lt;br /&gt;
 sudo wpa_supplicant -ddKt -i wlan0 -c /home/knoppix/wpa_supplicant.conf -Dndiswrapper&lt;br /&gt;
&lt;br /&gt;
The following grabs an IP address if you use DHCP from your router.&lt;br /&gt;
 sudo pump -i wlan0&lt;br /&gt;
&lt;br /&gt;
And finally, tell Knoppix where to go to find the internet.&lt;br /&gt;
 sudo route add default gw ''&amp;lt;Gateway/Router IP address here&amp;gt;'' &lt;br /&gt;
&lt;br /&gt;
*'''wpa_supplicant.conf&lt;br /&gt;
Note: the bold lines were added in the editing steps for my Linksys WRT54G Router to accept the card.  See the Useful Links at the end for a full explanation of all options that can be put in here.&lt;br /&gt;
 '''ctrl_interface=/home/knoppix/wpa_supplicant&lt;br /&gt;
 '''eapol_version=1&lt;br /&gt;
 '''ap_scan=1&lt;br /&gt;
 network={&lt;br /&gt;
 ssid=&amp;quot;MySSIDHere&amp;quot;&lt;br /&gt;
 '''scan_ssid=1&lt;br /&gt;
 #psk=&amp;quot;MyPassphraseHere&amp;quot;&lt;br /&gt;
 psk=''hex representation of the passphrase&lt;br /&gt;
 '''proto=WPA&lt;br /&gt;
 '''key_mgmt=WPA-PSK&lt;br /&gt;
 '''pairwise=TKIP&lt;br /&gt;
 '''group=TKIP&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
*'''Useful Links:&lt;br /&gt;
&lt;br /&gt;
[http://www.knoppix.net/forum/viewtopic.php?t=12351 Wireless card success story (where I located the ''pump'' command)]&lt;br /&gt;
&lt;br /&gt;
[http://hostap.epitest.fi/cgi-bin/viewcvs.cgi/*checkout*/hostap/wpa_supplicant/wpa_supplicant.conf?rev=HEAD&amp;amp;content-type=text/plain Example wpa_supplicant.conf with full explanations and various configurations]&lt;br /&gt;
&lt;br /&gt;
-bobeltomate&lt;br /&gt;
&lt;br /&gt;
tiscali broadband and networking home business uk only&lt;br /&gt;
unlimited 8mb from £6.49 per month. Earn money from promoting tiscali. &lt;br /&gt;
&lt;br /&gt;
http://www.tiscali-network.com/fastbroadband&lt;br /&gt;
&lt;br /&gt;
uk sites only please to test your service out....to see if i get any referrals directly from your postings&lt;br /&gt;
&lt;br /&gt;
thank you.&lt;/div&gt;</summary>
		<author><name>125.238.255.237</name></author>	</entry>

	<entry>
		<id>https://mail.knoppix.net/wiki/Bootable_USB_Key</id>
		<title>Bootable USB Key</title>
		<link rel="alternate" type="text/html" href="https://mail.knoppix.net/wiki/Bootable_USB_Key"/>
				<updated>2008-10-02T21:13:49Z</updated>
		
		<summary type="html">&lt;p&gt;125.238.255.237: revert&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Knoppix 5.0.1 boots rather nicely from a USB key. It's getting easier to get it working, as the USB bugs from the previous versions have been fixed.&lt;br /&gt;
&lt;br /&gt;
This is a &amp;quot;recipe&amp;quot; for creating a Knoppix bootable USB key.  It was originally posted to the forums: http://knoppix.net/forum/viewtopic.php?t=25402&lt;br /&gt;
&lt;br /&gt;
==Preparation==&lt;br /&gt;
&lt;br /&gt;
* Download a Knoppix image and burn it to CD or DVD.&lt;br /&gt;
&lt;br /&gt;
* Back up all data on your USB key, because we will be erasing and reformatting it!&lt;br /&gt;
&lt;br /&gt;
* Make sure U3 is not installed on the USB key&lt;br /&gt;
&lt;br /&gt;
Unfortunately, many newer USB keys come with &amp;quot;U3&amp;quot; Windows software ([http://www.digg.com/security/U3_USB_Flash_Drives_install_junk_on_any_Windows_PC_you_plug_into badware]?) preinstalled.  Removing U3 is highly recommended, and will free up additional space on your USB key, as well as eliminate a source of potential conflicts.&lt;br /&gt;
&lt;br /&gt;
Find a Windows machine, and try these programs to uninstall U3.  Unfortunately, they are a bit flaky.  If one does not work, try the other:&lt;br /&gt;
&lt;br /&gt;
http://www.sandisk.com/Assets/u3/launchpadremoval.exe&lt;br /&gt;
&lt;br /&gt;
http://www.u3.com/uninstall/&lt;br /&gt;
&lt;br /&gt;
To my knowledge, U3 has not yet been reverse-engineered, and the U3 vendors are secretive, so there's no way to manipulate it from Linux.&lt;br /&gt;
&lt;br /&gt;
The U3 removal software searches for a valid U3 installation before removing it!  There seems to be no way to just wipe U3 cleanly away, unfortunately.  You have to infect your computer with U3, in order to use their software to clean your USB key.  About the only workaround for this Catch-22 situation is to avoid purchasing a USB key with U3 in the first place.&lt;br /&gt;
&lt;br /&gt;
Newer SanDisk USB keys come with a built in uninstall application.  Try that first, before trying the above solutions.&lt;br /&gt;
&lt;br /&gt;
==Instructions==&lt;br /&gt;
&lt;br /&gt;
* Boot Knoppix 5.0.1 (or any later version) from CD, and make sure that it works.&lt;br /&gt;
&lt;br /&gt;
As soon as the title screen of Knoppix appears (the cheatcode entry screen), put in the USB key.&lt;br /&gt;
&lt;br /&gt;
Do this before Knoppix starts to load, so that your USB key is sure to be found by Knoppix's autodetection.&lt;br /&gt;
&lt;br /&gt;
Do not use the &amp;quot;toram&amp;quot; cheatcode when booting Knoppix. The RAM copy of the CD omits the /boot directory, but we require this directory, so we can't use the RAM copy.&lt;br /&gt;
&lt;br /&gt;
* Once Knoppix is up and running, open a root shell (from the penguin icon).&lt;br /&gt;
&lt;br /&gt;
Now, we need to find the drive letter of your USB key. It will be something like /dev/sda, /dev/sdb, /dev/sdc, and so on. Be very careful and make absolutely sure you have the drive letter correct, because you will be erasing the USB key, and you don't want to erase your hard drive by mistake!&lt;br /&gt;
&lt;br /&gt;
Examples of possible commands to try:&lt;br /&gt;
&lt;br /&gt;
 dmesg | grep -i scsi&lt;br /&gt;
&lt;br /&gt;
 dmesg | grep -i usb&lt;br /&gt;
&lt;br /&gt;
 cat /proc/partitions&lt;br /&gt;
&lt;br /&gt;
 fdisk -l&lt;br /&gt;
&lt;br /&gt;
 lsscsi -k&lt;br /&gt;
&lt;br /&gt;
Look at the sizes of the various drives you see here. Find your USB key, and do not get it confused with your hard drive! For the rest of this example, I'm going to be using ''/dev/sdz'', a fictional drive letter that nobody has, just to prevent bad mistakes from typing in commands blindly.&lt;br /&gt;
&lt;br /&gt;
; Note : If your USB stick is FAT-formatted and has enough free capacity, you can skip the following repartitioning phase and jump to installing SYSLINUX section. Just make sure your stick's partition has it's boot flag activated so the boot loader works properly. This can be done with the command fdisk /dev/sdz and subsequent commands (example: a 1 p w )&lt;br /&gt;
&lt;br /&gt;
; Note: If you're repeating your installation and have already zeroed your USB key at least once, then you can add ''count=1k'' to the line below.  It becomes ''dd if=/dev/zero of=/dev/sdz count=1k'' which will just zero out the first few sectors of your USB key.  This avoids wear and tear on your USB key, but still writes to enough sectors to clean out any existing formatting on your USB key.&lt;br /&gt;
&lt;br /&gt;
* Erase your entire USB key.&lt;br /&gt;
&lt;br /&gt;
 dd if=/dev/zero of=/dev/sdz&lt;br /&gt;
&lt;br /&gt;
Did you use the right drive letter? ''Did you?'' If not, you'll be crying, right about now....&lt;br /&gt;
&lt;br /&gt;
This command will take a while to finish. By writing to every block on the USB key, we are also testing it for bad blocks.&lt;br /&gt;
&lt;br /&gt;
You should get the &amp;quot;no space left on device&amp;quot; error message when it finishes erasing and reaches the end of the drive. Any other error messages might mean bad blocks: if you notice any, your key might be worn out and you'll need to buy another one (cheap keys are notorious for wearing out very quickly).&lt;br /&gt;
&lt;br /&gt;
* Run the mkdiskimage script, to automatically partition and format your USB key.&lt;br /&gt;
&lt;br /&gt;
Choose ''only one'' of these sections to try, based on the size of your USB key.&lt;br /&gt;
&lt;br /&gt;
If your USB key is exactly 1GB in size:&lt;br /&gt;
&lt;br /&gt;
 mkdiskimage -4 /dev/sdz 0 64 32&lt;br /&gt;
&lt;br /&gt;
Here are some alternatives you can try, for larger USB keys.  If the above command worked for your USB key, then you do not need to try these!  Simply proceed to the SYSLINUX step below.&lt;br /&gt;
&lt;br /&gt;
If your USB key is 2GB or less in size, but larger than 1GB:&lt;br /&gt;
&lt;br /&gt;
 mkdiskimage -4 /dev/sdz 0 128 32&lt;br /&gt;
&lt;br /&gt;
If your USB key is 8GB or less in size, but larger than 2GB:&lt;br /&gt;
&lt;br /&gt;
 mkdiskimage -F -4 /dev/sdz 0 255 63&lt;br /&gt;
&lt;br /&gt;
If your USB key is larger than 8GB in size (see cautions below):&lt;br /&gt;
&lt;br /&gt;
 mkdiskimage -F -4 /dev/sdz 1 255 63&lt;br /&gt;
 dd if=/dev/zero of=/dev/sdz bs=1 seek=446 count=64&lt;br /&gt;
 echo -e ',0\n,0\n,0\n,,C,*' | sfdisk /dev/sdz&lt;br /&gt;
 mkdosfs /dev/sdz4&lt;br /&gt;
&lt;br /&gt;
The final section above, for keys larger than 8GB, is rather tricky.  The mkdiskimage script can't handle partitions larger than 8GB, so I have to hack around it a bit.  What we are doing here is making a dummy partition of only 1MB(!) in size, so that mkdiskimage can prepare the MBR properly.  Then, we manually delete that partition, by doing some surgery in the partition table.  We then use sfdisk to re-create the partition properly, using the full size of your USB key as FAT32, and finally format it with mkdosfs.&lt;br /&gt;
&lt;br /&gt;
Please be very careful typing in the command(s) in your section above.  If using the final section for keys larger than 8GB, the 0's in the echo command above are zeroes, not the letter O, and please be sure to use single quotes instead of double quotes.  This should work for all USB storage devices, up to 2TB in size.  I tested this using a 320GB USB hard drive, and it worked.  Beyond 2TB, you're on your own....&lt;br /&gt;
&lt;br /&gt;
This lays down a new MBR and partition table on the drive, and partitions and formats the entire drive as one big partition, either FAT16 or FAT32. Even though I prefer FAT32, I'm still recommending FAT16 for smaller keys, for increased compatibility with some strange BIOS's.&lt;br /&gt;
&lt;br /&gt;
The mkdiskimage script is USB-ZIP compliant, which may help it boot on more systems than USB-HDD. It's nice that Knoppix now includes this script by default. Here's the webpage for mkdiskimage, for additional reference: &lt;br /&gt;
&lt;br /&gt;
http://syslinux.zytor.com/usbkey.php&lt;br /&gt;
&lt;br /&gt;
* Close KDE's popup window.&lt;br /&gt;
&lt;br /&gt;
KDE may throw a stupid popup window in your face, once it recognizes your new partition.&lt;br /&gt;
If this happens, close the window.&lt;br /&gt;
&lt;br /&gt;
* Run the SYSLINUX installer on your new partition.&lt;br /&gt;
&lt;br /&gt;
 syslinux -s /dev/sdz4&lt;br /&gt;
&lt;br /&gt;
This installs the SYSLINUX bootloader onto the newly-created partition, and includes a special file, ldlinux.sys. The -s option is for safety and additional compatibility, although if you want your USB key to boot a little faster, you can omit the -s option.  Notice the partition is the fourth partition on the drive, not the first. This is for USB-ZIP compliance.&lt;br /&gt;
&lt;br /&gt;
* Mount your new partition.&lt;br /&gt;
&lt;br /&gt;
 mount /dev/sdz4 /media/sdz4&lt;br /&gt;
&lt;br /&gt;
Although Knoppix should have autodetected the new partition and set up a fstab entry for it, Knoppix's fstab options are incorrect.  So, by giving both the device and the mountpoint directory on the command line, we mount it manually, with no options. The /media/sdz4 directory should now correspond to the /dev/sdz4 partition.&lt;br /&gt;
&lt;br /&gt;
 cd /media/sdz4&lt;br /&gt;
 ls&lt;br /&gt;
&lt;br /&gt;
You should notice one, and only one, file in this directory now: ''ldlinux.sys''&lt;br /&gt;
&lt;br /&gt;
If you don't see this, then something probably went wrong earlier. Go back and try again before continuing.&lt;br /&gt;
&lt;br /&gt;
* Copy the contents of the Knoppix CD's boot directory, onto your USB key.&lt;br /&gt;
&lt;br /&gt;
You should already be in the ''/media/sdz4'' directory, from the cd command above.&lt;br /&gt;
&lt;br /&gt;
 rsync -av /cdrom/boot/isolinux/ ./&lt;br /&gt;
 mv isolinux.cfg syslinux.cfg&lt;br /&gt;
 rm -f isolinux.bin&lt;br /&gt;
&lt;br /&gt;
This copies all files from /cdrom/boot/isolinux/ to the current directory (the rsync command is an improvement over the cp command for handling large amounts of files, as it is better at handling errors).  Ignore any warnings about &amp;quot;failed to preserve ownership&amp;quot;. This is normal, because we're using the FAT filesystem, which does not support file ownership. This is not a problem for us.&lt;br /&gt;
&lt;br /&gt;
What we're doing here is copying the Knoppix CD's /boot directory first. This increases reliability, by getting it as close to the beginning of the drive as possible. This should help on systems with buggy CHS handling of USB keys, which may become an issue as new USB keys get larger.&lt;br /&gt;
&lt;br /&gt;
We are renaming Knoppix's isolinux.cfg file to syslinux.cfg, and then removing the unnecessary isolinux.bin file. ISOLINUX (used to boot the CD) and SYSLINUX (what we just installed to your USB key) are really two different variations of the same bootloader program. They accept the same config file format, so we don't need to change anything at all, just rename.&lt;br /&gt;
&lt;br /&gt;
BTW, since ISOLINUX has isolinux.bin as its main program file, can you guess what is the equivalent file for SYSLINUX? If you guessed ldlinux.sys, the file you saw earlier, good job!&lt;br /&gt;
&lt;br /&gt;
* Finish copying the rest of the Knoppix CD.&lt;br /&gt;
&lt;br /&gt;
Again, you should still be in the ''/media/sdz4'' directory. Again, don't forget the dot on the end of the rsync command.&lt;br /&gt;
&lt;br /&gt;
 rsync -av /cdrom/ ./ --exclude boot&lt;br /&gt;
&lt;br /&gt;
This should take a while -- we are filling up the USB key with the contents of the Knoppix CD. The excluded &amp;quot;boot&amp;quot; directory was already copied earlier.&lt;br /&gt;
&lt;br /&gt;
If, during the copy, it asks if you want to overwrite the files ''cdrom.ico'' and ''index.html'', say Yes.  This message appears because in later Knoppix versions, these files were doubled-up on the Knoppix CD (possibly a bug).&lt;br /&gt;
&lt;br /&gt;
* You are now ready to boot!&lt;br /&gt;
&lt;br /&gt;
Cleanly unmount the USB key.&lt;br /&gt;
&lt;br /&gt;
 sync&lt;br /&gt;
 cd /&lt;br /&gt;
 umount /media/sdz4&lt;br /&gt;
 sync&lt;br /&gt;
&lt;br /&gt;
Shut down Knoppix, and remove the CD when it tells you to.&lt;br /&gt;
&lt;br /&gt;
* Reset your computer and fiddle with the BIOS until it sees the USB key.&lt;br /&gt;
&lt;br /&gt;
After unmounting above, the USB key can be removed. Some BIOS's require a removal and re-insertion before they will recognize it.&lt;br /&gt;
&lt;br /&gt;
Other things to try, if you're having trouble getting the BIOS to see your USB key and let you boot from it:&lt;br /&gt;
&lt;br /&gt;
# Try a different USB port. Some BIOS's only search a few ports, not all of them.  Avoid using a USB hub, if possible.&lt;br /&gt;
# Hit a special key to bring up a boot menu. Some BIOS's can only boot from USB when manually selected.&lt;br /&gt;
# Go into your BIOS's setup menu, and walk through the boot settings. Look under all menus, especially &amp;quot;hard drives&amp;quot; and &amp;quot;removable devices&amp;quot; and other things like that. Some BIOS's will not search for newly attached devices until you manually go through the menus again.&lt;br /&gt;
# Enable &amp;quot;USB Keyboard and Legacy Support&amp;quot; if it is disabled.&lt;br /&gt;
# Turn your computer completely off and on again. Some BIOS's require you to physically turn the computer off and on again, before they will see newly attached &amp;quot;hard drives&amp;quot;.&lt;br /&gt;
# If all else fails, try a different PC. It's still fairly rare these days to find a computer that has a good ability to boot from USB devices, and it's not something that motherboard makers advertise, so it takes a bit of luck to find a computer that can do this.&lt;br /&gt;
&lt;br /&gt;
* Boot into Knoppix from your USB key.&lt;br /&gt;
&lt;br /&gt;
The USB key will be slow to load at first, especially during the cheatcode screen, because most BIOS's will default to running USB devices in a very slow mode.  Once Knoppix detects and autoconfigures the USB port during booting, though, it will return to normal speed.&lt;br /&gt;
&lt;br /&gt;
If it works, that's great. Notice how much faster it is. There's zero seek time on a USB key, so even though it isn't very fast, it feels a lot faster than the CD. Programs are surprisingly quick to load.&lt;br /&gt;
&lt;br /&gt;
Find the drive letter for your USB key again. It should not change, but it might have.&lt;br /&gt;
&lt;br /&gt;
* Make the USB key writeable.&lt;br /&gt;
&lt;br /&gt;
Knoppix assumes that the &amp;quot;CD-ROM&amp;quot; that it booted from is impossible to write to, but we have a USB key now, not a CD-ROM. So, we must fool Knoppix into letting you write to it.&lt;br /&gt;
&lt;br /&gt;
 mount -o remount,rw /cdrom&lt;br /&gt;
 mount --bind /cdrom /media/sdz4&lt;br /&gt;
&lt;br /&gt;
* Optional step: Modify the Knoppix boot menu&lt;br /&gt;
&lt;br /&gt;
This is an optional step, for customization. We want Knoppix to autofind the persistent home directory (once we make it), and fix a few other things.&lt;br /&gt;
&lt;br /&gt;
 vi /media/sdz4/syslinux.cfg&lt;br /&gt;
&lt;br /&gt;
On line 3, the default timeout is 300. Lower this, to around 50 or so (5 seconds, since this counter is in tenths of seconds).&lt;br /&gt;
&lt;br /&gt;
It's nice to have it boot faster, without waiting for you to hit Enter, so you can put in the USB key and walk away, coming back in a few minutes to a fully booted system.&lt;br /&gt;
&lt;br /&gt;
On line 2, add a few more options to the end of the line.&lt;br /&gt;
&lt;br /&gt;
 noswap noeject noprompt dma home=scan&lt;br /&gt;
&lt;br /&gt;
Here's a little explanation of what each option does.&lt;br /&gt;
&lt;br /&gt;
; noswap : Security fix: assuming you're going to be using the USB key on a bunch of different computers you don't own, you don't want to be swapping your memory onto their hard drives.&lt;br /&gt;
; noeject : You can't physically eject a USB key.&lt;br /&gt;
; noprompt : Gets rid of the &amp;quot;remove CD and close drive door&amp;quot; prompt when shutting down, as this prompt is rather misleading when it's really a USB key instead.&lt;br /&gt;
; dma : Gets you a significant speed increase when dealing with many IDE drives, a good thing to have.&lt;br /&gt;
; home=scan : This will cause Knoppix to pick up your persistent home directory automatically the next time you boot up, asking you for the password as needed. You will get an extra menu during bootup, asking you if you want to mount your home directory or not.&lt;br /&gt;
&lt;br /&gt;
Save the file and quit the editor.&lt;br /&gt;
&lt;br /&gt;
* Optional step: Create a Knoppix persistent home directory&lt;br /&gt;
&lt;br /&gt;
Now, we can run the Knoppix persistent utility, to create something that will save your settings across a reboot.&lt;br /&gt;
&lt;br /&gt;
(It's under the penguin menu, Configure, Create Persistent.)&lt;br /&gt;
&lt;br /&gt;
Choose your drive from the menu that appears, and follow the instructions.&lt;br /&gt;
&lt;br /&gt;
When making your encrypted persistent home directory, choose a size that is a good balance.  I recommend not using the entire remaining space on the USB key.  It's handy to have some extra free space, for quick file copying and such.  Also, if you have a large USB key with roughly 260MB of free space or more, and need to also work under Windows, you can install PortableApps (see below).&lt;br /&gt;
&lt;br /&gt;
The program should complete without errors. If the program suddenly disappears midway through, check the kernel logs with &amp;quot;dmesg&amp;quot; again. If you see pagefuls of SCSI errors and such, beware, you might have a worn-out USB key!&lt;br /&gt;
&lt;br /&gt;
==You're done!==&lt;br /&gt;
&lt;br /&gt;
Now, you should be all set. Reboot again, to make sure it all works.&lt;br /&gt;
&lt;br /&gt;
Enjoy your Knoppix-on-a-keychain!&lt;br /&gt;
&lt;br /&gt;
Josh&lt;br /&gt;
&lt;br /&gt;
--[[User:Krellan|Krellan]] 00:43, 10 Sep 2006 (GMT)&lt;br /&gt;
&lt;br /&gt;
==Large USB keys==&lt;br /&gt;
&lt;br /&gt;
The mkdiskimage command is very sensitive to the size of your USB key.  I have included several variations to try, in the above article.  Here are some more alternatives, for completeness.&lt;br /&gt;
&lt;br /&gt;
These will break USB-ZIP compatibility, as it is a USB-ZIP requirement to have 64 heads and 32 sectors.  Unfortunately, there is no other way, as a valid cylinder count (less than 1024) is also a requirement.  So, try USB-HDD instead of USB-ZIP.  The tradeoff is that it won't be as compatible with as many BIOS's as USB-ZIP.&lt;br /&gt;
&lt;br /&gt;
 mkdiskimage -4 /dev/sdz 0 255 63&lt;br /&gt;
&lt;br /&gt;
This will allow you to partition a USB key up to 8GB in size.  You probably could also use 256 heads instead of 255, for a little more space, but 255 heads is recommended, as it's slightly more compatible.&lt;br /&gt;
&lt;br /&gt;
You may then run into the 2GB limit of the FAT16 partition.  Beyond 2GB, it is probably best to use FAT32 instead.  Supply the -F option to mkdiskimage.&lt;br /&gt;
&lt;br /&gt;
 mkdiskimage -F -4 /dev/sdz 0 255 63&lt;br /&gt;
&lt;br /&gt;
At first, I did recommend FAT32 for all users: http://www.knoppix.net/forum/viewtopic.php?t=25402&lt;br /&gt;
&lt;br /&gt;
However, it did not work on as many BIOS's, so I now recommend FAT16, unless you have a USB key that is larger than the 2GB limit of FAT16.&lt;br /&gt;
&lt;br /&gt;
The other instructions on the page above should still be valid.  Only the mkdiskimage command line needs to be changed, for use with large keys.&lt;br /&gt;
&lt;br /&gt;
--[[User:Krellan|Krellan]] 20:30, 19 Oct 2006 (GMT)&lt;br /&gt;
&lt;br /&gt;
==PortableApps==&lt;br /&gt;
&lt;br /&gt;
Here's also something great I found.  If you have roughly 260MB or more of free space remaining on your USB key, you might want to drop PortableApps on there.&lt;br /&gt;
&lt;br /&gt;
http://portableapps.com/suite&lt;br /&gt;
&lt;br /&gt;
http://portableapps.com/&lt;br /&gt;
&lt;br /&gt;
This is a suite of freeware Windows utilities, and will help you if you need to do work within Windows without being able to reboot into Knoppix.  Much better and cleaner than U3!&lt;br /&gt;
&lt;br /&gt;
When installing PortableApps to a USB key that already has Knoppix on it, PortableApps will complain about overwriting the autorun.inf file.  This is fine.  Say Yes to the overwrite.  This will allow the USB key to bring up the PortableApps menu, instead of the Knoppix homepage, when clicking on it from within Windows.&lt;br /&gt;
&lt;br /&gt;
With a 1GB key formatted as FAT16, as per the above instructions, there is, unfortunately, just barely not enough room for both Knoppix and the full PortableApps suite to coexist.  The workaround is to &amp;quot;install&amp;quot; PortableApps to a spare empty folder on your hard drive first.  Make edits to that folder as necessary, deleting some apps you can live without.  Then, copy the entire folder manually to your USB key from there.&lt;br /&gt;
&lt;br /&gt;
Formatting as FAT32 will work, as FAT32 is more efficient at cramming in the thousands of small files PortableApps creates.  A larger USB key will provide much more room for both Knoppix and PortableApps, and enough extra left over for a decently-sized Knoppix home directory as well.  See above for alternate mkdiskimage command lines you can try, when formatting larger USB keys or using FAT32.&lt;br /&gt;
&lt;br /&gt;
--[[User:Krellan|Krellan]] 19:23, 27 Nov 2006 (GMT)&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
There is an another project based on PortableApps, with the addition of [http://tor.eff.org/ TOR-networking] enabled by default. This makes it possible to anonymize web surfing at the cost of speed.&lt;br /&gt;
&lt;br /&gt;
More info at http://www.democrakey.com/&lt;br /&gt;
&lt;br /&gt;
--[[User:Neva|Neva]] 18:54, 20 Jun 2007 (GMT)&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
mkdiskimage won't set up a 2 gb USB device with the USB-ZIP format using the example given. According to other FAQ's this is an issue with too many cylinders. A 1 gb drive is supposed to work fine. You may be able to manually create two drives on the device and manually format it in order to set it up as USB-ZIP.&lt;br /&gt;
&lt;br /&gt;
Depending on the USB device, you can use fdisk to figure out the cylinders, heads and sectors and get mkdiskimage to work with these values. The one I used had 1015 cylinders, 64 heads and 62 sectors per track -- these values worked fine and I was able to create a bootable Knoppix USB key.&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
I was able to use this guide to setup and boot from Knoppix on a Creative Zen Vision:M MP3 player. Details here: http://www.francisshanahan.com/detail.aspx?cid=509&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
For the Cylinders/Head/Sectors issue, an easy way to find the information is simply type:&lt;br /&gt;
&amp;lt;code&amp;gt;hdparm /dev/sd?&amp;lt;/code&amp;gt;&lt;br /&gt;
Where '?' is the drive letter. It will output the &amp;quot;Geometry: x/y/z&amp;quot; where X=Cylinders, Y=Heads, Z=Sectors. Enter those in for the last three variables on the mkdiskimage command and you are all set.&lt;br /&gt;
&lt;br /&gt;
--[[User:Geekner|Geekner]] 18:53, 7 Oct 2007 (UTC)&lt;br /&gt;
&lt;br /&gt;
When running Knoppix 5.1.1, and booting from your USB key, sometimes udev hardware detection will fail, or lock up entirely.  This is strange, and I don't know why this happens.  This doesn't happen when booting from the original CD.&lt;br /&gt;
&lt;br /&gt;
The workaround is to use the &amp;quot;noudev&amp;quot; cheatcode.  However, when using this cheatcode, fewer of your peripherals will be detected correctly.  It's better than having the system lock up, though.  If this cheatcode is necessary for you, consider editing it into your ''syslinux.cfg'' file as described above, so that you won't need to enter it every time.&lt;br /&gt;
&lt;br /&gt;
--[[User:Krellan|Krellan]] 10:55, 18 Oct 2007 (UTC)&lt;br /&gt;
&lt;br /&gt;
[[Category:Booting]]&lt;/div&gt;</summary>
		<author><name>125.238.255.237</name></author>	</entry>

	<entry>
		<id>https://mail.knoppix.net/wiki/Bootable_USB_Key</id>
		<title>Bootable USB Key</title>
		<link rel="alternate" type="text/html" href="https://mail.knoppix.net/wiki/Bootable_USB_Key"/>
				<updated>2008-10-01T20:49:33Z</updated>
		
		<summary type="html">&lt;p&gt;125.238.255.237: revert&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Knoppix 5.0.1 boots rather nicely from a USB key. It's getting easier to get it working, as the USB bugs from the previous versions have been fixed.&lt;br /&gt;
&lt;br /&gt;
This is a &amp;quot;recipe&amp;quot; for creating a Knoppix bootable USB key.  It was originally posted to the forums: http://knoppix.net/forum/viewtopic.php?t=25402&lt;br /&gt;
&lt;br /&gt;
==Preparation==&lt;br /&gt;
&lt;br /&gt;
* Download a Knoppix image and burn it to CD or DVD.&lt;br /&gt;
&lt;br /&gt;
* Back up all data on your USB key, because we will be erasing and reformatting it!&lt;br /&gt;
&lt;br /&gt;
* Make sure U3 is not installed on the USB key&lt;br /&gt;
&lt;br /&gt;
Unfortunately, many newer USB keys come with &amp;quot;U3&amp;quot; Windows software ([http://www.digg.com/security/U3_USB_Flash_Drives_install_junk_on_any_Windows_PC_you_plug_into badware]?) preinstalled.  Removing U3 is highly recommended, and will free up additional space on your USB key, as well as eliminate a source of potential conflicts.&lt;br /&gt;
&lt;br /&gt;
Find a Windows machine, and try these programs to uninstall U3.  Unfortunately, they are a bit flaky.  If one does not work, try the other:&lt;br /&gt;
&lt;br /&gt;
http://www.sandisk.com/Assets/u3/launchpadremoval.exe&lt;br /&gt;
&lt;br /&gt;
http://www.u3.com/uninstall/&lt;br /&gt;
&lt;br /&gt;
To my knowledge, U3 has not yet been reverse-engineered, and the U3 vendors are secretive, so there's no way to manipulate it from Linux.&lt;br /&gt;
&lt;br /&gt;
The U3 removal software searches for a valid U3 installation before removing it!  There seems to be no way to just wipe U3 cleanly away, unfortunately.  You have to infect your computer with U3, in order to use their software to clean your USB key.  About the only workaround for this Catch-22 situation is to avoid purchasing a USB key with U3 in the first place.&lt;br /&gt;
&lt;br /&gt;
Newer SanDisk USB keys come with a built in uninstall application.  Try that first, before trying the above solutions.&lt;br /&gt;
&lt;br /&gt;
==Instructions==&lt;br /&gt;
&lt;br /&gt;
* Boot Knoppix 5.0.1 (or any later version) from CD, and make sure that it works.&lt;br /&gt;
&lt;br /&gt;
As soon as the title screen of Knoppix appears (the cheatcode entry screen), put in the USB key.&lt;br /&gt;
&lt;br /&gt;
Do this before Knoppix starts to load, so that your USB key is sure to be found by Knoppix's autodetection.&lt;br /&gt;
&lt;br /&gt;
Do not use the &amp;quot;toram&amp;quot; cheatcode when booting Knoppix. The RAM copy of the CD omits the /boot directory, but we require this directory, so we can't use the RAM copy.&lt;br /&gt;
&lt;br /&gt;
* Once Knoppix is up and running, open a root shell (from the penguin icon).&lt;br /&gt;
&lt;br /&gt;
Now, we need to find the drive letter of your USB key. It will be something like /dev/sda, /dev/sdb, /dev/sdc, and so on. Be very careful and make absolutely sure you have the drive letter correct, because you will be erasing the USB key, and you don't want to erase your hard drive by mistake!&lt;br /&gt;
&lt;br /&gt;
Examples of possible commands to try:&lt;br /&gt;
&lt;br /&gt;
 dmesg | grep -i scsi&lt;br /&gt;
&lt;br /&gt;
 dmesg | grep -i usb&lt;br /&gt;
&lt;br /&gt;
 cat /proc/partitions&lt;br /&gt;
&lt;br /&gt;
 fdisk -l&lt;br /&gt;
&lt;br /&gt;
 lsscsi -k&lt;br /&gt;
&lt;br /&gt;
Look at the sizes of the various drives you see here. Find your USB key, and do not get it confused with your hard drive! For the rest of this example, I'm going to be using ''/dev/sdz'', a fictional drive letter that nobody has, just to prevent bad mistakes from typing in commands blindly.&lt;br /&gt;
&lt;br /&gt;
; Note : If your USB stick is FAT-formatted and has enough free capacity, you can skip the following repartitioning phase and jump to installing SYSLINUX section. Just make sure your stick's partition has it's boot flag activated so the boot loader works properly. This can be done with the command fdisk /dev/sdz and subsequent commands (example: a 1 p w )&lt;br /&gt;
&lt;br /&gt;
; Note: If you're repeating your installation and have already zeroed your USB key at least once, then you can add ''count=1k'' to the line below.  It becomes ''dd if=/dev/zero of=/dev/sdz count=1k'' which will just zero out the first few sectors of your USB key.  This avoids wear and tear on your USB key, but still writes to enough sectors to clean out any existing formatting on your USB key.&lt;br /&gt;
&lt;br /&gt;
* Erase your entire USB key.&lt;br /&gt;
&lt;br /&gt;
 dd if=/dev/zero of=/dev/sdz&lt;br /&gt;
&lt;br /&gt;
Did you use the right drive letter? ''Did you?'' If not, you'll be crying, right about now....&lt;br /&gt;
&lt;br /&gt;
This command will take a while to finish. By writing to every block on the USB key, we are also testing it for bad blocks.&lt;br /&gt;
&lt;br /&gt;
You should get the &amp;quot;no space left on device&amp;quot; error message when it finishes erasing and reaches the end of the drive. Any other error messages might mean bad blocks: if you notice any, your key might be worn out and you'll need to buy another one (cheap keys are notorious for wearing out very quickly).&lt;br /&gt;
&lt;br /&gt;
* Run the mkdiskimage script, to automatically partition and format your USB key.&lt;br /&gt;
&lt;br /&gt;
Choose ''only one'' of these sections to try, based on the size of your USB key.&lt;br /&gt;
&lt;br /&gt;
If your USB key is exactly 1GB in size:&lt;br /&gt;
&lt;br /&gt;
 mkdiskimage -4 /dev/sdz 0 64 32&lt;br /&gt;
&lt;br /&gt;
Here are some alternatives you can try, for larger USB keys.  If the above command worked for your USB key, then you do not need to try these!  Simply proceed to the SYSLINUX step below.&lt;br /&gt;
&lt;br /&gt;
If your USB key is 2GB or less in size, but larger than 1GB:&lt;br /&gt;
&lt;br /&gt;
 mkdiskimage -4 /dev/sdz 0 128 32&lt;br /&gt;
&lt;br /&gt;
If your USB key is 8GB or less in size, but larger than 2GB:&lt;br /&gt;
&lt;br /&gt;
 mkdiskimage -F -4 /dev/sdz 0 255 63&lt;br /&gt;
&lt;br /&gt;
If your USB key is larger than 8GB in size (see cautions below):&lt;br /&gt;
&lt;br /&gt;
 mkdiskimage -F -4 /dev/sdz 1 255 63&lt;br /&gt;
 dd if=/dev/zero of=/dev/sdz bs=1 seek=446 count=64&lt;br /&gt;
 echo -e ',0\n,0\n,0\n,,C,*' | sfdisk /dev/sdz&lt;br /&gt;
 mkdosfs /dev/sdz4&lt;br /&gt;
&lt;br /&gt;
The final section above, for keys larger than 8GB, is rather tricky.  The mkdiskimage script can't handle partitions larger than 8GB, so I have to hack around it a bit.  What we are doing here is making a dummy partition of only 1MB(!) in size, so that mkdiskimage can prepare the MBR properly.  Then, we manually delete that partition, by doing some surgery in the partition table.  We then use sfdisk to re-create the partition properly, using the full size of your USB key as FAT32, and finally format it with mkdosfs.&lt;br /&gt;
&lt;br /&gt;
Please be very careful typing in the command(s) in your section above.  If using the final section for keys larger than 8GB, the 0's in the echo command above are zeroes, not the letter O, and please be sure to use single quotes instead of double quotes.  This should work for all USB storage devices, up to 2TB in size.  I tested this using a 320GB USB hard drive, and it worked.  Beyond 2TB, you're on your own....&lt;br /&gt;
&lt;br /&gt;
This lays down a new MBR and partition table on the drive, and partitions and formats the entire drive as one big partition, either FAT16 or FAT32. Even though I prefer FAT32, I'm still recommending FAT16 for smaller keys, for increased compatibility with some strange BIOS's.&lt;br /&gt;
&lt;br /&gt;
The mkdiskimage script is USB-ZIP compliant, which may help it boot on more systems than USB-HDD. It's nice that Knoppix now includes this script by default. Here's the webpage for mkdiskimage, for additional reference: &lt;br /&gt;
&lt;br /&gt;
http://syslinux.zytor.com/usbkey.php&lt;br /&gt;
&lt;br /&gt;
* Close KDE's popup window.&lt;br /&gt;
&lt;br /&gt;
KDE may throw a stupid popup window in your face, once it recognizes your new partition.&lt;br /&gt;
If this happens, close the window.&lt;br /&gt;
&lt;br /&gt;
* Run the SYSLINUX installer on your new partition.&lt;br /&gt;
&lt;br /&gt;
 syslinux -s /dev/sdz4&lt;br /&gt;
&lt;br /&gt;
This installs the SYSLINUX bootloader onto the newly-created partition, and includes a special file, ldlinux.sys. The -s option is for safety and additional compatibility, although if you want your USB key to boot a little faster, you can omit the -s option.  Notice the partition is the fourth partition on the drive, not the first. This is for USB-ZIP compliance.&lt;br /&gt;
&lt;br /&gt;
* Mount your new partition.&lt;br /&gt;
&lt;br /&gt;
 mount /dev/sdz4 /media/sdz4&lt;br /&gt;
&lt;br /&gt;
Although Knoppix should have autodetected the new partition and set up a fstab entry for it, Knoppix's fstab options are incorrect.  So, by giving both the device and the mountpoint directory on the command line, we mount it manually, with no options. The /media/sdz4 directory should now correspond to the /dev/sdz4 partition.&lt;br /&gt;
&lt;br /&gt;
 cd /media/sdz4&lt;br /&gt;
 ls&lt;br /&gt;
&lt;br /&gt;
You should notice one, and only one, file in this directory now: ''ldlinux.sys''&lt;br /&gt;
&lt;br /&gt;
If you don't see this, then something probably went wrong earlier. Go back and try again before continuing.&lt;br /&gt;
&lt;br /&gt;
* Copy the contents of the Knoppix CD's boot directory, onto your USB key.&lt;br /&gt;
&lt;br /&gt;
You should already be in the ''/media/sdz4'' directory, from the cd command above.&lt;br /&gt;
&lt;br /&gt;
 rsync -av /cdrom/boot/isolinux/ ./&lt;br /&gt;
 mv isolinux.cfg syslinux.cfg&lt;br /&gt;
 rm -f isolinux.bin&lt;br /&gt;
&lt;br /&gt;
This copies all files from /cdrom/boot/isolinux/ to the current directory (the rsync command is an improvement over the cp command for handling large amounts of files, as it is better at handling errors).  Ignore any warnings about &amp;quot;failed to preserve ownership&amp;quot;. This is normal, because we're using the FAT filesystem, which does not support file ownership. This is not a problem for us.&lt;br /&gt;
&lt;br /&gt;
What we're doing here is copying the Knoppix CD's /boot directory first. This increases reliability, by getting it as close to the beginning of the drive as possible. This should help on systems with buggy CHS handling of USB keys, which may become an issue as new USB keys get larger.&lt;br /&gt;
&lt;br /&gt;
We are renaming Knoppix's isolinux.cfg file to syslinux.cfg, and then removing the unnecessary isolinux.bin file. ISOLINUX (used to boot the CD) and SYSLINUX (what we just installed to your USB key) are really two different variations of the same bootloader program. They accept the same config file format, so we don't need to change anything at all, just rename.&lt;br /&gt;
&lt;br /&gt;
BTW, since ISOLINUX has isolinux.bin as its main program file, can you guess what is the equivalent file for SYSLINUX? If you guessed ldlinux.sys, the file you saw earlier, good job!&lt;br /&gt;
&lt;br /&gt;
* Finish copying the rest of the Knoppix CD.&lt;br /&gt;
&lt;br /&gt;
Again, you should still be in the ''/media/sdz4'' directory. Again, don't forget the dot on the end of the rsync command.&lt;br /&gt;
&lt;br /&gt;
 rsync -av /cdrom/ ./ --exclude boot&lt;br /&gt;
&lt;br /&gt;
This should take a while -- we are filling up the USB key with the contents of the Knoppix CD. The excluded &amp;quot;boot&amp;quot; directory was already copied earlier.&lt;br /&gt;
&lt;br /&gt;
If, during the copy, it asks if you want to overwrite the files ''cdrom.ico'' and ''index.html'', say Yes.  This message appears because in later Knoppix versions, these files were doubled-up on the Knoppix CD (possibly a bug).&lt;br /&gt;
&lt;br /&gt;
* You are now ready to boot!&lt;br /&gt;
&lt;br /&gt;
Cleanly unmount the USB key.&lt;br /&gt;
&lt;br /&gt;
 sync&lt;br /&gt;
 cd /&lt;br /&gt;
 umount /media/sdz4&lt;br /&gt;
 sync&lt;br /&gt;
&lt;br /&gt;
Shut down Knoppix, and remove the CD when it tells you to.&lt;br /&gt;
&lt;br /&gt;
* Reset your computer and fiddle with the BIOS until it sees the USB key.&lt;br /&gt;
&lt;br /&gt;
After unmounting above, the USB key can be removed. Some BIOS's require a removal and re-insertion before they will recognize it.&lt;br /&gt;
&lt;br /&gt;
Other things to try, if you're having trouble getting the BIOS to see your USB key and let you boot from it:&lt;br /&gt;
&lt;br /&gt;
# Try a different USB port. Some BIOS's only search a few ports, not all of them.  Avoid using a USB hub, if possible.&lt;br /&gt;
# Hit a special key to bring up a boot menu. Some BIOS's can only boot from USB when manually selected.&lt;br /&gt;
# Go into your BIOS's setup menu, and walk through the boot settings. Look under all menus, especially &amp;quot;hard drives&amp;quot; and &amp;quot;removable devices&amp;quot; and other things like that. Some BIOS's will not search for newly attached devices until you manually go through the menus again.&lt;br /&gt;
# Enable &amp;quot;USB Keyboard and Legacy Support&amp;quot; if it is disabled.&lt;br /&gt;
# Turn your computer completely off and on again. Some BIOS's require you to physically turn the computer off and on again, before they will see newly attached &amp;quot;hard drives&amp;quot;.&lt;br /&gt;
# If all else fails, try a different PC. It's still fairly rare these days to find a computer that has a good ability to boot from USB devices, and it's not something that motherboard makers advertise, so it takes a bit of luck to find a computer that can do this.&lt;br /&gt;
&lt;br /&gt;
* Boot into Knoppix from your USB key.&lt;br /&gt;
&lt;br /&gt;
The USB key will be slow to load at first, especially during the cheatcode screen, because most BIOS's will default to running USB devices in a very slow mode.  Once Knoppix detects and autoconfigures the USB port during booting, though, it will return to normal speed.&lt;br /&gt;
&lt;br /&gt;
If it works, that's great. Notice how much faster it is. There's zero seek time on a USB key, so even though it isn't very fast, it feels a lot faster than the CD. Programs are surprisingly quick to load.&lt;br /&gt;
&lt;br /&gt;
Find the drive letter for your USB key again. It should not change, but it might have.&lt;br /&gt;
&lt;br /&gt;
* Make the USB key writeable.&lt;br /&gt;
&lt;br /&gt;
Knoppix assumes that the &amp;quot;CD-ROM&amp;quot; that it booted from is impossible to write to, but we have a USB key now, not a CD-ROM. So, we must fool Knoppix into letting you write to it.&lt;br /&gt;
&lt;br /&gt;
 mount -o remount,rw /cdrom&lt;br /&gt;
 mount --bind /cdrom /media/sdz4&lt;br /&gt;
&lt;br /&gt;
* Optional step: Modify the Knoppix boot menu&lt;br /&gt;
&lt;br /&gt;
This is an optional step, for customization. We want Knoppix to autofind the persistent home directory (once we make it), and fix a few other things.&lt;br /&gt;
&lt;br /&gt;
 vi /media/sdz4/syslinux.cfg&lt;br /&gt;
&lt;br /&gt;
On line 3, the default timeout is 300. Lower this, to around 50 or so (5 seconds, since this counter is in tenths of seconds).&lt;br /&gt;
&lt;br /&gt;
It's nice to have it boot faster, without waiting for you to hit Enter, so you can put in the USB key and walk away, coming back in a few minutes to a fully booted system.&lt;br /&gt;
&lt;br /&gt;
On line 2, add a few more options to the end of the line.&lt;br /&gt;
&lt;br /&gt;
 noswap noeject noprompt dma home=scan&lt;br /&gt;
&lt;br /&gt;
Here's a little explanation of what each option does.&lt;br /&gt;
&lt;br /&gt;
; noswap : Security fix: assuming you're going to be using the USB key on a bunch of different computers you don't own, you don't want to be swapping your memory onto their hard drives.&lt;br /&gt;
; noeject : You can't physically eject a USB key.&lt;br /&gt;
; noprompt : Gets rid of the &amp;quot;remove CD and close drive door&amp;quot; prompt when shutting down, as this prompt is rather misleading when it's really a USB key instead.&lt;br /&gt;
; dma : Gets you a significant speed increase when dealing with many IDE drives, a good thing to have.&lt;br /&gt;
; home=scan : This will cause Knoppix to pick up your persistent home directory automatically the next time you boot up, asking you for the password as needed. You will get an extra menu during bootup, asking you if you want to mount your home directory or not.&lt;br /&gt;
&lt;br /&gt;
Save the file and quit the editor.&lt;br /&gt;
&lt;br /&gt;
* Optional step: Create a Knoppix persistent home directory&lt;br /&gt;
&lt;br /&gt;
Now, we can run the Knoppix persistent utility, to create something that will save your settings across a reboot.&lt;br /&gt;
&lt;br /&gt;
(It's under the penguin menu, Configure, Create Persistent.)&lt;br /&gt;
&lt;br /&gt;
Choose your drive from the menu that appears, and follow the instructions.&lt;br /&gt;
&lt;br /&gt;
When making your encrypted persistent home directory, choose a size that is a good balance.  I recommend not using the entire remaining space on the USB key.  It's handy to have some extra free space, for quick file copying and such.  Also, if you have a large USB key with roughly 260MB of free space or more, and need to also work under Windows, you can install PortableApps (see below).&lt;br /&gt;
&lt;br /&gt;
The program should complete without errors. If the program suddenly disappears midway through, check the kernel logs with &amp;quot;dmesg&amp;quot; again. If you see pagefuls of SCSI errors and such, beware, you might have a worn-out USB key!&lt;br /&gt;
&lt;br /&gt;
==You're done!==&lt;br /&gt;
&lt;br /&gt;
Now, you should be all set. Reboot again, to make sure it all works.&lt;br /&gt;
&lt;br /&gt;
Enjoy your Knoppix-on-a-keychain!&lt;br /&gt;
&lt;br /&gt;
Josh&lt;br /&gt;
&lt;br /&gt;
--[[User:Krellan|Krellan]] 00:43, 10 Sep 2006 (GMT)&lt;br /&gt;
&lt;br /&gt;
==Large USB keys==&lt;br /&gt;
&lt;br /&gt;
The mkdiskimage command is very sensitive to the size of your USB key.  I have included several variations to try, in the above article.  Here are some more alternatives, for completeness.&lt;br /&gt;
&lt;br /&gt;
These will break USB-ZIP compatibility, as it is a USB-ZIP requirement to have 64 heads and 32 sectors.  Unfortunately, there is no other way, as a valid cylinder count (less than 1024) is also a requirement.  So, try USB-HDD instead of USB-ZIP.  The tradeoff is that it won't be as compatible with as many BIOS's as USB-ZIP.&lt;br /&gt;
&lt;br /&gt;
 mkdiskimage -4 /dev/sdz 0 255 63&lt;br /&gt;
&lt;br /&gt;
This will allow you to partition a USB key up to 8GB in size.  You probably could also use 256 heads instead of 255, for a little more space, but 255 heads is recommended, as it's slightly more compatible.&lt;br /&gt;
&lt;br /&gt;
You may then run into the 2GB limit of the FAT16 partition.  Beyond 2GB, it is probably best to use FAT32 instead.  Supply the -F option to mkdiskimage.&lt;br /&gt;
&lt;br /&gt;
 mkdiskimage -F -4 /dev/sdz 0 255 63&lt;br /&gt;
&lt;br /&gt;
At first, I did recommend FAT32 for all users: http://www.knoppix.net/forum/viewtopic.php?t=25402&lt;br /&gt;
&lt;br /&gt;
However, it did not work on as many BIOS's, so I now recommend FAT16, unless you have a USB key that is larger than the 2GB limit of FAT16.&lt;br /&gt;
&lt;br /&gt;
The other instructions on the page above should still be valid.  Only the mkdiskimage command line needs to be changed, for use with large keys.&lt;br /&gt;
&lt;br /&gt;
--[[User:Krellan|Krellan]] 20:30, 19 Oct 2006 (GMT)&lt;br /&gt;
&lt;br /&gt;
==PortableApps==&lt;br /&gt;
&lt;br /&gt;
Here's also something great I found.  If you have roughly 260MB or more of free space remaining on your USB key, you might want to drop PortableApps on there.&lt;br /&gt;
&lt;br /&gt;
http://portableapps.com/suite&lt;br /&gt;
&lt;br /&gt;
http://portableapps.com/&lt;br /&gt;
&lt;br /&gt;
This is a suite of freeware Windows utilities, and will help you if you need to do work within Windows without being able to reboot into Knoppix.  Much better and cleaner than U3!&lt;br /&gt;
&lt;br /&gt;
When installing PortableApps to a USB key that already has Knoppix on it, PortableApps will complain about overwriting the autorun.inf file.  This is fine.  Say Yes to the overwrite.  This will allow the USB key to bring up the PortableApps menu, instead of the Knoppix homepage, when clicking on it from within Windows.&lt;br /&gt;
&lt;br /&gt;
With a 1GB key formatted as FAT16, as per the above instructions, there is, unfortunately, just barely not enough room for both Knoppix and the full PortableApps suite to coexist.  The workaround is to &amp;quot;install&amp;quot; PortableApps to a spare empty folder on your hard drive first.  Make edits to that folder as necessary, deleting some apps you can live without.  Then, copy the entire folder manually to your USB key from there.&lt;br /&gt;
&lt;br /&gt;
Formatting as FAT32 will work, as FAT32 is more efficient at cramming in the thousands of small files PortableApps creates.  A larger USB key will provide much more room for both Knoppix and PortableApps, and enough extra left over for a decently-sized Knoppix home directory as well.  See above for alternate mkdiskimage command lines you can try, when formatting larger USB keys or using FAT32.&lt;br /&gt;
&lt;br /&gt;
--[[User:Krellan|Krellan]] 19:23, 27 Nov 2006 (GMT)&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
There is an another project based on PortableApps, with the addition of [http://tor.eff.org/ TOR-networking] enabled by default. This makes it possible to anonymize web surfing at the cost of speed.&lt;br /&gt;
&lt;br /&gt;
More info at http://www.democrakey.com/&lt;br /&gt;
&lt;br /&gt;
--[[User:Neva|Neva]] 18:54, 20 Jun 2007 (GMT)&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
mkdiskimage won't set up a 2 gb USB device with the USB-ZIP format using the example given. According to other FAQ's this is an issue with too many cylinders. A 1 gb drive is supposed to work fine. You may be able to manually create two drives on the device and manually format it in order to set it up as USB-ZIP.&lt;br /&gt;
&lt;br /&gt;
Depending on the USB device, you can use fdisk to figure out the cylinders, heads and sectors and get mkdiskimage to work with these values. The one I used had 1015 cylinders, 64 heads and 62 sectors per track -- these values worked fine and I was able to create a bootable Knoppix USB key.&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
I was able to use this guide to setup and boot from Knoppix on a Creative Zen Vision:M MP3 player. Details here: http://www.francisshanahan.com/detail.aspx?cid=509&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
For the Cylinders/Head/Sectors issue, an easy way to find the information is simply type:&lt;br /&gt;
&amp;lt;code&amp;gt;hdparm /dev/sd?&amp;lt;/code&amp;gt;&lt;br /&gt;
Where '?' is the drive letter. It will output the &amp;quot;Geometry: x/y/z&amp;quot; where X=Cylinders, Y=Heads, Z=Sectors. Enter those in for the last three variables on the mkdiskimage command and you are all set.&lt;br /&gt;
&lt;br /&gt;
--[[User:Geekner|Geekner]] 18:53, 7 Oct 2007 (UTC)&lt;br /&gt;
&lt;br /&gt;
When running Knoppix 5.1.1, and booting from your USB key, sometimes udev hardware detection will fail, or lock up entirely.  This is strange, and I don't know why this happens.  This doesn't happen when booting from the original CD.&lt;br /&gt;
&lt;br /&gt;
The workaround is to use the &amp;quot;noudev&amp;quot; cheatcode.  However, when using this cheatcode, fewer of your peripherals will be detected correctly.  It's better than having the system lock up, though.  If this cheatcode is necessary for you, consider editing it into your ''syslinux.cfg'' file as described above, so that you won't need to enter it every time.&lt;br /&gt;
&lt;br /&gt;
--[[User:Krellan|Krellan]] 10:55, 18 Oct 2007 (UTC)&lt;br /&gt;
&lt;br /&gt;
[[Category:Booting]]&lt;/div&gt;</summary>
		<author><name>125.238.255.237</name></author>	</entry>

	</feed>