From a81473809aee9da3d2631b117d7461e789e3ad4e Mon Sep 17 00:00:00 2001 From: mckusick Date: Thu, 6 Sep 2018 23:28:35 +0000 Subject: [PATCH] The Call For Testing had no reports of operational problems and found that performance was no worse and usually better when running with TRIM consolidation. Performance improvement was most noticable when multiple large files are released in a short period of time. Thus, TRIM consolidation is being enabled by default. Should operational problems be found, it can be disabled using the command `sysctl vfs.ffs.dotrimcons=0'. This variable can also be set as a tunable if early disabling is necessary. Approved by: re (gjb) Sponsored by: Netflix --- sys/ufs/ffs/ffs_alloc.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/ufs/ffs/ffs_alloc.c b/sys/ufs/ffs/ffs_alloc.c index 6cbec2d151e6..636e8e67257e 100644 --- a/sys/ufs/ffs/ffs_alloc.c +++ b/sys/ufs/ffs/ffs_alloc.c @@ -484,8 +484,8 @@ static int doreallocblks = 1; SYSCTL_INT(_vfs_ffs, OID_AUTO, doreallocblks, CTLFLAG_RW, &doreallocblks, 0, "enable block reallocation"); -static int dotrimcons = 0; -SYSCTL_INT(_vfs_ffs, OID_AUTO, dotrimcons, CTLFLAG_RW, &dotrimcons, 0, +static int dotrimcons = 1; +SYSCTL_INT(_vfs_ffs, OID_AUTO, dotrimcons, CTLFLAG_RWTUN, &dotrimcons, 0, "enable BIO_DELETE / TRIM consolidation"); static int maxclustersearch = 10;