Page MenuHomeFreeBSD

Make the ZFS min_auto_ashift=12 setting persistent
ClosedPublic

Authored by allanjude on May 25 2017, 4:07 AM.
Tags
None
Referenced Files
Unknown Object (File)
Fri, Nov 15, 11:07 AM
Unknown Object (File)
Thu, Nov 7, 10:59 AM
Unknown Object (File)
Tue, Oct 29, 10:06 AM
Unknown Object (File)
Oct 5 2024, 12:53 PM
Unknown Object (File)
Oct 5 2024, 6:11 AM
Unknown Object (File)
Oct 4 2024, 7:09 PM
Unknown Object (File)
Oct 4 2024, 5:02 PM
Unknown Object (File)
Sep 28 2024, 5:22 AM
Subscribers

Details

Summary

Some users have reported problems where they created a pool with 4k sectors using the installer, but when they added additional disks later, the min_auto_ashift value had reverted to the default (9), causing their second vdev to have worse performance

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

Is this supposed to be in loader.conf or in sysctl.conf? Does it matter?

I've traditionally controlled this in sysctl.conf, but perhaps loader.conf is a better, more permanent place.

IMO if it is really supposed to be default, then the correct place is in /boot/defaults/loader.conf - overloading /boot/loader.conf will only confuse people.

It is probably time to make 4K (ashift=12) the default and have the 512b (ashift=9) users explicitly declare their special requirement, but it should not happen without further discussion and a clear way to communicate this to the userbase.

In D10895#225791, @feld wrote:

Is this supposed to be in loader.conf or in sysctl.conf? Does it matter?

I've traditionally controlled this in sysctl.conf, but perhaps loader.conf is a better, more permanent place.

It doesn't explicitly matter. The installer infrastructure for writing sysctl.conf was added by remko@ and is actually done wrong, and doesn't exist in stable/11, so I did it in loader.conf to make it an easy merge to stable/11

IMO if it is really supposed to be default, then the correct place is in /boot/defaults/loader.conf - overloading /boot/loader.conf will only confuse people.

In this case, it is an option in the installer, not a system wide default.

In D10895#225833, @feld wrote:

It is probably time to make 4K (ashift=12) the default and have the 512b (ashift=9) users explicitly declare their special requirement, but it should not happen without further discussion and a clear way to communicate this to the userbase.

I agree that might be the right thing to do, however I am not sure what OpenZFS would think of that. The idea is for ZFS to be the same on every platform. At the same time, Linux has already gone and done their own thing here, so.

This revision is now accepted and ready to land.May 25 2017, 5:32 PM

ok, that explanation does make sense, LGTM.

This revision was automatically updated to reflect the committed changes.