upgrading 9.3 / ZFS v28

andrew clarke mail at ozzmosis.com
Tue Nov 18 06:47:26 UTC 2014


On Mon 2014-11-17 16:24:52 UTC-0800, David Newman (dnewman at networktest.com) wrote:

> This command will upgrade the zpool, even when mounted:
> 
> zpool upgrade -a
> 
> This command will take the system offline, as I learned the hard way:
> 
> zfs upgrade
>
> The right way to do this:
> 
> 1. Boot into a LiveCD. I used the FreeBSD 10.1 DVD.
> 
> 2. For each boot partition, use this command:
> 
> # gpart bootcode -b /boot/pmbr -p /boot/gptzfsboot -i 1 ada0
> 
> This assumes that (a) the freebsd-boot partition is first on the disk
> and ada0 is the disk. Use "gpart show" to verify this.
> 
> This system has four disks, each with a freebsd-boot partition, so I
> went on like this:
> 
> # gpart bootcode -b /boot/pmbr -p /boot/gptzfsboot -i 2 ada1
> # gpart bootcode -b /boot/pmbr -p /boot/gptzfsboot -i 3 ada2
> # gpart bootcode -b /boot/pmbr -p /boot/gptzfsboot -i 4 ada3
> 
> ...and I got an invalid index error on that last one, even though it's
> set up the same as the others.
> 
> The system seems to boot and run OK, but I'm not sure why that last
> command failed.

In what way did "zfs upgrade" take the system offline? Kernel panic?

You did not paste the output of "gpart show", but I suspect you may
have got the gpart index parameter wrong on ada{1,2,3}.

On my two disk system, "gpart show" outputs:

=>        34  1953525101  ada0  GPT  (932G)
          34         128     1  freebsd-boot  (64K)
         162  1953524973     2  freebsd-zfs  (932G)

=>        34  1953525101  ada1  GPT  (932G)
          34         128     1  freebsd-boot  (64K)
         162  1953524973     2  freebsd-zfs  (932G)

Therefore the correct commands were:

gpart bootcode -b /boot/pmbr -p /boot/gptzfsboot -i 1 ada0
gpart bootcode -b /boot/pmbr -p /boot/gptzfsboot -i 1 ada1

Regards
Andrew


More information about the freebsd-questions mailing list