This is kind of an adjunct to part 4 of my “Server Upgrade Chronicles”.
ZFS root pools have some requirements and best-practices at variance to other ZFS pools. One of the most annoying is that you can’t use a whole disk, and you can’t use an EFI-labeled disk. This is annoying because for most ZFS uses using a whole disk is the best practice, and when you do that ZFS puts an EFI label on that disk.
So, when you try to use in a root pool a disk you’d previously used somewhere else in ZFS, you often see this:
bash-3.2$ pfexec zpool attach rpool c4t0d0s0 c9t0d0s0 cannot attach c9t0d0s0 to c4t0d0s0: EFI labeled devices are not supported on root pools.
What do you do then? Well, you google, of course. And you find many sites explaining how to overwrite an EFI label on a disk. And every single one of them omits several things that seem to me to be key points (and which I had to play around with a lot to get any understanding of). The fact that ZFS is what drew me back into Solaris, and that I wasn’t ever really comfortable with their disk labeling scheme to begin with, is no doubt a contributing factor.
This is going to get long, so I’m putting in a cut here. Continue reading Replacing A Solaris EFI Disk Label