Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 09 Jun 2017 13:18:04 +1000
From:      Stephen McKay <mckay@FreeBSD.org>
To:        =?UTF-8?Q?=c5=81ukasz_W=c4=85sikowski?= <lukasz@wasikowski.net>
Cc:        Stephen McKay <mckay@FreeBSD.org>, freebsd-fs@freebsd.org
Subject:   Re: Problem with zpool remove of log device
Message-ID:  <0fc687$sij78n@ipmail05.adl6.internode.on.net>
In-Reply-To: <4df1ea6d-148e-f3ab-d204-9277c513a468@wasikowski.net> from =?UTF-8?Q?=c5=81ukasz_W=c4=85sikowski?= at "Wed, 07 Jun 2017 12:56:30 %2B0200"
References:  <9188a169-cd81-f64d-6b9e-0e3c6b4af1bb@wasikowski.net> <0410af$1dldvp4@ipmail04.adl6.internode.on.net><4df1ea6d-148e-f3ab-d204-9277c513a468@wasikowski.net>

next in thread | previous in thread | raw e-mail | index | archive | help
On Wednesday, 7th June 2017, =?UTF-8?Q?=c5=81ukasz_W=c4=85sikowski?= wrote:

>W dniu 2017-06-07 o 10:21, Stephen McKay pisze:
>
>> On Friday, 26th May 2017, lukasz@wasikowski.net wrote:
>> 
>>> I cant remove log device from pool - operation ends ok, but log device
>>> is still in the pool (bug?).

>> Does your system still write to the log?  Use "zfs iostat -v 1" to
>> check.  I think it is probably no longer be in use and only the final
>> disconnection failed.
>
>zpool iostat -v 1 shows no activity on the log drive. I tried to remove
>it after booting to livecd - no luck.

I hope I haven't mislead you there (more than misspelling zpool, that is).

In normal operation the log is idle unless there are synchronous writes
to log.  So, to be sure your log is active, use something like this (within
the target pool) to generate sync writes:

    while :
    do
        date > foo
        fsync foo
    done

With this running, my system does 600 writes per second to the log
according to zpool iostat.  That drops to zero once I kill the script.

>> I had this problem when I tried to remove a log mirror from a pool
>> I have been using for years.  I solved it by tweaking the zfsonlinux
>> hack a bit and slotting it into 9.3.
>
>Thank you for this info. It seems that it's no longer an issue for me -
>this box will be soon retired. I'll move some data from it and wipe it down.

If you are feeling public spirited this is an ideal opportunity to check
the theory against reality.  I'm curious about how widespread this accounting
bug is, so if you can keep the machine intact for a while after it has
been decommissioned, you could build a patched kernel and try to remove the
log again.  All it would cost in this case is a little time.

Cheers,

Stephen.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?0fc687$sij78n>