From owner-freebsd-fs@freebsd.org Tue Jul 14 16:46:17 2015 Return-Path: Delivered-To: freebsd-fs@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id EDAD09A1F15 for ; Tue, 14 Jul 2015 16:46:16 +0000 (UTC) (envelope-from fjwcash@gmail.com) Received: from mail-ob0-x235.google.com (mail-ob0-x235.google.com [IPv6:2607:f8b0:4003:c01::235]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id B4B56FD4 for ; Tue, 14 Jul 2015 16:46:16 +0000 (UTC) (envelope-from fjwcash@gmail.com) Received: by obre1 with SMTP id e1so9758751obr.1 for ; Tue, 14 Jul 2015 09:46:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=xI/+W4UUv1roi3NbpfcRm/ZEzDRKQ0qwOs3xLX+PAis=; b=vJNuEZ03ZqAkpEuV5d5uVhFmo9LUGCujeis+aGXef6SaNv1M3TQadh85pvH/Btdc7V Yy6lJda/tJfdzi9o9tjGzp9TRYFoNvoZSWwAeVvAZquoH4Tb0prUf5V4E/JxW6gQJqxs I6GdEqGpCqcr2n7UN2ubJDcMf2Dn9LRYaZcyt9GkU2R3w0XbK1rjBV+7MoLcWFa27oW5 d0iD5BfjA8NhSJIxu+WgV0abGZxk4gxf+5gtXtfheONGzB4DbgSPy1NWS7oNc/eIurYB xf+0qaOZlEaFMwE+jFd1p/a8Z8PijLbJObs2OO34dxOHTv5P1ju8rzZvjZKEUFKe0QaA 20yw== MIME-Version: 1.0 X-Received: by 10.202.232.67 with SMTP id f64mr34700071oih.63.1436892376010; Tue, 14 Jul 2015 09:46:16 -0700 (PDT) Received: by 10.76.81.100 with HTTP; Tue, 14 Jul 2015 09:46:15 -0700 (PDT) In-Reply-To: <55A53BE2.7060609@stankevitz.com> References: <55A4461F.6020308@stankevitz.com> <55A53BE2.7060609@stankevitz.com> Date: Tue, 14 Jul 2015 09:46:15 -0700 Message-ID: Subject: Re: Offline/online a drive from a mounted RW RAIDZx pool: resilver needed? From: Freddie Cash To: Chris Stankevitz Cc: FreeBSD Filesystems Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.20 X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Jul 2015 16:46:17 -0000 On Tue, Jul 14, 2015 at 9:42 AM, Chris Stankevitz wrote: > On 7/13/15 4:26 PM, Freddie Cash wrote: > >> If you don't write anything to the pool, or at least, nothing gets >> written to that vdev, then there's >> > > Freddie, > > I missed part of your message. Are you saying that there are two > possibilities in the offline/online scenario: the drive comes online > immediately (no missed writes) or the drive undergoes a complete resilver > (1 or more missing bytes)? > =E2=80=8BSorry, was typing that on my phone, and meant to hit back not send= . If nothing is written to the pool (or, at least that specific vdev) while the drive is removed, then the metadata on the drive will match the pool, and it can be onlined without a resilver. If only a little bit of data has been written, and a short bit of time has passed, =E2=80=8B =E2=80=8Bthen the drive will only need to sync (resilver) that changed data= to the drive. If a lot of data has been written, or a long time has passed (not sure what qualifies as "long", maybe until the last txg synced to the disk is no longer in the txg history of the pool?), then the entire drive will be resilvered. Or, something along those lines. That's what I've observed by doing various tests (offline drive, pull drive, write to pool, online drive; or offline drive, replace with new one, start resilver, new drive dies, stick in old drive, online it, wait for resilver; and other scenarios). =E2=80=8B --=20 Freddie Cash fjwcash@gmail.com