ZFS add 2 new devices to mirror

Hi folks,

I have a zfs mirror in my system of two hard drives. They are capable of 1TB data storage. Now I want to add anoter mirror to this mirror to raise the capacity from 1TB to 2TB.

I run amd64 9.0, zfs version is 28.

I tried the command [cmd=]zpool add zpool mirror /dev/ada2 /dev/ada3[/cmd] which sounded most reasonable to me. But I get the error message

Code:
cannot add to 'zpool': root pool can not have multiple vdevs or seperate logs

I have seen in several tutorials that there exists a root pool, and then there were a lot of mirror devices added. Is it necessary to add a root pool before?

Best regards,
eyebone
 
Turn off the bootfs property first, if you have Root on ZFS setup you'll have to do this in a recovery enviroment of some sort, live cd or memory stick.
 
kpa said:
Turn off the bootfs property first, if you have Root on ZFS setup you'll have to do this in a recovery enviroment of some sort, live cd or memory stick.

I think I´ve tested already tested that once and that it didn´t work, unfortunately. If you have set the bootfs-flag, ZFS kinda "remembers" that and still complains:
Code:
cannot add to 'zpool': root pool can not have multiple vdevs or seperate logs

Example without bootfs being set:
Code:
NAME   PROPERTY  VALUE   SOURCE
pool   bootfs    -       default

Example with bootfs set:
Code:
NAME   PROPERTY  VALUE       SOURCE
pool   bootfs    pool1/root  local

As I remember it, you cannot set it back to exactly VALUE -, SOURCE default, which is needed for it to "forget" and stop complaining. I think the closest I got was VALUE -, SOURCE local, and that wasn´t enough. But I am happily proven wrong:)


@kpa

Do try but I´m not sure it will work.

/Sebulon
 
I have done that many times successfully in order to add cache or log devices.

Let me point out that the procedure never had to occur from a rescue image.

[CMD=""]#zpool set bootfs="" pool[/CMD]
[CMD=""]#zpool set bootfs="pool" pool[/CMD]
 
Thanks! Worked like a charm:

Code:
#zpool set bootfs="" pool
#zpool add pool mirror /dev/ada2 /dev/ada3
#zpool set bootfs="pool" pool

Great!
 
Back
Top