Rainer Orth wrote:
> Rainer Orth <[EMAIL PROTECTED]> writes:
>
>   
>>> instlalboot on the new disk and see if that fixes it.
>>>       
>> Unfortunately, it didn't.  Reconsidering now, I see that I ran installboot
>> against slice 0 (reduced by 1 sector as required by CR 6680633) instead of
>> slice 2 (whole disk).  Doing so doesn't fix the problem either, though.
>>     
>
> I've found out what the problem was: I didn't specify the -F zfs option to
> installboot, so only half of the ZFS bootblock was written.  This is a
> combination of two documentation bugs and a terrible interface:
>   

Mainly because there is no -F option?

> * With the introduction of zfs boot, installboot got a new -F <fstype>
>   option.  Unfortunately, this is documented neither on installboot(1M)
>   (which wasn't update at all, it seems) nor in the ZFS Admin Guide
>   (p.80, workaround for CR 6668666).
>
> * Apart from that, I've never understood why it is necessary to specify the
>   full path to the bootblock to installboot like this
>
> installboot /usr/platform/`uname -i`/lib/fs/<fstype>/bootblk 
> /dev/rdsk/c0t0d0s0
>   

That is because installboot is simply a wrapper for dd.
http://src.opensolaris.org/source/xref/onnv/onnv-gate/usr/src/psm/stand/bootblks/ufs/i386/installboot.sh

The first argument is copied to the second argument using dd.

>   It would be far easier to just specify the fstype (or even let
>   installboot figure that out by itself using fstyp) than having to give
>   the full pathname.  In that case, installboot could just dd the whole
>   bootblk file instead of hardcoding the block counts for the different
>   filesystem types (probably to avoid corrupting the filesystem if the user
>   gives a file that is not a bootblock).
>
> Overall, a terrible mess ;-(
>
>   

I think that it should be very unusual that installboot would be run
interactively.  That is really no excuse for making it only slightly
smarter than dd, but it might be hard to justify changes unless some
kind person were to submit a bug with an improved implementation
(would make a good short project for someone :-)
 -- richard

_______________________________________________
zfs-discuss mailing list
zfs-discuss@opensolaris.org
http://mail.opensolaris.org/mailman/listinfo/zfs-discuss

Reply via email to