1nbdkit-delay-filter(1)              NBDKIT              nbdkit-delay-filter(1)
2
3
4

NAME

6       nbdkit-delay-filter - nbdkit delay filter
7

SYNOPSIS

9        nbdkit --filter=delay plugin rdelay=SECS wdelay=SECS [plugin-args...]
10
11        nbdkit --filter=delay plugin rdelay=NNms wdelay=NNms [plugin-args...]
12
13        nbdkit --filter=delay plugin [plugin-args ...]
14                 delay-read=(SECS|NNms) delay-write=(SECS|NNms)
15                 delay-zero=(SECS|NNms) delay-trim=(SECS|NNms)
16                 delay-extents=(SECS|NNms) delay-cache=(SECS|NNms)
17                 delay-fast-zero=BOOL
18

DESCRIPTION

20       "nbdkit-delay-filter" is a filter that delays read and write requests
21       by some seconds or milliseconds.  This is used to simulate a slow or
22       remote server, or to test certain kinds of race conditions in Linux.
23       To limit server bandwidth use nbdkit-rate-filter(1) instead.
24

EXAMPLES

26       Delays reads and writes by 100ms:
27
28        nbdkit --filter=delay file disk.img rdelay=100ms wdelay=100ms
29
30       Delay only zero operations by 1 second, nothing else is affected:
31
32        nbdkit --filter=delay file disk.img delay-zero=1
33

PARAMETERS

35       rdelay=SECS
36       rdelay=NNms
37       delay-read=SECS
38       delay-read=NNms
39           Delay read operations by "SECS" seconds or "NN" milliseconds.
40
41           The two forms "rdelay" and "delay-read" work identically.
42
43       delay-write=SECS
44       delay-write=NNms
45           Delay write operations by "SECS" seconds or "NN" milliseconds.
46
47       delay-zero=SECS
48       delay-zero=NNms
49           Delay zero operations by "SECS" seconds or "NN" milliseconds.  See
50           also delay-fast-zero.
51
52       delay-trim=SECS
53       delay-trim=NNms
54           Delay trim/discard operations by "SECS" seconds or "NN"
55           milliseconds.
56
57       delay-extents=SECS
58       delay-extents=NNms
59           Delay block status (extents) operations by "SECS" seconds or "NN"
60           milliseconds.
61
62       delay-cache=SECS
63       delay-cache=NNms
64           Delay advisory cache operations by "SECS" seconds or "NN"
65           milliseconds.
66
67       wdelay=SECS
68       wdelay=NNms
69           Delay write, zero and trim operations by "SECS" seconds or "NN"
70           milliseconds.
71
72       delay-fast-zero=BOOL
73           The NBD specification documents an extension called fast zero, in
74           which the client may request that a server should reply with
75           "ENOTSUP" as soon as possible if the zero operation offers no real
76           speedup over a corresponding write.  By default, this parameter is
77           true, and fast zero requests are serviced by the plugin after the
78           same delay as any other zero request; but setting this parameter to
79           false instantly fails a fast zero response without waiting for or
80           consulting the plugin.
81

FILES

83       $filterdir/nbdkit-delay-filter.so
84           The filter.
85
86           Use "nbdkit --dump-config" to find the location of $filterdir.
87

VERSION

89       "nbdkit-delay-filter" first appeared in nbdkit 1.2, based on earlier
90       "rdelay" and "wdelay" options in nbdkit-file-plugin(1).
91

SEE ALSO

93       nbdkit(1), nbdkit-filter(3), nbdkit-rate-filter(1).
94

AUTHORS

96       Richard W.M. Jones
97
99       Copyright (C) 2018 Red Hat Inc.
100

LICENSE

102       Redistribution and use in source and binary forms, with or without
103       modification, are permitted provided that the following conditions are
104       met:
105
106       ·   Redistributions of source code must retain the above copyright
107           notice, this list of conditions and the following disclaimer.
108
109       ·   Redistributions in binary form must reproduce the above copyright
110           notice, this list of conditions and the following disclaimer in the
111           documentation and/or other materials provided with the
112           distribution.
113
114       ·   Neither the name of Red Hat nor the names of its contributors may
115           be used to endorse or promote products derived from this software
116           without specific prior written permission.
117
118       THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND ANY
119       EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
120       IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
121       PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR CONTRIBUTORS BE
122       LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
123       CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
124       SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
125       BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
126       WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
127       OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
128       ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
129
130
131
132nbdkit-1.18.4                     2020-04-16            nbdkit-delay-filter(1)
Impressum