1NFSTEST_DELEGATION(1)       nfstest_delegation 1.6       NFSTEST_DELEGATION(1)
2
3
4

NAME

6       nfstest_delegation - Delegation tests
7

SYNOPSIS

9       nfstest_delegation --server <server> [--client <client>] [options]
10

DESCRIPTION

12       Basic delegation tests verify that a correct delegation is granted when
13       opening a file for reading or writing. Also, another OPEN should not be
14       sent  for the same file when the client is holding a delegation. Verify
15       that the stateid  of  all  I/O  operations  should  be  the  delegation
16       stateid.   Reads  from  a different process on the same file should not
17       cause the client to send additional READ packets  when  the  client  is
18       holding  a  read  delegation.  Furthermore, a LOCK packet should not be
19       sent to the server when the client is holding a delegation.
20
21       Recall delegation tests verify the delegation is recalled when  a  con‐
22       flicting  operation is sent to the server from a different client. Con‐
23       flicting operations are reading, writing and changing  the  permissions
24       on the same file. Note, that reading a file from a different client can
25       only recall a read delegation.  Also, verify that a delegation  is  not
26       recalled  when a different client is granted a read delegation. After a
27       delegation is recalled, the client should send an OPEN with CLAIM_DELE‐
28       GATE_CUR  before returning the delegation and the stateid should be the
29       same as the original OPEN stateid. Also, a  delegation  should  not  be
30       granted when re-opening the file right before returning the delegation.
31       Verify client flushes all written data before returning the WRITE dele‐
32       gation.  The LOCK should be sent as well right before returning a dele‐
33       gation which has been recalled. A delegation should not be  granted  on
34       the second client who cause the delegation recall on the first client.
35
36
37

OPTIONS

39       --version
40              show program's version number and exit
41
42       -h, --help
43              show this help message and exit
44
45       -f FILE, --file=FILE
46              File  where  options  are specified besides the system wide file
47              /etc/nfstest, user wide file $HOME/.nfstest or  in  the  current
48              directory .nfstest file
49
50
51   NFS specific options:
52       -s SERVER, --server=SERVER
53              Server name or IP address
54
55       -e EXPORT, --export=EXPORT
56              Exported file system to mount [default: '/']
57
58       --nfsversion=NFSVERSION
59              NFS version, e.g., 3, 4, 4.1, etc. [default: 4.1]
60
61       -m MTPOINT, --mtpoint=MTPOINT
62              Mount point [default: '/mnt/t']
63
64       -p PORT, --port=PORT
65              NFS server port [default: 2049]
66
67       --proto=PROTO
68              NFS protocol name [default: 'tcp']
69
70       --sec=SEC
71              Security flavor [default: 'sys']
72
73       -o MTOPTS, --mtopts=MTOPTS
74              Mount options [default: 'hard,rsize=4096,wsize=4096']
75
76       --datadir=DATADIR
77              Data  directory where files are created, directory is created on
78              the mount point [default: '']
79
80
81   Logging options:
82       -v VERBOSE, --verbose=VERBOSE
83              Verbose level for debug messages [default: 'none']
84
85       --tverbose=TVERBOSE
86              Verbose level for test messages [default: '1']
87
88       --createlog
89              Create log file
90
91       --rexeclog
92              Create rexec log files
93
94       --warnings
95              Display warnings
96
97       --tag=TAG
98              Informational tag, it is displayed as an INFO message  [default:
99              '']
100
101       --notty
102              Do not use terminal colors on output
103
104
105   Packet trace options:
106       --createtraces
107              Create a packet trace for each test
108
109       --tbsize=TBSIZE
110              Capture buffer size for tcpdump [default: 192k]
111
112       --trcdelay=TRCDELAY
113              Seconds to delay before stopping packet trace [default: 0.0]
114
115       --keeptraces
116              Do not remove any trace files [default: remove trace files if no
117              errors]
118
119       --rmtraces
120              Remove trace files [default: remove trace files if no errors]
121
122       -i INTERFACE, --interface=INTERFACE
123              Device interface [default: automatically selected]
124
125
126   File options:
127       --nfiles=NFILES
128              Number of files to create [default: 2]
129
130       --filesize=FILESIZE
131              File size to use for test files [default: 64k]
132
133       --rsize=RSIZE
134              Read size to use when reading files [default: 4k]
135
136       --wsize=WSIZE
137              Write size to use when writing files [default: 4k]
138
139       --iodelay=IODELAY
140              Seconds to delay I/O operations [default: 0.1]
141
142       --offset-delta=OFFSET_DELTA
143              Read/Write offset delta [default: 4k]
144
145
146   Path options:
147       --sudo=SUDO
148              Full path of binary for sudo [default: '/usr/bin/sudo']
149
150       --tcpdump=TCPDUMP
151              Full path of binary for tcpdump [default: '/usr/sbin/tcpdump']
152
153       --iptables=IPTABLES
154              Full path of binary for iptables [default: '/usr/sbin/iptables']
155
156       --messages=MESSAGES
157              Full path of log messages file [default: '/var/log/messages']
158
159       --tmpdir=TMPDIR
160              Temporary directory [default: '/tmp']
161
162
163   Debug options:
164       --nocleanup
165              Do not cleanup created files
166
167       --bugmsgs=BUGMSGS
168              File containing test messages to mark as bugs if they failed
169
170       --ignore
171              Ignore all bugs given by bugmsgs
172
173       --nomount
174              Do not mount server and run the tests on local disk space
175
176       --basename=BASENAME
177              Base name for all files and logs [default: automatically  gener‐
178              ated]
179
180       --nfsdebug=NFSDEBUG
181              Set NFS kernel debug flags and save log messages [default: '']
182
183       --rpcdebug=RPCDEBUG
184              Set RPC kernel debug flags and save log messages [default: '']
185
186       --pktdisp
187              Display main packets related to the given test
188
189
190   Test options:
191       --runtest=RUNTEST
192              Comma  separated list of tests to run, if list starts with a '^'
193              then all tests are run except the ones listed [default: 'all']
194
195       --client=CLIENT
196              Remote NFS client used for recall tests
197
198       --lock-offset=LOCK_OFFSET
199              Starting offset for lock [default: 0]
200
201       --lock-len=LOCK_LEN
202              Number of bytes to lock [default: 0]
203
204       --truncate
205              Truncate file when writing from the second file for  the  recall
206              tests
207

