From owner-freebsd-fs@freebsd.org Mon Feb 15 21:08:42 2016 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 7F70FAA968D for ; Mon, 15 Feb 2016 21:08:42 +0000 (UTC) (envelope-from killing@multiplay.co.uk) Received: from mail-wm0-x235.google.com (mail-wm0-x235.google.com [IPv6:2a00:1450:400c:c09::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 2179F10E5 for ; Mon, 15 Feb 2016 21:08:41 +0000 (UTC) (envelope-from killing@multiplay.co.uk) Received: by mail-wm0-x235.google.com with SMTP id g62so77086459wme.1 for ; Mon, 15 Feb 2016 13:08:41 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=multiplay-co-uk.20150623.gappssmtp.com; s=20150623; h=subject:to:references:from:message-id:date:user-agent:mime-version :in-reply-to:content-type:content-transfer-encoding; bh=lbq2bmY+rEZzV3bJkZPlMaJOOp/DL8mOndJnQ4O4ZA0=; b=XhP4ONcZ4tFlwss5qww7S1vGGqLap4sDwe6Jmqf8KGYFJw61Y++JaBcX0ACYXHvA6B XysFrY5Hyo79BnPsresrCUD+wPf8W6lArYiLfpR55jhUisQKg/iSRNv2ITEX2pQpweF0 F6r4Jna3WOfqux5KK/UkeM3jbnkvR63cd+SFC7/NH+WOvbSKXl3bKgwcJjvjW2n+5Nw2 /MkN71MtI9wKTaHYRTf6MFzfqXwuxK02NJ1RjJlnf6GaiKAI6KP3QcsHNeVl+7h7kz3b +WEjikopccd5QjcAyADdegtBQKv2T6z7aKLmvnNEOcFGZSTr5HGHUF3mUhaWiLchs9IE Kutg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:subject:to:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-type :content-transfer-encoding; bh=lbq2bmY+rEZzV3bJkZPlMaJOOp/DL8mOndJnQ4O4ZA0=; b=g9PO2MHpHC33FWvm5gP8fEbPDQkloGoZ0J/x6qk3UVgj52dYfvoztZy8Mr+LBwH2U4 3C5TPrZMRLnUBAMU5pGSmhZvYv/33Ij8i9FiL+Z3wKwFs0i9I8sZem/KSQUchhDfC1fY s6ectEex3x1bqc07S9Ko19Vec9WiQQ7fbKfEJBYMMFUVhzsnCipPl5+N7lcXvj5BLq2e g0CdE5R61Kg2bix+Yd8MPv9hmH42/vHqVYZtZaC2pLxhsNMi1WgdcW9Q4px088vEts5u dzFdIIM4U0F7Mix+ojxbEbkwYAoBtmMpwWxLagurFIeFxhrf73nrckm82zR5dfDYgoiy VIUA== X-Gm-Message-State: AG10YOR2C1jU0fQ2FOE7SuYV3YhUBwdHxa8BQF8ZRxn/oy5rMqBCxRU2ypBpPNPC0pqZgRue X-Received: by 10.28.212.9 with SMTP id l9mr15646122wmg.75.1455570520075; Mon, 15 Feb 2016 13:08:40 -0800 (PST) Received: from [10.10.1.58] (liv3d.labs.multiplay.co.uk. [82.69.141.171]) by smtp.gmail.com with ESMTPSA id et11sm27072530wjc.30.2016.02.15.13.08.38 for (version=TLSv1/SSLv3 cipher=OTHER); Mon, 15 Feb 2016 13:08:38 -0800 (PST) Subject: Re: Hours of tiny transfers at the end of a ZFS resilver? To: freebsd-fs@freebsd.org References: <8E04E52A-2635-4253-8140-F69495D7D0A6@panasas.com> From: Steven Hartland Message-ID: <56C23E5B.7060207@multiplay.co.uk> Date: Mon, 15 Feb 2016 21:08:43 +0000 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:38.0) Gecko/20100101 Thunderbird/38.5.1 MIME-Version: 1.0 In-Reply-To: <8E04E52A-2635-4253-8140-F69495D7D0A6@panasas.com> Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit 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: Mon, 15 Feb 2016 21:08:42 -0000 On 15/02/2016 20:33, Ravi Pokala wrote: >> Date: Mon, 15 Feb 2016 21:18:59 +1100 >> From: Andrew Reilly >> To: freebsd-fs@freebsd.org >> Subject: Hours of tiny transfers at the end of a ZFS resilver? >> Message-ID: <120226C8-3003-4334-9F5F-882CCB0D28C5@bigpond.net.au> >> Content-Type: text/plain; charset=us-ascii >> >> Hi Filesystem experts, > Hi Andrew, > > I am in no way, shape, or form a filesystem expert. :-) I *am*, however, an ATA drive expert. I wanted to clarify something you said, because it seems to be a common misunderstanding. > >> ... the new drives actually have 4096B sectors (although they lie about that in smartctl -i queries): > They're not lying. > >> Sector Sizes: 512 bytes logical, 4096 bytes physical > Right there - "Sector Size: ... 4096 bytes physical". This is 512B logical / 4KB physical scheme is called AF-512e, and is a documented, standard format. > > https://en.wikipedia.org/wiki/Advanced_Format#512e > > The intent is to allow backwards-compatibility with software going back decades, which only knows about 512-byte sectors. Such software would treat an AF-512e drive the same as any other drive. The trade-off is performance, because the drive has to transparently perform read-modify-write operations (for sub-4096B writes), and read the full 4096B physical sector even if only a single 512B logical sector was requested. (Ditto if a properly-sized but un-aligned request were made.) > > I know GEOM reports both the logical and physical sector sizes (as the provider's "sectorsize" and "stripesize", respectively), and I know that the ATACAM driver is populating them correctly based on the drive's IDENTIFY_DEVICE information. (My very first submission to the project was to fix some bugs in this code; r262886, 2014-03-07.) [*] > > I *don't* know if ZFS does the right thing automatically; it might not be able to determine what "the right thing" is in all cases. I leave answering that to the actual ZFS experts. :-) Yes this was added nearly 2 1/2 years ago by r254591 > > -Ravi (rpokala@) > > [*] This is probably a good segue into discussing why we even have the ADA_Q_4K quirk, and whether we should get rid of it...? --rp The 4k quirks exists because a large amount of devices don't report 4k correctly instead just reporting 512 for both logical and physical even when they are actually 4k or larger physical sector size. Regards Steve