Subject: Re: mirrored root w/ raidframe - howto install bootblock?
To: Martin Husemann <martin@duskware.de>
From: Greg Troxel <gdt@ir.bbn.com>
List: port-sparc
Date: 05/15/2006 07:50:25
Martin Husemann <martin@duskware.de> writes:

> On Sun, May 14, 2006 at 10:57:46AM -0400, Greg Troxel wrote:
>> I think what's needed is to augment installboot to understand raid1,
>> or easier to be able to give it two fs arguments, one for the place to
>> put bootxx and the other to look for block #s of /boot.
>
> I think it does (at least it works this way on sparc64): if the partition
> to install the boot into is of type RAID, it will do the necessary magic
> (i.e. offset some stuff -64 blocks).

I can't find any sign of that in src/usr.sbin/installboot.

From reading sys/arch/sparc/stand/binstall/binstall.sh, it seems
sparc64 boot uses bootblk and ofwboot as stage1 and stage2, and they
both have RAIDframe support.   The first stage has FFS code and thus
doesn't require poking block numbers.  So installboot doesn't have to
do anything special with the "boot filesystem", just write bootblk to
the beginning of the boot partition, and put ofwboot in the 

sparc uses bootxx and boot.  Two things needed for nicely dealing with
booting for RAID-1 seem to be missing (i.e., I can't find them):

  installboot finding blocks from one filesystem (e.g., raid0a), and
  translating those to offsets relative to the entire disk for bootxx,
  so that bootxx can load /boot from RAID.

  /boot skipping over the raid header so it can load the kernel from RAID

So, does anyone out there have a sparc system that boots from RAID-1?
From my code reading, it looks like it can't work.

-- 
        Greg Troxel <gdt@ir.bbn.com>