My Linux Toy -- the Libretto 50CT

This is probably extremely boring unless you are trying to install Debian on a Libretto and are looking for documentation from people who have somehow managed to get it to work.

This one might be especially valuable if you don't know anything about Linux because neither do I and I managed to get it working.

I hate screwdrivers, hardware, and getting my fingers greasy.

On the other hand, if you're wondering what this is about, perhaps you should check out the links section below.


If you want to read as little as possible, skip down to the Debian part. This is a bit chatty.

I bought my Libretto second-hand -- third hand, actually -- without any floppy drive whatsoever, scarce documentation, and only American keycaps (and an American warranty, if you can call it a warranty).

After about five hours of use, the old hard drive in it died. It was still under warranty, but the Finnish Toshiba agent wouldn't touch it with a 10-meter pole. So much for worldwide warranty.

I got a new 2-gig drive (whee) and struggled for about two months (yes, two months) with it before I finally got everything running. (Don't let that scare you -- most of that was because I was busy having a merry Christmas and a happy new year. All in all, getting the thing running only took about three evenings and most of that was reading docs and waiting for installations to complete.)

The way it was done

Here's a blow-by-blow account of what I did.
  1. Partition the hard drive on DOS with a 500-meg DOS partition, leaving the other 1.5 megs completely untouched.
  2. Install Windows 95 on the DOS partition by putting the hard drive in a second computer with a CD drive, copying everything I could fit onto the hard drive, and moving the drive back.
  3. Move assorted other stuff I had forgotten to copy, or that I needed to get off the 'Net, over a serial link. Windows HyperTerminal sucks, but at least it has ZModem and Kermit. (I've seen more terminal programs than I care to remember that lacked either or both.)
  4. Find and install the network card driver (download to the computer I had connected to over a serial line, then zip it over using HyperTerminal).
  5. Finally connect the Windows side to the Internet and download the Debian package.
  6. I partitioned the drive (this is part of the Debian install procedure, but it makes sense to put this note here) into a smallish root partition and a largish /usr (and of course an unused partition near the end where the Lib can save the contents of its head when it goes to sleep ... I have 32 megs of memory but I couldn't make a partition smaller than around 39.5 megs for this). This was just gleaned from one of the installation "howtos" I found on the Internet. But in retrospect this arrangement wasn't so wise; I've had to rearrange things a little bit because I managed to fill up the root partition pretty quickly; it contains /var (where dpkg puts downloaded packages -- I like to keep them around after I've installed them just in case) and /home and of course /tmp. If you're like me, one or more of those should be separate from the root partition (unless of course you go for just one partition for the whole system).
  7. I gleaned the following DOS command line from a Japanese web page about installing Debian 1.x on a Libretto. I'm not altogether sure where I found it, or how (given that I don't even have the stuff to display the Japanese characters correctly, never mind that I couldn't read them if I did) but here's the command line I used to start up Loadlin the first time:
    	loadlin linux root=/dev/ram initrd=root.bin
    The first parameter is the full path to the kernel you want to boot; I had Loadlin, the kernel, root.bin and all the other stuff in the same directory but you might want to go for a cleaner setup. (And let's hope you will be more successful than I was at finding up-to-date documentation for Loadlin.)
  8. Run the Debian installer. This was a breeze. However, something screwed up the partition table for me at one point, so I redid this part (actually all the way back to formatting the hard drive and reinstalling Windows ... yuck) another time.
  9. You will want to install some packages before the system is actually useful for anything.
  10. The default Debian kernel you installed doesn't come with APM support, so you will want to compile your own kernel. I actually ran the "out of the box" kernel for a long time before I got around to doing this myself, and put up with living without APM, but it was a real hassle. Basically, it seems that every time you put the computer to sleep, the APM routines will throw an interrupt which Linux normally doesn't know how to handle, and you get a (very meaningful) "divide by zero" panic. Until you get the APM kernel, in practice you will have to shut down Linux when you want to turn off the computer and reboot Linux when you start it up. So go build the APM kernel, you won't want to look back.
  11. Enjoy. Repeat. Enjoy.
I've been using Loadlin and it works just fine. I never boot into Windows anymore anyhow, but I want to have the possibility -- mostly in case my wife would want to do word processing on the road (as if I'd let her! :-) There is an annoying note that "Windows is starting your MS-DOS mode program" when you boot the computer but that means you can press Esc to get into Windows if you really need to. Probably LILO wouldn't be hard to use at all but I have better things to do than fool around with the startup stuff. What I have works for me. (And anyhow I rarely reboot -- I just put the machine to sleep when I'm done using it.)

For what it's worth, here's the Loadlin command line I'm using now:

	loadlin zimage root=/dev/hda5
where zimage is the name of the new kernel I compiled (it's in Loadlin's working directory; otherwise you will need a full path) and hda5 is my Linux root partition. (I hope I got this right -- this was gleaned with less from the Unix side, and those DOS PIF files aren't exactly human-readable. No way I would reboot into Windows just to verify this :-)

In case you've never seen this in practice, when you attempt to start this program, Windows will ask you if you are sure you want to shut down everything else and restart the computer in, well, DOS mode. If you say yes, it will sort of arrange to pull away the carpet from under its own feet after the reboot, at which point the MS-DOS program will run with full control over the computer (and in this case then load and boot Linux).

What I think I should still do is somehow create a bootable PCMCIA card for emergency situations in case I'd ever need to do this whole procedure over again. (Actually I guess I'd try to get the card to boot directly into Linux.)


Some sites you should probably know about: The above listing doesn't necessarily list all the references that I found the most helpful. Stay tuned -- I'll try to remember to import stuff from bookmark files I have scattered all over the place here at some point.

In the end, the reference I relied on the most was Debian's installation instructions although I wouldn't have known e.g. how to access the BIOS of the Lib (remember, no docs with this second-hand unit) or to set up a sleep partition if I hadn't also cruised around all those Libretto sites too.

$Id: libretto.prep,v 1.20 1999/09/30 15:55:48 era Exp $
[Registered Linux User #142090 ... Register yourself!]                      [Debian GNU/Linux]                      [Best Viewed in Emacs]