From: Chao Yu <yuchao0@huawei.com>
To: John <graysky@archlinux.us>, Jaegeuk Kim <jaegeuk@kernel.org>
Cc: linux-f2fs-devel@lists.sourceforge.net
Subject: Re: [f2fs-dev] fstrim does not recognize FSVER=1.13 of F2FS partitions
Date: Tue, 24 Mar 2020 10:32:26 +0800 [thread overview]
Message-ID: <8b47e963-9e12-c945-e40e-a9d54a412d52@huawei.com> (raw)
In-Reply-To: <CAO_nJAbyEcTR4wFytJp1HQmQBDzpwycKhA_-FUwo39WVMceuZw@mail.gmail.com>
On 2020/3/24 4:12, John wrote:
> On Mon, Mar 23, 2020 at 11:02 AM Jaegeuk Kim <jaegeuk@kernel.org> wrote:
>>> /dev/mapper/media-crypt /mnt/media f2fs
>>> rw,lazytime,relatime,background_gc=on,discard,no_heap,user_xattr,inline_xattr,acl,inline_data,inline_dentry,flush_merge,extent_cache,mode=adaptive,active_logs=6,alloc_mode=default,fsync_mode=posix
>>
>> - media-crypt means dm-crypt? Any chance to try raw sda?
>
> Yes, it is dm-crypt.
>
>> Could you try this?
>> - mount -o remount,nodiscard
>> : The reason is, as f2fs uses async discard feature with -o discard, it doesn't
>> give 0 bytes on fstrim sometimes.
>
> I can confirm it is mounted now with the nodiscard option, but fstrim
> still claims discard is not supported.
Can you try below command and show us the result to see whether device supports discard:
strace blkdiscard -o 0 -l 4096 /dev/mapper/media-crypt
It may discard first 4k block which is first superblock of f2fs, for safety, it will
be better to backup all your data before executing the command.
Thanks,
>
> % mount | grep crypt
> /dev/mapper/media-crypt on /mnt/media type f2fs
> (rw,relatime,lazytime,background_gc=on,nodiscard,no_heap,user_xattr,inline_xattr,acl,inline_data,inline_dentry,flush_merge,extent_cache,mode=adaptive,active_logs=6,alloc_mode=default,fsync_mode=posix,x-systemd.automount)
>
> # fstrim -v /mnt/media
> fstrim: /mnt/media: the discard operation is not supported
> .
>
_______________________________________________
Linux-f2fs-devel mailing list
Linux-f2fs-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel
next prev parent reply other threads:[~2020-03-24 2:32 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-03-14 18:09 [f2fs-dev] fstrim does not recognize FSVER=1.13 of F2FS partitions John
2020-03-16 1:24 ` Chao Yu
2020-03-16 9:52 ` John
2020-03-17 1:44 ` Chao Yu
2020-03-18 20:25 ` John
2020-03-23 4:11 ` Jaegeuk Kim
2020-03-23 10:27 ` John
2020-03-23 15:02 ` Jaegeuk Kim
2020-03-23 20:12 ` John
2020-03-24 2:32 ` Chao Yu [this message]
[not found] ` <CAO_nJAYWQWrWaQVfUmVpJGFtOeKKE76im-AkLUDTJm8DN4VAgA@mail.gmail.com>
[not found] ` <2292eb8d-8357-227f-5448-d1d03b33c042@huawei.com>
2020-03-25 13:58 ` John
2020-03-25 15:28 ` Jaegeuk Kim
2020-03-25 18:41 ` John
2020-03-25 19:04 ` John
2020-03-25 19:59 ` Jaegeuk Kim
2020-03-25 21:13 ` John
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=8b47e963-9e12-c945-e40e-a9d54a412d52@huawei.com \
--to=yuchao0@huawei.com \
--cc=graysky@archlinux.us \
--cc=jaegeuk@kernel.org \
--cc=linux-f2fs-devel@lists.sourceforge.net \
/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).