[Bug 275965] periodic: add a daily zfs trim

2024-04-17 Thread bugzilla-noreply
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=275965

Mark Linimon  changed:

   What|Removed |Added

  Flags||mfc-stable13?
   Assignee|b...@freebsd.org|i...@freebsd.org

--- Comment #4 from Mark Linimon  ---
^Triage: assign to committer.

-- 
You are receiving this mail because:
You are the assignee for the bug.


[Bug 275965] periodic: add a daily zfs trim

2024-04-16 Thread bugzilla-noreply
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=275965

--- Comment #3 from commit-h...@freebsd.org ---
A commit in branch stable/14 references this bug:

URL:
https://cgit.FreeBSD.org/src/commit/?id=3e69ab88a032ac43d433f787b715466a87e72817

commit 3e69ab88a032ac43d433f787b715466a87e72817
Author: Lexi Winter 
AuthorDate: 2024-04-09 21:49:56 +
Commit: Warner Losh 
CommitDate: 2024-04-16 19:54:20 +

periodic/daily/801.trim-zfs: Add a daily zfs trim script

As mentioned in zpoolprops(7), on some SSDs, it may not be desirable to
use ZFS autotrim because a large number of trim requests can degrade
disk performance; instead, the pool should be manually trimmed at
regular intervals.

Add a new daily periodic script for this purpose, 801.trim-zfs.  If
enabled (daily_trim_zfs_enable=YES; the default is NO), it will run a
'zpool trim' operation on all online pools, or on the pools listed in
'daily_trim_zfs_pools'.

The trim is not started if the pool is degraded (which matches the
behaviour of the existing 800.scrub-zfs script) or if a trim is already
running on that pool.  Having autotrim enabled does not inhibit the
periodic trim; it's sometimes desirable to run periodic trims even with
autotrim enabled, because autotrim can elide trims for very small
regions.

PR: 275965
MFC after:  1 week
Reviewed by:imp
Pull Request:   https://github.com/freebsd/freebsd-src/pull/956

(cherry picked from commit 493908c4b45c7b75e4a6b4aea3b5b63ea5c268d5)

 share/man/man5/periodic.conf.5| 11 -
 usr.sbin/periodic/etc/daily/801.trim-zfs (new +x) | 59 +++
 usr.sbin/periodic/etc/daily/Makefile  |  3 +-
 usr.sbin/periodic/periodic.conf   |  5 ++
 4 files changed, 76 insertions(+), 2 deletions(-)

-- 
You are receiving this mail because:
You are the assignee for the bug.


[Bug 275965] periodic: add a daily zfs trim

2024-04-09 Thread bugzilla-noreply
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=275965

--- Comment #2 from commit-h...@freebsd.org ---
A commit in branch main references this bug:

URL:
https://cgit.FreeBSD.org/src/commit/?id=493908c4b45c7b75e4a6b4aea3b5b63ea5c268d5

commit 493908c4b45c7b75e4a6b4aea3b5b63ea5c268d5
Author: Lexi Winter 
AuthorDate: 2024-04-09 21:49:56 +
Commit: Warner Losh 
CommitDate: 2024-04-09 21:55:11 +

periodic/daily/801.trim-zfs: Add a daily zfs trim script

As mentioned in zpoolprops(7), on some SSDs, it may not be desirable to
use ZFS autotrim because a large number of trim requests can degrade
disk performance; instead, the pool should be manually trimmed at
regular intervals.

Add a new daily periodic script for this purpose, 801.trim-zfs.  If
enabled (daily_trim_zfs_enable=YES; the default is NO), it will run a
'zpool trim' operation on all online pools, or on the pools listed in
'daily_trim_zfs_pools'.

The trim is not started if the pool is degraded (which matches the
behaviour of the existing 800.scrub-zfs script) or if a trim is already
running on that pool.  Having autotrim enabled does not inhibit the
periodic trim; it's sometimes desirable to run periodic trims even with
autotrim enabled, because autotrim can elide trims for very small
regions.

PR: 275965
MFC after:  1 week
Reviewed by:imp
Pull Request:   https://github.com/freebsd/freebsd-src/pull/956

 share/man/man5/periodic.conf.5| 11 -
 usr.sbin/periodic/etc/daily/801.trim-zfs (new +x) | 59 +++
 usr.sbin/periodic/etc/daily/Makefile  |  3 +-
 usr.sbin/periodic/periodic.conf   |  5 ++
 4 files changed, 76 insertions(+), 2 deletions(-)

-- 
You are receiving this mail because:
You are the assignee for the bug.


[Bug 275965] periodic: add a daily zfs trim

2023-12-27 Thread bugzilla-noreply
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=275965

Lexi Winter  changed:

   What|Removed |Added

URL||https://github.com/freebsd/
   ||freebsd-src/pull/956

-- 
You are receiving this mail because:
You are the assignee for the bug.


[Bug 275965] periodic: add a daily zfs trim

2023-12-27 Thread bugzilla-noreply
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=275965

--- Comment #1 from Lexi Winter  ---
Created attachment 247294
  --> https://bugs.freebsd.org/bugzilla/attachment.cgi?id=247294=edit
patch

-- 
You are receiving this mail because:
You are the assignee for the bug.


[Bug 275965] periodic: add a daily zfs trim

2023-12-27 Thread bugzilla-noreply
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=275965

Bug ID: 275965
   Summary: periodic: add a daily zfs trim
   Product: Base System
   Version: 14.0-STABLE
  Hardware: Any
OS: Any
Status: New
  Severity: Affects Only Me
  Priority: ---
 Component: bin
  Assignee: b...@freebsd.org
  Reporter: lexi.free...@le-fay.org

when using ZFS on certain SSDs, it might be preferable to run a periodic 'zpool
trim' rather than using autotrim.  this patch adds a new daily script
"801.trim-zfs", controlled by "daily_trim_zfs_enable" (default NO) which does a
daily trim of all pools or the pools listed in "daily_trim_zfs_pools".

-- 
You are receiving this mail because:
You are the assignee for the bug.