1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87
|
% FLASHCACHE_SETIOCTL(8) flashcache_setioctl
%
% October 2012
# NAME
flashcache_setioctl - Set I/O behavior for special process in flashcache
# DESCRIPTION
The **flashcache_setioctl** command can be used to set/remove a
process from flashcache blacklist/whitelist, or clear flashcache
blacklist/whitelist.
# SYNOPSIS
flashcache_setioctl (-c | -a | -r) (-b *pid* |-w *pid*) *ssd_devname*
# OPTIONS
-c
: Clear blacklist/whitelist
-a
: Add to blacklist/whitelist
-r
: Remove from blacklist/whitelist
-b
: Operate on blacklist
-w
: Operate on whitelist
# FLASHCACHE CACHE POLICY
Flashcache can be put in one of 2 modes - Cache Everything or
Cache Nothing (dev.flashcache.cache_all). The defaults is to "cache
everything".
These 2 modes have a blacklist and a whitelist.
The tgid (thread group id) for a group of pthreads can be used as a
shorthand to tag all threads in an application. The tgid for a pthread
is returned by getpid() and the pid of the individual thread is
returned by gettid().
The algorithm works as follows :
In "cache everything" mode,
1) If the pid of the process issuing the IO is in the blacklist, do
not cache the IO. ELSE,
2) If the tgid is in the blacklist, don't cache this IO. UNLESS
3) The particular pid is marked as an exception (and entered in the
whitelist, which makes the IO cacheable).
4) Finally, even if IO is cacheable up to this point, skip sequential IO
if configured by the sysctl.
Conversely, in "cache nothing" mode,
1) If the pid of the process issuing the IO is in the whitelist,
cache the IO. ELSE,
2) If the tgid is in the whitelist, cache this IO. UNLESS
3) The particular pid is marked as an exception (and entered in the
blacklist, which makes the IO non-cacheable).
4) Anything whitelisted is cached, regardless of sequential or random
IO.
# SEE ALSO
`flashcache_create`(8)
*README* and other documents in **/usr/share/doc/flashcache-utils**
The flashcache source code and all documentation may be downloaded from
<https://github.com/facebook/flashcache/>.
# AUTHORS
Flashcache is developed by Mohan Srinivasan <mohan@fb.com>
This man page was written by Liang Guo <guoliang@debian.org>
for Debian GNU/Linux (but may be used by others).
|