Booting Linux on an old i586 Pentium MMX

This was essentially the first PC I bought for my own money. It came with Windows 95 preinstalled, but I refused to pay for it (and didn't have to) so I didn't get any activation code. Now since ever installed with Linux.

I recently (early 2013) wanted to run it again to access some old ISA XT boards with MFM disk controllers to read out data stashed on an old MiniScribe drive. This requires no distro, although I used to run Puppy Linux on it for a while, now that distro will not even work on this Pentium MMX, and that's supposed to be a low-end distro! So I compiled a custom RAM disk like I usually do for my embedded system, and up it comes. Process like this:

There is a lot you can do with a simple ramdisk image, like turning the machine into a router, if you compile in the right drivers. Any embedded task can be done actually. And you don't even have to have a hard disk in the machine.

Reading a MiniScribe 8425 MFM disk under Linux

I did the above Linux ramdisk image for one specific purpose: to read the contents off an old MFM drive, a MiniScribe 8425 with a DTC 5150X controller card, the latter 8bit XT ISA.

To get the DTC card working with Linux I had to do two things:

Recovering the contents of the drive: if there are no errors on the drive, first blitz all contents off the XD drive with busybox' dd command like so:

dd if=/dev/xda of=/mnt/miniscribe.img conv=noerror,sync

If you're unlucky, like me, there are errors on the disk. Then we need to extract as much as we can save! So we use GNU ddrescue, which will iterativly help you to cause pain to your harddisk by reading back and forth and attempting to extract as much from the drive as possible. I had to recompile this and hand-edit the source code to get it to compile... And then I ran it off that image etc. (It's included on the image above.)

Since this is a hard disk with 615 cylinders, 4 heads and 17 sectors per track, each sector 512 bytes, we should expect to end up with a file of 21411840 bytes.

Examining the old MiniScribe image

So now we have disk image, containing a partition, so let's extract the partition information

$ parted miniscribe-2.img
GNU Parted 3.1
Använder /home/linus/miniscribe-2.img
Välkommen till GNU Parted! Skriv "hjälp" för att visa en lista över kommandon.
(parted) unit
Enhet?  [compact]? B
(parted) print
Modell:  (file)
Disk /home/linus/miniscribe-2.img: 21411840B
Sektorstorlek (logisk/fysisk): 512B/512B
Partitionstabell: msdos
Disk Flags:

Nummer  Början  Slut       Storlek    Typ      Filsystem  Flaggor
 1      95744B  21377023B  21281280B  primary  fat16      startbar

OK the partition (only one on these old drives) start at 95744, so let's try to mount it:

$ mount -o loop,ro,offset=95744 miniscribe-2.img /mnt/disk/
$ ls -al /mnt/disk
totalt 194
drwxr-xr-x. 3 root root 16384  1 jan  1970 .
drwxr-xr-x. 1 root root    38 12 feb 19.13 ..
-rwxr-xr-x. 1 root root 50456 23 aug  1991 COMMAND.COM
-rwxr-xr-x. 1 root root    68  1 jan  1980 DCONFIG.SYS
-rwxr-xr-x. 1 root root  1583 23 aug  1991 DEVSWAP.COM
-r-xr-xr-x. 1 root root 21232  1 jan  1980 DISKMAP.DAT
drwxr-xr-x. 2 root root  2048  1 jan  1980 DOS
-r-xr-xr-x. 1 root root 24442 23 aug  1991 IBMBIO.COM
-r-xr-xr-x. 1 root root 39239 23 aug  1991 IBMDOS.COM
-rwxr-xr-x. 1 root root 35327 23 aug  1991 SSTORDRV.SYS

Aha, so a SuperStor compressed drive that has not been used since august 1991. From the names of the files and the dates we can conclude that this is installed with DR-DOS Version 6.0. We conclude this by seeing the IBM 3.3 marker at the beginning of the partition tell us it is version 5 or later, and we know that the 6.0 version bundled the SuperStor compression scheme came out in September 1991, and these dates on the files give at hand that it is indeed version 6.0, surely that version of DR-DOS may have been compiled and timestamped in august, 1991.

If you can't even mount the drive, next thing you do is to run PhotoRec on the image to extract any lost files right off from the disk image. It will usually find a lot of files, then you have to sift through them. In this case it would not work: the photorec algorithm is pretty simplistic, and the SUPERSTOR drive is compressed, it will not find many files there.

So we actually need to boot this image to be able to get the data out. (It did recover some text fragments that just happened to be in some swap sector.)

Luckily I could find all 6 floppies of DR-DOS 6.0 online, so I did not have to try to dig up these.

One possibility to access the compressed data directly uding DMSDOS if this compression scheme is applicable also for the SuperStor drives. However Doublespace/Drivespace/Stacker seem to keep one big file named DBLSPACE.001 on the drive and I have nothing like that. It appears to install compression deeply so it is directly embedded into the boot process, hence the spartan root dir.