From owner-freebsd-stable@freebsd.org Thu Jan 12 23:30:53 2017 Return-Path: Delivered-To: freebsd-stable@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 1203DCA90EC for ; Thu, 12 Jan 2017 23:30:53 +0000 (UTC) (envelope-from killing@multiplay.co.uk) Received: from mail-wm0-x231.google.com (mail-wm0-x231.google.com [IPv6:2a00:1450:400c:c09::231]) (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 AB94F1546 for ; Thu, 12 Jan 2017 23:30:52 +0000 (UTC) (envelope-from killing@multiplay.co.uk) Received: by mail-wm0-x231.google.com with SMTP id n129so7780205wmn.0 for ; Thu, 12 Jan 2017 15:30:52 -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; bh=/mglYDtjEXUon0FFbyIBKgM2Z8/lX/asefwKGoGkwns=; b=L4P20QspbnHBu9ex+swDDl149sol5db+oA+FXaSovu8EKMsmQ/EyBe7jUIsA7qPqF7 4X4WIAnQQd0UwbMKoUcw4nPHp/aBgEOuImYVUamai51lQnuQTmP4wkvO3TwHm+SC1uX4 p9YQYXRbuJ/fukHo2a+7clgTLuxlo7d2B4VQ1ZqiHblK9tVmNir9aL6sdDmBuAqrOctH tvgTYsEPKmG81Nmsyc0eBAVzIPD37A+WM61QfwTor9UXT5WwAsRDkvt3ihDQWKkXoVxN +ixNMuM79szl9A0HB1c9yj1ue284MsFdl1a0xG8Xbn0psQSG6TGKD7K0QJbz9h51y23N oWeg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:references:from:message-id:date :user-agent:mime-version:in-reply-to; bh=/mglYDtjEXUon0FFbyIBKgM2Z8/lX/asefwKGoGkwns=; b=fzM41lFhqjRHzWREysqdeLGEgvBXPT3YdYVr8PIvBXUYaNvGb/SB5YwkHSqVdZbQZ+ qCDCTkwoQRAZAs3qyXK48eE2kQhvZ9iO2KsXEzT5xYjmcTfx+ioU0g1U7e9NSQm5+psX t0LfLa7tjJa4bzuWHXG6sqNwQ0CYq7Vxp0STBHTioOTSn4Bx19S8tjClXXcVDZLLv+ve 3rWh6/KfkM84OARL3eRV+js4TrKD9gVZ1WraRcWUJdfjr+PWrk6lWXTZIKbcKb6gkxDf orH1Gnia5OkhL0SSfVTBIHnmd/SZF10+w5q05WOxekumj6W7VjH2COBUkmHClEdY3Sfq JarA== X-Gm-Message-State: AIkVDXIm7+n8j8qVKPk5cArj9msd5RzsOu+Tp2tkcu7Ku3n0FA4oCSKWbSEcqaUzJCtL4+ST X-Received: by 10.28.207.70 with SMTP id f67mr339550wmg.72.1484263850470; Thu, 12 Jan 2017 15:30:50 -0800 (PST) Received: from [10.10.1.58] ([185.97.61.26]) by smtp.gmail.com with ESMTPSA id w7sm6255921wmd.24.2017.01.12.15.30.49 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 12 Jan 2017 15:30:49 -0800 (PST) Subject: Re: zpool asize problem on 11.0 To: freebsd-stable@freebsd.org References: <01B0C796-CB6D-412D-AB93-05836906BC89@lassitu.de> From: Steven Hartland Message-ID: <3035d642-bffa-84b9-a4bc-b7134541fc78@multiplay.co.uk> Date: Thu, 12 Jan 2017 23:30:56 +0000 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.6.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit X-Content-Filtered-By: Mailman/MimeDel 2.1.23 X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 12 Jan 2017 23:30:53 -0000 On 12/01/2017 22:57, Stefan Bethke wrote: > Am 12.01.2017 um 23:29 schrieb Stefan Bethke : >> I’ve just created two pools on a freshly partitioned disk, using 11.0 amd64, and the shift appears to be 9: >> >> # zpool status -v host >> pool: host >> state: ONLINE >> status: One or more devices are configured to use a non-native block size. >> Expect reduced performance. >> action: Replace affected devices with devices that support the >> configured block size, or migrate data to a properly configured >> pool. >> scan: none requested >> config: >> >> NAME STATE READ WRITE CKSUM >> host ONLINE 0 0 0 >> gpt/host0 ONLINE 0 0 0 block size: 512B configured, 4096B native >> >> errors: No known data errors >> >> # zdb host | grep ashift >> ashift: 9 >> ashift: 9 >> >> But: >> # sysctl vfs.zfs.min_auto_ashift >> vfs.zfs.min_auto_ashift: 12 >> >> Of course, I’ve noticed this only after restoring all the backups, and getting ready to put the box back into production. >> >> Is this expected behaviour? I guess there’s no simple fix, and I have to start over from scratch? > I had falsely assumed that vfs.zfs.min_auto_ashift would be 12 in all circumstances. It appears when running FreeBSD 11.0p2 in VirtualBox, it can be 9. And my target disk was attached to the host and mapped into the VM as a „native disk image“, but the 4k native sector size apparently got lost in that abstraction. > > The output above is with the disk installed in the target system with a native AHCI connection, and the system booted from that disk. > > I’ve certainly learned to double check the ashift property on creating pools. > The default value for vfs.zfs.min_auto_ashift is 9, so unless you specifically set it to 12 you will get the behaviour you described. Regards Steve