All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jens Axboe <axboe@fb.com>
To: Jeff Moyer <jmoyer@redhat.com>
Cc: <linux-fsdevel@vger.kernel.org>, <linux-block@vger.kernel.org>,
	<calvinowens@fb.com>, <hch@lst.de>, <adilger@dilger.ca>,
	"Martin K. Petersen" <martin.petersen@oracle.com>
Subject: Re: [PATCH 0/11] Update version of write stream ID patchset
Date: Fri, 4 Mar 2016 15:13:38 -0700	[thread overview]
Message-ID: <56DA0892.4050007@fb.com> (raw)
In-Reply-To: <x49y49xnbop.fsf@segfault.boston.devel.redhat.com>

On 03/04/2016 03:03 PM, Jeff Moyer wrote:
> Jens Axboe <axboe@fb.com> writes:
>
>> On 03/04/2016 02:01 PM, Jeff Moyer wrote:
>>> OK.  I'm still of the opinion that we should try to make this
>>> transparent.  I could be swayed by workload descriptions and numbers
>>> comparing approaches, though.
>>
>> You can't just waive that flag and not have a solution. Any solution
>> in that space would imply having policy in the kernel. A "just use a
>> stream per file" is never going to work.
>
> Jens, I'm obviously missing a lot of the background information, here.
> I want to stress that I'm not against your patches. I'm just trying to
> understand if there's a sensible way to use the write stream support in
> the kernel so that applcations don't /have/ to be converted.  It sounds
> like that's hard, and without any specs or hardware, I'm not going to be
> able to even try to come up with solutions to that problem.

It's not hard to update an application to do this. As an example, one 
thing I tried was converting RocksDB to use streams. A naive approach 
was used, where we simply mapped each compaction level to a specific 
stream, and got about a 30% reduction in WA just through that. The guys 
from Samsung has done that with RocksDB as well, just a bit more 
involved, and got better results. The application change was really no 
more involved than calling fadvise() on the fd after opening it. That is 
it. I don't know why you think that is hard.

As to doing this automagically, you'll need knowledge that you do not 
have. The kernel or file system has no idea if data written to file X 
and file Y have similar life times. You could start tracking that, of 
course, but that would make you very unhappy. If I'm an application 
storing files, I have a much better idea of what is related time wise.

And you don't really need a spec to understand how this works, the spec 
will just tell you the mechanics of how we pass this information to the 
device, how we find out what the device can support, etc. The basic gist 
of it is that we can write data with similar life times to the right 
place on media. For a flash disk, that would be the same EB.

> I think it
> would make for interesting research, though.  I recall a paper from one
> of the USENIX conferences that dealt with automatically identifying
> write streams on a network storage server, but alas, I can't find the
> reference right now.

Samsung released a paper on RocksDB and streams, iirc.


-- 
Jens Axboe


  reply	other threads:[~2016-03-04 22:13 UTC|newest]

Thread overview: 36+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-03-04 16:10 [PATCH 0/11] Update version of write stream ID patchset Jens Axboe
2016-03-04 16:10 ` [PATCH 01/11] idr: make ida_simple_remove() return an error Jens Axboe
2016-03-04 16:10 ` [PATCH 02/11] block: add support for carrying a stream ID in a bio Jens Axboe
2016-03-04 16:10 ` [PATCH 03/11] Add support for per-file/inode stream ID Jens Axboe
     [not found]   ` <CAJVOszBXU-qQENcOGG8pWeARwoWL2G3gNJ0H2uNPjXkiVa8S+Q@mail.gmail.com>
2016-03-04 20:35     ` Jens Axboe
2016-03-04 16:10 ` [PATCH 04/11] Add system call for setting inode/file write " Jens Axboe
2016-03-04 16:10 ` [PATCH 05/11] wire up system call for x86/x86-64 Jens Axboe
2016-03-04 16:10 ` [PATCH 06/11] Add support for bdi tracking of stream ID Jens Axboe
2016-03-04 16:10 ` [PATCH 07/11] direct-io: add support for write stream IDs Jens Axboe
2016-03-04 16:10 ` [PATCH 08/11] Add stream ID support for buffered mpage/__block_write_full_page() Jens Axboe
2016-03-04 16:10 ` [PATCH 09/11] btrfs: add support for write stream IDs Jens Axboe
2016-03-04 20:44   ` Chris Mason
2016-03-04 20:45     ` Jens Axboe
2016-03-04 16:10 ` [PATCH 10/11] xfs: add support for buffered writeback stream ID Jens Axboe
2016-03-04 16:10 ` [PATCH 11/11] ext4: add support for write stream IDs Jens Axboe
2016-03-04 19:42 ` [PATCH 0/11] Update version of write stream ID patchset Jeff Moyer
2016-03-04 20:34   ` Jens Axboe
2016-03-04 21:01     ` Jeff Moyer
2016-03-04 21:06       ` Jens Axboe
2016-03-04 22:03         ` Jeff Moyer
2016-03-04 22:13           ` Jens Axboe [this message]
2016-03-05 20:48         ` Martin K. Petersen
2016-03-08 21:56           ` Jens Axboe
2016-03-17 23:43             ` Dan Williams
2016-03-18  0:18               ` Jens Axboe
2016-03-18  2:39                 ` Martin K. Petersen
2016-03-18 17:37                   ` Jens Axboe
2016-03-18 17:56                     ` Dan Williams
2016-03-06  6:13 ` Andreas Dilger
2016-03-06 13:03   ` Martin K. Petersen
2016-03-06 16:08     ` Boaz Harrosh
2016-03-06 20:51       ` Shaun Tancheff
2016-03-07 15:41         ` Martin K. Petersen
2016-03-07 15:34       ` Martin K. Petersen
2016-03-06 22:42     ` Andreas Dilger
2016-03-07 15:52       ` Martin K. Petersen

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=56DA0892.4050007@fb.com \
    --to=axboe@fb.com \
    --cc=adilger@dilger.ca \
    --cc=calvinowens@fb.com \
    --cc=hch@lst.de \
    --cc=jmoyer@redhat.com \
    --cc=linux-block@vger.kernel.org \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=martin.petersen@oracle.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.