ZFSBoot try and bsdlabel bootstrap code

Doug Rabson dfr at rabson.org
Sat Nov 22 01:27:37 PST 2008


On 21 Nov 2008, at 21:31, Olivier SMEDTS wrote:

> 2008/11/20 Doug Rabson <dfr at rabson.org>:
>>
>> On 19 Nov 2008, at 22:12, Olivier SMEDTS wrote:
>>
>>> Hello,
>>>
>>> I want to boot off a ZFS pool (version 13) on an USB stick for  
>>> testing
>>> purposes. But I'm stuck with the bsdlabel bootstrap code size...
>>> I'm using a 2 hours old CURRENT.
>>>
>>> # kldload usb2_storage_mass
>>> # kldload zfs
>>> # dd if=/dev/zero of=/dev/da0 bs=512 count=32
>>> # fdisk -BI da0
>>> # dd if=/dev/zero of=/dev/da0s1 bs=512 count=32
>>> # bsdlabel -wB -b /boot/zfsboot da0s1
>>> bsdlabel: boot code /boot/zfsboot is wrong size
>>>
>>> Is what I'm trying to do with bsdlabel wrong ?
>>> I previously tried with the default bootstrap code but I had an
>>> (expected) "boot: Not ufs" error at boot.
>>>
>>> PS : I'm not subscribed to this list.
>>
>> The process for install zfsboot is a bit manual (and undocumented).  
>> Try
>> something like this:
>>
>>       # dd if=/boot/zfsboot of=/dev/da0s1 count=1
>>       # dd if=/boot/zfsboot of=/dev/ds0s1 skip=1 seek=1024
>
> It works !
>
> Now I'm stuck at loader(8) prompt.
> After having a look at your patch, I tried building world with
> "LOADER_ZFS_SUPPORT=yes". And it seems broken, at least on amd64 :
>
> # cd /usr/src
> # make buildworld LOADER_ZFS_SUPPORT=yes
> [...]
>
>
>> Alternatively, you might try using the brand new support for GPT  
>> that I
>> committed yesterday:
>
> Well, this one was broken on amd64 and is now disconnected from the  
> build.
>
> Any advice ?

I will sort out the amd64 build problems. My test machine was i386 so  
I missed it.



More information about the freebsd-fs mailing list