On the road to X11

This is going to be.. involved to do… But there is some hope. The source to X11 R5 is still online, even though the xfree86-1.2 stuff is long gone. I was able to find a binary 2 bit Xserver for 386BSD, so that’s promising.

So my hope would now lay in making up a configuration file that’ll satisfy the Xfree86 1.2 server, and build enough of X11R5 to where it’s able to do something….

I have no idea if it’s even that easy to do, but if anyone has any leads on a source copy of xfree86-1.2 or 1.3 that’d probably be easier to build for 386BSD as it was used in the time frame… 2.0 was for the forks of NetBSD & FreeBSD so no doubt it’d hinge on things like DLL’s…

In the meantime, you can check out Neils Horn’s blog, with an example of what Xfree86 1.x was capable of on 0.96 linux.. Back in the day.

HTTPD 1.3

Well I was looking for a way to move data out of the 386BSD vm without too much pain, and I’ve just been hitting this brick wall about trying to compile apache.

You see the thing is, 386BSD is so old, it doesn’t have dynamic libraries, and a uname command so you have to ‘fool’ the configure scripts, and even then if you do manage to get an executable it’ll just crash… For some reason gdb couldn’t help with the whole thing… very annoying. I think it may be a program size limit..? Either way, I’m sure it was ‘fixed’ in NetBSD 0.8 ..

So after googling around the ancient news groups, I came across this post..

NCSA httpd 1.1/1.2/1.3 compile straight (well almost) out of the box. I’ve not tried the CERN one yet. I’m happy with my NCSA 1.3.

Well, now that’s interesting… Remember that NCSA gave us Mosaic, but they also gave us httpd, which apache is based on. However NCSA no longer hosts the httpd source code… It’s gone with the wind…. Except for this Slackware mirror.

So after downloading it, and building, naturally…. it crashed. However this time I was able to fire up GDB, and see that it was crashing in the mime initialization… It seems it was using a null pointer… So for the heck of it, I changed the hash macro to use the 2nd definition, and it worked!!

So after all of that, I built some stuff for 386BSD to test the transfer of the web server, and it “seems” ok to me… Naturally I wouldn’t expect this to withstand any large amounts of traffic as it doesn’t seem to fork itself… I also suspect this version may work with the VAX 4.X BSD stuff as well…

httpd-1.3
com (CP/M emulator)
GNUMake-3.75
Frotz-2.32
screen-3.7.1
gcc-2.5.8
bash-1.14.7
bash-2.0

It is kind of scary how this old software is disappearing, and at the same time, we hear this promise of how we can keep everything forever in the “digital age”… At any rate, I guess this preserves a somewhat usable OS/Webserver configuration circa 1993…

Back to 386 BSD

Well gunkies is getting a little more life to it, and Dugo contributed this install guide for 386 BSD. Along the way I installed it again with floppy images, and I hit the same fault again:

/386bsd: wd0a: overlaps open partition (b)

However this time I noticed that if you keep on rebooting, it’ll actually stop complaining and work!

So not only was I able to recover from a crash after trying to install the source code, but I was able to complete the install, and install the patchkits! What this has resulted in, is that Qemu can now run 386BSD!!! And it’s significantly faster then Bochs. Not to mention you gain the whole SLiRP / Usermode networking.

So far I’ve tested this with Qemu-0.11.0 just fine. I’m not sure about other levels… so it’s another YMMV.

So now I’ve been able to not only rebuild the kernel & world, but the following programs:

gzip 1.2.4
unzip 5.52
irc II-4.4
lynx 2.8.2

Oh yeah, and another f2c build, and yes it’ll run Dungeon!

So for the few people interested in some BSD history, as this is the ‘first’ Net/2 derived freely available release in a qemu format right here (sorry, link removed, if you want it install this instead).

Just uncompress the qcow2 file (sorry it’ll blow out to 500MB), then run Qemu something like this:

i386-softmmu/qemu.exe -L pc-bios -hda bsd386.qcow2 -M isapc -net nic -net user -no-reboot -m 256

And with any luck, you’ll find the VM booting, and all set and ready to roll. If it comes up in single user-mode, just close Qemu & fire it up again..

I’ll probably put together a windows install package for this later, but for now I figure I’ll unleash some 386BSD onto the world.

386BSD & Bochs

386BSD

386BSD on Bochs

While checking around on wikipedia for something related to 4.2BSD, I found out that bochs 2.4 can run 386BSD!

Now the significance of 386BSD is that it was the real first time that BSD had been given to the masses, in that it *could* run on commodity hardware (read 386’s!), come with full source code and be free. It is no wonder that the initial 0.0 release had well over 100,000 downloads!

It is getting harder and harder to track down a download source for 386BSD as it too was swept up in the great lawsuit of AT&T vs BSDI/CSRG although it was never named in the suit. Not to mention it was quickly superseded by the FreeBSD & NetBSD projects. It is very unstable in the 0.1 release, there is clearly some issues with it’s “install” program with regards to allocating swap space, and in general with the OS’s swapping routines. Also because of the overlap any attempt to install on a disk larger then 100MB results in a corrupted file system that will no longer boot after the eventual file corruption. It’s quite sad, but if you search the news group at the time, there was all kinds of issues with the install process, and with it’s stability.

The installation process does involve quite a bit of floppy shuffling, and will almost result in lots of trial & error to get it going. While there is an install guide on the install disk, it isn’t worded into exactly how to do it. Needless to say the Free/Net BSD releases have improved on the install greatly.

On the other hand it sure is interesting to see a Net/2 BSD to see how far we have come, and how so much is the same.

You can find 386BSD on the mirror site oldlinux.org.

Just watch out that the install floppy (dist.fs) is only 1.2MB.. So be sure to alter your bochsrc file accordingly.