IBM Thinkpad with USB CDROM
From DSL Wiki
My old IBM Thinkpad 570E has no removable-media drives. What does that remind you of? Yes, and like a netbook it also has limited memory (64Mb) and hard disk (11Gb). These were decent specs when new and it cost a lot of money. It came with Windows 98 installed and a separate USB CDROM R/W drive. It also has an external floppy disk with a cable that plugs into a dedicated socket.
I decided to upgrade it to Windows XP, so I put the installation CD in the drive and ran setup. Things proceeded as normal until the first reboot, when the computer could no longer understand its USB port and the CDROM drive attached to it. It simply halted with a hard disk error. I could boot from a "Windows Startup" floppy disk, but Windows was gone, the CDROM was a myth, and I had only a few DOS tools.
You don't want to hear about all the blind alleys I went up before I found my way here, so I will just tell you how I got the brick to see its USB CDROM and install DSL. I am not a Linux person, but worked with command line MSDOS for many years (and CP/M before that) so was not quelled by the elitism that drips from most Linux websites. Just don't ask them any questions and you will be fine.
I will be mentioning a lot of programs and utilities, but won't be providing the links to where they can be found. That's because I was driven crazy by great recommendations for various things coupled to links that no longer worked. Use a web search engine to find current links to download these things (if you don't want your searches tracked and recorded, try www.ixquick.com). I did not have to pay for anything, and you shouldn't either. The DSL files can be found on many mirrors linked from www.damnsmalllinux.org.
First, I had to install DOS onto the hard disk so it would boot. Well, actually I probably didn't have to. I could have just booted from a floppy, but I went with the hard drive. You haven't bricked your Thinkpad, but you may want to clear Windows off of it, and the process is the same. You boot from a DOS system floppy and format the hard disk with the /s switch. Unfortunately, the format program is not included on the usual "Windows startup" floppy, so unless you have it in your collection of old disks, you will have to find one on the net, or get freedos. You will probably stumble over mismatched versions of Format and the DOS version you have. Early versions of Format and Fdisk probably won't be able to cope with the "large" size of the Thinkpad's hard disk either. The Windows 98 version of DOS and utilities worked for me. I have them on an old Win98 installation CD. The "Windows startup" floppy from a Windows XP install identifies it's DOS version (type ver at the command line) as "Millenium", and that may need different versions of the utilities. You will also find that a DOS file editor will be useful. I use TED.
You may want to use Fdisk to repartition the drive, with a small first partition for DOS and necessary installation space, leaving the rest of the disk for the eventual Linux filesystem. I used a utility called Presizer for that, but Fdisk is fine too. You only need to Fdisk and Format the first partition, and it only needs to be big enough to hold the DSL image with some slack. Presizer wouldn't go smaller than 657 Mb, but 128Mb or 80Mb is plenty. The DSL installation has a utility to set up the Linux partitions so you do that later.
Next you need to get the computer to recognise the USB CDROM drive. There are DOS drivers that will do this. They are called:
usbaspi.sys recognises the USB drive usbcd.sys assigns a drive letter shsucdx.com alternative to the standard DOS mscdex.com
These ones work specifically with my IBM Thinkpad and the Acer 4406EU USB CDRW that came with it. You may have a different CDROM drive, perhaps a genuine IBM one if your vendor wasn't doing things on the cheap. There are other drivers for accessing USB drives in DOS, such as the DUSE ones, but they didn't work for me. There is also a driver to recognise USB hard drives called:
di1000dd.sys
I haven't tried that, but if you have no USB CDROM drive, you might be able to use that with a USB hard drive to transfer the DSL image to your internal drive.
Your config.sys and autoexec.bat files on your DOS boot disk (either floppy or hard) should contain these lines:
config.sys:
device=usbaspi.sys device=usbcd.sys /d:usbcdrom
autoexec.bat:
shsucdx /d:usbcdrom
Now when you boot, the CDROM drive will be accessible, with a drive letter like any other drive. However, you won't be able to boot from it, as it doesn't exist until after dos has booted and loaded the drivers. So, once you have downloaded the DSL CD image and burned it to a CD (using another computer obviously), you still can't use the CD as it stands. You have to do a "poor man" install initially, or maybe it is a "frugal" install. There are a couple of .PDF files in the DSL ftp files repositories that have useful information about this, like FrugalHowto.pdf, but we are going for a full HD install eventually.
I downloaded the dsl-4.4.10-syslinux.iso image file, because it is supposed to be more tolerant of older kit. You need to burn this image to a CD, using a burner that knows how to do iso images. Just copying it will NOT do.
Actually, I found that one of my Windows ZIP utilities could look inside this image file and extract things from it, so you can avoid burning the CD image if you think it will be easier. You still need to find a way to get the required files onto the Thinkpad's internal drive though. I transferred a lot of files with an RS232 null-modem cable and two terminal programs when I was still trying to install windows. Took 40 hours.
Once you have burned the image to a CD, you will find the CD has two directories and an html file on it. In the KNOPPIX directory, there is a floppy disk boot image called boot.img. You need to make a floppy disk with that boot image on it. Or you can find this image on the DSL mirror sites, or you can boot the DSL Live CD on another machine and use the utility in it to copy the image onto a floppy.
When you boot the Thinkpad from that floppy, it will not be able to see the USB CDROM drive, so you must first copy the KNOPPIX directory from the CD onto the Thinkpad's hard disk after booting from the disk with the usbaspi drivers. There are only three files in the KNOPPIX directory and no subdirectories, so you can copy them with the DOS Copy command and wildcards. Use the DOS MD command to make the directory (DOS will make the names all caps automatically):
c: rem makes sure you are on the C: drive cd\ rem makes sure you are in the root directory of C: md knoppix rem create directory copy d:\knoppix\*.* c:\knoppix rem copies all files
So now you have a boot floppy with the boot.img from the CD and a copy of the KNOPPIX directory on the Thinkpad's hard disk (C:). Boot from the floppy and the DSL splash screen will come up. If you press enter, or just wait, it will continue into a portable DSL session, but it is awkward to have to boot from a floppy all the time, so we want to install the system on the hard disk. To do this, type "install" at the prompt and then hit enter.
This will take you to the installation menu. I got additional error messages under this menu, because of a wireless network card I had plugged in, but just went ahead and typed the option number, which worked.
The first thing you do there is make at least one Linux partition in the large part of the disk you cleared out earlier. You could use the whole hard disk, but we had to use part of it to hold the KNOPPIX directory in order to get this far, and if you lose that you may regret it later when you have to do the install over (I installed several times before I got it right). Apparently you will want at least two Linux partitions, a big one for most uses and a smaller one for memory swapping. The partition set up utility is option 10 on the menu. Select that and then answer "hda" for the hard disk.
I set up my partitions like this:
hda1 Boot Primary Win95 FAT32 (LBA) 674.48 hda2 Boot Primary Linux 10001.95 hda5 Logical Linux swap 1390.08
The first is just what was there when I started the utility. The second is what I got when I selected "new" and specified primary and 10000 Mb. I then made it bootable with the bootable toggle. The hda numbers are assigned automatically. The third is what I got when I specified the rest of the disk and logical (sometimes referred to elsewhere as "secondary"), and then set the type to 82 with the "Type" button.
The utility complains about two partitions being set bootable, that DOS boot won't know what to do about it, but we are going to use grub to select what to boot at boot up time anyway. Maybe the hda2 Linux partition doesn't have to be bootable, and maybe the hda1 bootable partition ought really be a Linux one, but this works. Another wrinkle, merely having a Linux swap partition seems not be enough to use a swap partition. There is an additional command referred to in the frugal how to pdf, but that can be done later.
Remember to use the "write" button to write the partitions before you quit, or nothing will happen. Now I think you need to reboot (again from the floppy) for the partitions to be recognised.
Enter the install menu again like before, and select option 2 for hard disk install, and then hda2 for the partition (if that is the partition number assigned to the bootable Linux partition on your drive). When you get to "Proceed to install a boot loader" be careful with the return key. You need to enter a "y" and you can't easily go back if you press return and get the default "n". Then select Grub. I tried Lilo and it didn't work, your mileage may vary.
If you want to be able to boot the DOS partition, answer "y" on the next option "Do you have Windows installed on the first partition". If you don't do this, the DOS boot can only be done with a floppy, though the partition will be accessible. Now it asks for another reboot (just like a Windows install!). Remove the floppy (it says remove the CD, but we are using a floppy) before you reboot. Grub will come up and you can select which boot options to use, with several screen resolutions. I select 1024*768.
Now you will be prompted for passwords for root and users. I set up for only one user on a previous prompt. I got additional error messages under the password prompts again, but just went ahead and typed. You get no echo, not even asterisks, but if you make a mistake you just get a new prompt.
And up comes the DSL screen. You can now boot without the floppy. You have a netbook, assuming you can get some kind of wireless PCMCIA card or dongle to work. I have just seen a PCMCIA mobile broadband card on sale, so might try that. The wireless network one I have is capable of WPA encryption under windows with additional drivers, but DSL only seems to ask for a WEP key, which is not what my home network is using.
And yes, the swap file- I started a terminal session ("Term" on the bottom bar) and entered:
sudo mkswap /dev/hda5 sudo swapon /dev/hda5 (then exit to close the session)
And now the status panel is showing that I have a swapfile in use. This is important for performance in small memory machines.