From: Karel Zak <kzak@redhat.com>
To: Marcos Mello <marcosfrm@gmail.com>
Cc: util-linux@vger.kernel.org
Subject: Re: Automatic SSD trim script
Date: Mon, 13 Jan 2014 13:12:31 +0100 [thread overview]
Message-ID: <20140113121231.GB12700@x2.net.home> (raw)
In-Reply-To: <loom.20131217T203643-235@post.gmane.org>
On Tue, Dec 17, 2013 at 07:46:35PM +0000, Marcos Mello wrote:
> Karel Zak <kzak@...> writes:
>
> >
> > On Mon, Dec 09, 2013 at 02:43:32PM +0100, Lukáš Czerner wrote:
> > > > All we need is to link fstrim with libmount and lib/sysfs.c, add a new
> > > > option --all and check non-zero
> /sys/block/≤name>/queue/discard_granularity
> > > > (or so).
> > >
> > > Yes and yes. This is the ultimate solution. Simply being able to run
> > > fstrim --all to discard free space on all the mounted supported file
> > > systems is great idea. In that case we do not need any scripts at
> > > all.
> >
> > Implemented. Sten, maybe you can try fstrim --all from git tree
> > in your crontab.
> >
>
> Thanks, Karel!
>
> Would it be possible add an option for the "--all" mode to tell fstrim skip
> mountpoints witch have "discard" option in fstab?
It seems like unnecessary optimization -- the overhead on filesystem with
active discard is minimal.
(And according to Lukas in some cases FSTRIM ioctl can help you
with deleted files smaller than than discard_granularity.)
Karel
--
Karel Zak <kzak@redhat.com>
http://karelzak.blogspot.com
prev parent reply other threads:[~2014-01-13 12:12 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-12-05 19:20 Automatic SSD trim script Sten Heinze
2013-12-06 10:49 ` Karel Zak
2013-12-09 13:43 ` Lukáš Czerner
2013-12-10 15:44 ` Karel Zak
2013-12-11 2:07 ` Sten Heinze
2013-12-11 10:54 ` Pádraig Brady
2013-12-11 11:36 ` Karel Zak
2013-12-11 16:03 ` Karel Zak
2013-12-17 19:46 ` Marcos Mello
2013-12-17 19:58 ` Marcos Mello
2014-01-13 12:12 ` Karel Zak [this message]
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=20140113121231.GB12700@x2.net.home \
--to=kzak@redhat.com \
--cc=marcosfrm@gmail.com \
--cc=util-linux@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