Introduction

In January of 1997, I finally got serious about installing NetBSD 1.2 on my sparc machine. This machine is a sun 4/370, which is pretty much the top end of the sun4 architecture. After this sun went on to the desktop sparc (the sun4c architecture). It is able to crank about 20 MIPS and 1.6 Mflops, which is pretty decent, unless you compare it to what you can actually purchase these days.

In any event, here is what I experienced in installing NetBSD on this machine. My machine came with a 700M SMD disk in a separate pedestal. I have yet to actually spin up this disk. I had on hand a Hitachi scsi disk (a DK516C), which I jumpered as target 0 and mounted in the handy perforated "coffins" that sun so nicely built into the top of the cpu pedestal. One of the coffins also has a 150M 1/4 inch scsi tape drive, which I then used to boot miniunix and run the format program. For some reason, I was unable to actually format this disk, but it came formatted from the vendor, and I was able to do a full read analysis of all the blocks as well as a write/read/compare using the sun format program and that will have to do. Before I ended this phase of the operation I also partitioned and labelled the disk as follows:

Next I obtained NetBSD-1.2-sparc via ftp over the net and placed it onto a QIC tape. From there it went onto a sun 3/160 running SunOS 4.0 in anticipation of diskless booting the sparc. The install notes detail this rather nicely, but here is a run thru of what had to be done.

First edit /etc/hosts and /etc/ethers adding entries for the sparc target. Next I tried running add_client, but I would have had to add cross-architecure support from the install tapes, and decided that was too much bother, so would just set things up by hand. I was already diskless booting another sun3 machine, so some things were already set up, at least in prototype for me.

In /tftpboot, copy netbsd-sparc/usr/mdec/boot to be boot.netbsd, and do this removing the first 32 bytes (the a.out header).

dd if=boot of=/tftpboot.netbsd skip=1 bs=32

Then make a link to this which is the ip-number of the target machine in hex with a .SUN4 extension, i.e. 81C4B392.SUN4 or some such.

At this stage, the sparc machine can at least try to boot, and should get its IP number via revarp and the 2nd stage boot via tftpboot, which will then try to get the netbsd kernel. The thing to do is to edit /etc/exports to provide swap and root for the target and /etc/bootparams to inform the target where these are. I used netbsd.GENERIC, and this is worth discussing a bit. Some sun sparc machines do a nonsensical mapping of scsi targets to logical disk names. This brain damage aparently started with the sun4c desktop sparc systems and is not a concern with the sun4 clan. In any event, on my machine I was able to ignore the crazy issue of scsi ID 0 becoming sd3a and the like. I jumpered my disk as zero, boot it as zero and the generic kernel finds it as sd0a.

Also, the NetBSD distribution comes as base.tar.gz and the like, so you need gnu zip and tar to deal with them (you probably don't actually need gnu tar if you fuss around a bit). I solved this problem on my boot host by just unpacking the archives base and etc on an i386 netbsd machine I had running and then sending them over the network to my sun machine where I placed them into the diskless root directory on my server.

After this netbsd booted just fine and after only 3 attempts I made it cleanly thru the install script and the system now boots from the scsi disk. Stay tuned for more excitement!