lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:   Wed, 30 May 2018 12:15:07 -0400
From:   "Theodore Y. Ts'o" <tytso@....edu>
To:     Adrian Hunter <adrian.hunter@...el.com>
Cc:     Christoph Hellwig <hch@....de>, Faiz Abbas <faiz_abbas@...com>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        linux-omap <linux-omap@...r.kernel.org>,
        linux-mmc <linux-mmc@...r.kernel.org>,
        linux-block <linux-block@...r.kernel.org>,
        Ulf Hansson <ulf.hansson@...aro.org>,
        Jens Axboe <axboe@...nel.dk>, linux-ext4@...r.kernel.org
Subject: Re: mmc filesystem performance decreased on the first write after
 filesystem creation

On Wed, May 30, 2018 at 11:51:41AM +0300, Adrian Hunter wrote:
> 
> And discards are not enabled by default by mount so, at least on ext4,
> adding "-o discard" is needed in the mount options.

This is because doing discards right away is not always a win from
performance reasons.  There are some flash devices where discards are
super-slow and some devices where issuing discards too quickly would
cause them to trigger internal FTL race conditions and turn them into
paperweights.

There was at least one engineer from a Linux distribution who argued
for making discard not the default because back then, there were a lot
of SSD's floating out there (by a manufacturer who thankfully has
since gone bankrupt :-) for which they didn't want to deal with the
support requests from people who were angry about lost data or
destroyed SSD's --- because guess who they would blame?

Also, please note that for many devices it's much better to
periodically run fstrim (once a day or once a week) out of cron.

If someone wants to do a survey of available hardware and demonstrate:

   * there is significant value from enabling -o discard by default
     (instead of using fstrim)

   * there are no (or at least very, very few) devices for which
     enabling -o discard results in a major performance regression,
     and

   * if there are any devices left that turn into paperweights, they can
     be managed using blacklists,

I'm certainly open to changing the default.  There was, however, a
really good *reason* why the default was chosen to be the way it is.

					- Ted

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