Panic on 'zpool replace' on readonly pool

Hi,

I did a fresh install of FreeBSD 9.1-RC2 and imported an originally 4 disk zraid pool with only 3 disks attached in readonly mode (via zpool import -o readonly=on storage). On replacement of the missing disk via zpool replace storage ada1 the machine reboots instantly (with no messages in the system logs). I repeated the procedure five times with the same outcome. On importing the zpool without the readonly option, resilvering starts and works fine.

I guess this is not desirable behaviour, but should it in theory be possible to resilver a degraded zpool imported in readonly mode?

Since I couldn't find anything that seems related in the PR database, should I file a problem report on this?

Thanks

PS:
Code:
# uname -a
FreeBSD brutus.lostpackets.de 9.1-RC2 FreeBSD 9.1-RC2 #0 r241106: Mon Oct  1 18:26:44 UTC 2012     [email]root@farrell.cse.buffalo.edu[/email]:/usr/obj/usr/src/sys/GENERIC  amd64
 
It sounds like you found a ZFS bug, filing a PR is a very good idea.

Perhaps since the pool is readonly, and resilvering is technically a write, the code is between a rock and a hard place and does something stupid instead of printing "Cannot replace on a readonly pool"?

I can't find any docs indicating you can do a replace on a readonly pool, if this was expected behavior on Solaris for instance, I'd include that in the PR.
 
Back
Top