Subject: Re: install via netboot install kernel problem
To: Simon Burge <simonb@NetBSD.ORG>
From: Maciej W. Rozycki <macro@ds2.pg.gda.pl>
List: port-pmax
Date: 02/09/2000 11:36:00
On Wed, 9 Feb 2000, Simon Burge wrote:

>  + TFTP will be easier _in_general_, because almost everything has
>    TFTP support but not everything has (or will have) MOP support.

 If you mean the client then I agree.  If you mean the server than it's
what I want to address adding ELF support.  Almost all systems today
support ELF so they include an appropriate elf.h header.  The structures
and macros defined in the header have fixed values and mening thanks to a
centralized management of ELF specs.  So everyone should be able to
compile mopd for their system.  For these few systems that lack ELF
support, mopd may include a reasonable local copy of elf.h (but then
problems of data sizes arise -- the systems that have no ELF support do
not support ISO C's stdint.h types and there is no single traditional way
of fetching integers of a fixed width; I might actually add autoconf
support to mopd but wouldn't that be an overkill?).

 BOOTP and TFTP have their own weirdnesses, given the range of equipment
uses them.  I've already met some firmware that won't TFTP-boot any image
that is not integer multiple of 512 bytes in size unless it's smaller than
512 bytes which is also OK.  No comments... 

>  + The mopd patches I wrote used ECOFF because at the time ECOFF was
>    easier than ELF (for me).  An ECOFF kernel is pretty much an a.out
>    kernel with an extra header or two.  An ELF back-end should be easy
>    to do.  I've _never_ used BFD - this may make life easier...

 Given the problems with ECOFF, Jonathan pointed out (i.e. having to tweak
a generic ECOFF support for pmax images), it might not actually make the
life easier.  Especially as binutils (so BFD as well) are in flux for
some time, due to Ian, the maintainer, being overly busy recently...

 Unfortunately, I cannot test ECOFF booting via TFTP as my ROM doesn't
permit it, although I may look into the problem one day and try to
disassemble the firmware to find out what the real reason is -- maybe it's
fixable in one way or another. 

>  + From an Ultrix support POV - just use an elf2ecoff'd kernel with
>    the normal Ultrix mop support.  For a 5000/150 here that just
>    can't tftp boot, I just
> 
> 	addnode -h 08-00-2b-30-17-8f -l fredri /dlboot0/fredrick/netbsd
> 
>    One advantage of Ultrix's mop node database is that the image
>    can live anywhere on the system - it doesn't need to be located
>    underneath /tftpboot.

 It's just a matter of mopd's complexity.  Someone might actually add some
configuration file support for mopd which would include paths for various
images.  Or one may change mopd's root to / and use symlinks (but the
latter is actually dangerous as mopd usually runs as root and someone
might request /etc/shadow as the boot image, for example...). 

-- 
+  Maciej W. Rozycki, Technical University of Gdansk, Poland   +
+--------------------------------------------------------------+
+        e-mail: macro@ds2.pg.gda.pl, PGP key available        +