zfs disk replace issue

Bakul Shah bakul at bitblocks.com
Tue May 29 01:55:58 UTC 2012


On Mon, 28 May 2012 21:35:22 EDT kpneal at pobox.com  wrote:
> On Mon, May 28, 2012 at 12:09:47AM -0700, Bakul Shah wrote:
> > I have a zpool with 2 mirrors of two disks each. 3 of the
> > disks are 1TB. I replaced three original 300GB disks with
> > the TB disks and there were no problems
> > 
> > Recently I upgraded to a new machine and trasferred the old
> > zfs disks to the new machine and everything was ok.
> > 
> > I then replaced the final 300GB disk with a 1TB disk. I
> > noticed that after resilver finished (in two hours), "zpool
> > status" kept showing 'replacing 0' and showed the old and new
> > disk in the pool. I thought it would automatically take out
> > the old disk?  So then I manually "zpool detach"ed the old
> > disk but the size of the mirror has not changed.
> > 
> > Is this a bug or did I miss some step? I'd appreciate any help
> > to make the extra space usable! This pool is root so it
> > was mounted when I did this.  May be that was the problem?
> 
> I don't know if the 'autoexpand' property works on FreeBSD or not. If not
> then you may have to export the pool and then reimport it. I don't know
> how to do that when you are booting from the pool.

Thanks. I did discover this property earlier today. At least
for the older pool the default seems to be off.  I turned it
on but haven't had a chance to work on this... I just did

zpool detach z ada4p1
zpool attach z ada1p1 ada4p1

That fixed it but now it is resilvering! Luckily it only takes about
a couple hours!

> Oh, and I don't know if this is needed or not, but the practice seems
> to be to always do a scrub after a resilver has completed to a new,
> larger, disk.

Yeah, I already did that.

Thanks for your response.


More information about the freebsd-fs mailing list