Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1452198

Re: To add, or not to add, a bio REQ_ROTATIONAL flag

From "Martin K. Petersen" <martin.petersen@oracle.com>
Newsgroups linux.kernel
Subject Re: To add, or not to add, a bio REQ_ROTATIONAL flag
Date 2016-07-29 03:20 +0200
Message-ID <s04CZ-5Yi-1@gated-at.bofh.it> (permalink)
References <s04jD-5AF-7@gated-at.bofh.it>
Organization Oracle Corporation

Show all headers | View raw


>>>>> "Eric" == Eric Wheeler <bcache@lists.ewheeler.net> writes:

Eric,

Eric> However, just because FADV_SEQUENTIAL is flagged doesn't mean the
Eric> cache should bypass.  Filesystems can fragment, and while the file
Eric> being read may be read sequentially, the blocks on which it
Eric> resides may not be.  Same thing for higher-level block devices
Eric> such as dm-thinp where one might sequentially read a thin volume
Eric> but its _tdata might not be in linear order.  This may imply that
Eric> we need a new way to flag cache bypass from userspace that is
Eric> neither io-priority nor fadvise driven.

Why conflate the two? Something being a background task is orthogonal to
whether it is being read sequentially or not.

Eric> So what are our options?  What might be the best way to do this?

For the SCSI I/O hints I use the idle I/O priority to classify
backups. Works fine.

Eric> Are FADV_NOREUSE/FADV_DONTNEED reasonable candidates?

FADV_DONTNEED was intended for this. There have been patches posted in
the past that tied the loop between the fadvise flags and the bio. I
would like to see those revived.

Eric> Perhaps ionice could be used used, but the concept of "priority"
Eric> doesn't exactly encompass the concept of cache-bypass---so is
Eric> something else needed?

The idle class explicitly does not have a priority.

-- 
Martin K. Petersen	Oracle Linux Engineering

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

To add, or not to add, a bio REQ_ROTATIONAL flag Eric Wheeler <bcache@lists.ewheeler.net> - 2016-07-29 03:00 +0200
  Re: To add, or not to add, a bio REQ_ROTATIONAL flag "Martin K. Petersen" <martin.petersen@oracle.com> - 2016-07-29 03:20 +0200
    Re: To add, or not to add, a bio REQ_ROTATIONAL flag Eric Wheeler <bcache@lists.ewheeler.net> - 2016-08-01 05:00 +0200
  Re: To add, or not to add, a bio REQ_ROTATIONAL flag Wols Lists <antlists@youngman.org.uk> - 2016-07-29 03:20 +0200

csiph-web