TESTS

209   basic
210       Run all basic delegation tests: basic01, basic02, basic03, basic04,
211       basic05, basic06
212
213   basic01
214       Basic read delegation test
215
216   basic02
217       Basic write delegation test
218
219   basic03
220       Basic read delegation test with file stat
221
222   basic04
223       Basic write delegation test with file stat
224
225   basic05
226       Basic read delegation test with file lock
227
228   basic06
229       Basic write delegation test with file lock
230
231   recall
232       Run all recall delegation tests: recall01, recall02, recall03, recall04,
233       recall05, recall06, recall07, recall08, recall09, recall10
234
235   recall01
236       Recall read delegation by writing from a second client
237
238   recall02
239       Recall write delegation by writing from a second client
240
241   recall03
242       Recall read delegation by writing from a second client with file lock
243
244   recall04
245       Recall write delegation by writing from a second client with file lock
246
247   recall05
248       Recall write delegation by reading from a second client
249
250   recall06
251       Recall write delegation by reading from a second client with file lock
252
253   recall07
254       Recall read delegation by changing the permissions to the file
255
256   recall08
257       Recall write delegation by changing the permissions to the file
258
259   recall09
260       Recall read delegation by changing the permissions to the file with file lock
261
262   recall10
263       Recall write delegation by changing the permissions to the file with file lock
264

EXAMPLES

266       The  only  required  option  is  --server but only the basic delegation
267       tests will be run. Use the --client option to run the recall  tests  as
268       well
269       $ nfstest_delegation --server 192.168.0.11 --client 192.168.0.20
270

NOTES

272       The  user  id in the local host and the host specified by --client must
273       have access to run commands as root using the  'sudo'  command  without
274       the need for a password.
275
276       The user id must be able to 'ssh' to remote host without the need for a
277       password.
278

SEE ALSO

280       nfstest.test_util(3),        nfstest_alloc(1),        nfstest_cache(1),
281       nfstest_dio(1),   nfstest_file(1),  nfstest_interop(1),  nfstest_io(1),
282       nfstest_lock(1),  nfstest_pkt(1),  nfstest_pnfs(1),   nfstest_posix(1),
283       nfstest_sparse(1),            nfstest_ssc(1),           nfstest_xid(1),
284       packet.nfs.nfs4_const(3)
285
286

BUGS

288       No known bugs.
289

AUTHOR

291       Jorge Mora (mora@netapp.com)
292
293
294
295NFStest 2.1.5                  14 February 2017          NFSTEST_DELEGATION(1)
Impressum