Linux Btrfs filesystem development
 help / color / mirror / Atom feed
From: Adam Borowski <kilobyte@angband.pl>
To: linux-btrfs@vger.kernel.org
Subject: Re: weekly fstrim (still) necessary?
Date: Sun, 21 Jun 2020 20:19:27 +0200	[thread overview]
Message-ID: <20200621181927.GA16529@angband.pl> (raw)
In-Reply-To: <20200621054240.GA25387@tik.uni-stuttgart.de>

On Sun, Jun 21, 2020 at 07:42:40AM +0200, Ulli Horlacher wrote:
> On SLES a weekly fstrim is done via a btrfsmaintenance script, which is
> missing on Ubuntu.
> 
> For ext4 filesystem an explicite fstrim call is no longer neccessary, what
> about btrfs?
> Shall I call fstrim via /etc/cron.weekly ?

Both ext4 and btrfs may or may not auto-discard in the write path, depending
on mount option.  A lot of disks handle such frequent small discards poorly
-- usually with a greatly decreased performance, although data loss in not
unknown.

If you test your disk and know that it is happy with tons of small discards,
then the discard mount option is good for you.  Otherwise, you want to do
large discards once in a while -- be it a day or a week.

Not discarding at all is a bad idea on most disks.


Meow!
-- 
⢀⣴⠾⠻⢶⣦⠀
⣾⠁⢠⠒⠀⣿⡁ in the beginning was the boot and root floppies and they were good.
⢿⡄⠘⠷⠚⠋⠀                                       -- <willmore> on #linux-sunxi
⠈⠳⣄⠀⠀⠀⠀

  parent reply	other threads:[~2020-06-21 18:20 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-06-21  5:42 weekly fstrim (still) necessary? Ulli Horlacher
2020-06-21  7:01 ` Andrei Borzenkov
2020-06-21 16:24 ` Lukas Tribus
2020-06-21 18:19 ` Adam Borowski [this message]
2020-06-21 19:39 ` Chris Murphy
2020-06-21 23:52   ` Ulli Horlacher
2020-06-21 23:57     ` Chris Murphy
2020-06-22  0:06       ` Ulli Horlacher
2020-06-22  0:57         ` Chris Murphy
2020-06-22 14:02           ` Ulli Horlacher
2020-06-22 14:23             ` David Sterba
2020-06-22 15:56               ` Chris Mason
2020-06-26 12:08                 ` Fwd: " Tim Cuthbertson
2020-06-26 15:40                   ` Chris Mason
2020-06-26 16:40                     ` Chris Murphy
2020-06-26 16:48                       ` Chris Mason
2020-06-26 19:32                       ` Tim Cuthbertson
     [not found]                     ` <CAAKzf7kMFqkrQyRzJ6WHVE95PBm2e0BX+QBua-2-rasp=BR7FQ@mail.gmail.com>
2020-06-26 19:33                       ` Fwd: " Tim Cuthbertson
     [not found]                       ` <00D64498-C734-4D08-8FBE-019B7292BE8E@fb.com>
2020-06-26 19:52                         ` Tim Cuthbertson
2020-06-26 20:18                     ` Remi Gauvin
2020-06-26 20:49                       ` Roman Mamedov
2020-06-27 12:13                 ` Jan Killius

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20200621181927.GA16529@angband.pl \
    --to=kilobyte@angband.pl \
    --cc=linux-btrfs@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox