From: Martin Steigerwald <Martin@lichtvoll.de>
To: linux-btrfs@vger.kernel.org
Subject: Re: fstrim not working on one of three BTRFS filesystems
Date: Mon, 29 Dec 2014 14:23:38 +0100 [thread overview]
Message-ID: <2085969.4UDoZBNBiV@merkaba> (raw)
In-Reply-To: <3979684.puYLD8DjTq@merkaba>
Am Sonntag, 28. Dezember 2014, 17:58:17 schrieb Martin Steigerwald:
> Hi!
>
> After my recent tests with my /home filesystem and the up and downsizing of
> it I get:
>
>
> merkaba:~> LANG=C fstrim -v /home
> /home: 0 B (0 bytes) trimmed
> merkaba:~> LANG=C fstrim -v /
> /: 24.5 GiB (26257555456 bytes) trimmed
> merkaba:~> LANG=C fstrim -v /daten
> /daten: 2.8 GiB (3016101888 bytes) trimmed
>
>
> The fstrim on /home returns immediately. It does not even seem to trim
> anything. What could be the cause for that?
I have a 3.19-rc2 with a patch and a working fstrim now:
merkaba:~> btrfs scrub status /home
scrub status for […]
scrub started at Mon Dec 29 13:48:17 2014 and finished after 568 seconds
total bytes scrubbed: 272.73GiB with 0 errors
merkaba:~> fstrim -v /home
/home: 18,5 GiB (19873382400 Bytes) getrimmt
merkaba:~> btrfs scrub status /home
scrub status for […]
scrub started at Mon Dec 29 14:02:58 2014 and finished after 576 seconds
total bytes scrubbed: 272.82GiB with 0 errors
merkaba:~> btrfs fi df /home
Data, RAID1: total=139.93GiB, used=133.19GiB
System, RAID1: total=32.00MiB, used=48.00KiB
Metadata, RAID1: total=4.99GiB, used=3.24GiB
GlobalReserve, single: total=512.00MiB, used=0.00B
merkaba:~> LANG=C df -hT /home
Filesystem Type Size Used Avail Use% Mounted on
/dev/mapper/msata-home btrfs 170G 137G 32G 82% /home
I wonder about the trimmed size tough:
139,93 - 133,19 = 6,74
4,99 - 3,24 = 1,74
( 6,74 + 1,74 ) * 2 = 16,96 GiB
It is more than whats free inside the chunks but less than the total unused
space. Well it may have been up to what has been allocated as chunks
as I had more chunks allocated in it.
I leave it to the patch author to come up with it on the mailing list :)
Ciao,
--
Martin 'Helios' Steigerwald - http://www.Lichtvoll.de
GPG: 03B0 0D6C 0040 0710 4AFA B82F 991B EAAC A599 84C7
next prev parent reply other threads:[~2014-12-29 13:25 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-12-28 16:58 fstrim not working on one of three BTRFS filesystems Martin Steigerwald
2014-12-29 1:53 ` Robert White
2014-12-29 2:08 ` Duncan
2014-12-29 9:06 ` Martin Steigerwald
2014-12-29 13:23 ` Martin Steigerwald [this message]
-- strict thread matches above, loose matches on Subject: below --
2012-02-05 20:37 Bulk discard doesn't work after add/delete of devices Lutz Euler
2012-02-09 8:42 ` Liu Bo
2012-02-09 15:50 ` Lutz Euler
2012-02-10 1:56 ` Liu Bo
2012-02-12 17:01 ` Lutz Euler
2012-02-13 5:57 ` Liu Bo
2012-02-14 17:32 ` Lutz Euler
2012-02-29 0:17 ` Lutz Euler
2012-04-10 17:34 ` Lutz Euler
2012-11-14 21:10 ` Lutz Euler
2012-11-14 21:17 ` [PATCH] Btrfs: really fix trim 0 bytes after a device delete Lutz Euler
2015-01-03 15:30 ` [PATCH V2] " Lutz Euler
2015-01-03 16:16 ` fstrim not working on one of three BTRFS filesystems Lutz Euler
2015-05-19 15:18 ` Rich Freeman
2015-01-05 16:59 ` [PATCH V2] Btrfs: really fix trim 0 bytes after a device delete Martin Steigerwald
2015-01-05 19:29 ` Lutz Euler
2015-05-01 10:43 ` Martin Steigerwald
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=2085969.4UDoZBNBiV@merkaba \
--to=martin@lichtvoll.de \
--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;
as well as URLs for NNTP newsgroup(s).