Subject: Re: 5000/25, Netboot
To: None <port-pmax@NetBSD.ORG>
From: Toru Nishimura <nisimura@itc.aist-nara.ac.jp>
List: port-pmax
Date: 07/08/1997 15:14:15
Jonathan Store wrote;

> *Please* send me a list of what could go wrong.  

OK, here goes lengthy, rambling note.  It's not *a guide* in any
sense.  Instead, notes about possibilities might go wrong.  Too
verbose leads confusion, too terse brings misinterpritation.  I hope
someone who is talented in writing definite instructions will compile
simple and error-proof way for installation.

* installing disklabel and bootblocks

	"It's not uncommon to notice you failed to install correct
	disklabel/bootblocks when you try to reboot the system
	after entire installation has done..."
	
Sometimes there might be difficulties in setting BSD disklabel on
disk.  It's common to recycle disks formerly used for other OS. 
Although it's not mandatory, it would be safer to use "clean disk,"
i.e., disk whose very first few blocks are zerod.  Zeroing blocks is
sometimes awkward because some implementations of OSes prevent boot
blocks from overwritten.  Essentially the work is done by 'dd'ing
/dev/zero (if hosting UNIX machine has it) into target disk.  Some
OSes (like Digital UNIX) has a special way to clean boot blocks; see
disklabel(8) in that case.  DOS has a silimiar way.  Yet other OS
implementations allow to overwrite boot block area only after boot
blocks are cleaned, so it's worth zeroing when suspicious about
disklabelling.

* It's known that sometimes disklabel(8) refuses to work complaining
"Open partition would move or shrink."  Check NetBSD/pmax mailing list
archive for walkarounds.

* Don't forget install NetBSD/pmax boot blocks.
The easy way to label and bootblocks same time is;

disklabel -R -r -B -b /usr/mdec/rzboot -s /usr/mdec/bootrz rz2 TARGET_LABEL

It's handy to prepare an entire disk label information including file
system partioning, a file TARGET_LABEL in this example, with a text
editor.  You can find the templete from ...uum... where?!  (It would
be better disklabel -r <target> could produce a useful template when
target disk has no valid tahoe disklabel, but is it impossible to
obtain disk geometory with NetBSD/pmax?)  Anyway, the easiest way to
obtain a template is to stole the output of disklabel -r from other
*BSD machine.  (Dah)

* it's recommended to have a large root filesystem (as 32MB).  The
partition scheme in /etc/disktab is not appropriate for recent
NetBSD/pmax configuration.

* Make sure /dev is populated correctly.  If not, system will hang
during boot sequence.

* If you want to use MAXINE serial port, run "mknod tty00 c 17 0" by
hand.

* After installation is well done, change PROM environment variables so
that system can boot itself correctly, for example;

	>> setenv boot 3/rz2/netbsd -aN

Above instructs PROM to do automatic boot.

	>> setenv haltaction h
	>> setenv testaction q

Those are handy when you reboot system occationally.

* Entire installation steps can be done in rather radicurous way; for
example, it's possible to make filesystems and install NetBSD/pmax in
a disk attached with *BSD/i386 by manipulating host system UNIX
commands.  It can work well because *BSD/i386 is little endian system,
however, i386 has machine dependent peculiarities in boot area
different from pmax.  After all you have to install valid disklabel
and bootblocks even with the case.

* Another way for initial-boot rather than TFTPnetboot is, to write a
raw disk image specially prepared for installation.  Again, cautions
about writing boot area should make sense in this case.

Tohru Nishimura
Nara Institute of Science and Technology