1NFSTEST_SPARSE(1) nfstest_sparse 1.0 NFSTEST_SPARSE(1)
2
3
4
6 nfstest_sparse - Sparse file tests
7
9 nfstest_sparse --server <server> [options]
10
12 Verify correct functionality of sparse files. These are files which
13 have unallocated or uninitialized data blocks as holes. The new NFSv4.2
14 operation SEEK is used to search for the next hole or data segment in a
15 file.
16
17 Basic tests verify the SEEK operation returns the correct offset of the
18 next hole or data with respect to the starting offset given to the seek
19 system call. Verify the SEEK operation is sent to the server with the
20 correct stateid as a READ call. All files have a virtual hole at the
21 end of the file so when searching for the next hole, even if the file
22 does not have a hole, it returns the size of the file.
23
24 Some tests include testing at the protocol level by taking a packet
25 trace and inspecting the actual packets sent to the server.
26
27 Negative tests include trying to SEEK starting from an offset beyond
28 the end of the file.
29
30
31
33 --version
34 show program's version number and exit
35
36 -h, --help
37 show this help message and exit
38
39 -f FILE, --file=FILE
40 File where options are specified besides the system wide file
41 /etc/nfstest, user wide file $HOME/.nfstest or in the current
42 directory .nfstest file
43
44
45 NFS specific options:
46 -s SERVER, --server=SERVER
47 Server name or IP address
48
49 -e EXPORT, --export=EXPORT
50 Exported file system to mount [default: '/']
51
52 --nfsversion=NFSVERSION
53 NFS version, e.g., 3, 4, 4.1, etc. [default: 4.2]
54
55 -m MTPOINT, --mtpoint=MTPOINT
56 Mount point [default: '/mnt/t']
57
58 -p PORT, --port=PORT
59 NFS server port [default: 2049]
60
61 --proto=PROTO
62 NFS protocol name [default: 'tcp']
63
64 --sec=SEC
65 Security flavor [default: 'sys']
66
67 -o MTOPTS, --mtopts=MTOPTS
68 Mount options [default: 'hard,rsize=4096,wsize=4096']
69
70 --datadir=DATADIR
71 Data directory where files are created, directory is created on
72 the mount point [default: '']
73
74
75 Logging options:
76 -v VERBOSE, --verbose=VERBOSE
77 Verbose level for debug messages [default: 'none']
78
79 --tverbose=TVERBOSE
80 Verbose level for test messages [default: '1']
81
82 --createlog
83 Create log file
84
85 --rexeclog
86 Create rexec log files
87
88 --warnings
89 Display warnings
90
91 --tag=TAG
92 Informational tag, it is displayed as an INFO message [default:
93 '']
94
95 --notty
96 Do not use terminal colors on output
97
98
99 Packet trace options:
100 --createtraces
101 Create a packet trace for each test
102
103 --tbsize=TBSIZE
104 Capture buffer size for tcpdump [default: 192k]
105
106 --trcdelay=TRCDELAY
107 Seconds to delay before stopping packet trace [default: 0.0]
108
109 --keeptraces
110 Do not remove any trace files [default: remove trace files if no
111 errors]
112
113 --rmtraces
114 Remove trace files [default: remove trace files if no errors]
115
116 -i INTERFACE, --interface=INTERFACE
117 Device interface [default: automatically selected]
118
119
120 File options:
121 --nfiles=NFILES
122 Number of files to create [default: 2]
123
124 --filesize=FILESIZE
125 File size to use for test files [default: 64k]
126
127 --rsize=RSIZE
128 Read size to use when reading files [default: 4k]
129
130 --wsize=WSIZE
131 Write size to use when writing files [default: 4k]
132
133 --iodelay=IODELAY
134 Seconds to delay I/O operations [default: 0.1]
135
136 --offset-delta=OFFSET_DELTA
137 Read/Write offset delta [default: 4k]
138
139
140 Path options:
141 --sudo=SUDO
142 Full path of binary for sudo [default: '/usr/bin/sudo']
143
144 --tcpdump=TCPDUMP
145 Full path of binary for tcpdump [default: '/usr/sbin/tcpdump']
146
147 --iptables=IPTABLES
148 Full path of binary for iptables [default: '/usr/sbin/iptables']
149
150 --messages=MESSAGES
151 Full path of log messages file [default: '/var/log/messages']
152
153 --tmpdir=TMPDIR
154 Temporary directory [default: '/tmp']
155
156
157 Debug options:
158 --nocleanup
159 Do not cleanup created files
160
161 --bugmsgs=BUGMSGS
162 File containing test messages to mark as bugs if they failed
163
164 --ignore
165 Ignore all bugs given by bugmsgs
166
167 --nomount
168 Do not mount server and run the tests on local disk space
169
170 --basename=BASENAME
171 Base name for all files and logs [default: automatically gener‐
172 ated]
173
174 --nfsdebug=NFSDEBUG
175 Set NFS kernel debug flags and save log messages [default: '']
176
177 --rpcdebug=RPCDEBUG
178 Set RPC kernel debug flags and save log messages [default: '']
179
180 --pktdisp
181 Display main packets related to the given test
182
183
184 Test options:
185 --runtest=RUNTEST
186 Comma separated list of tests to run, if list starts with a '^'
187 then all tests are run except the ones listed [default: 'all']
188
190 seek
191 Run all SEEK tests: seek01, seek02, seek03, seek04
192
193 seek01
194 Verify SEEK succeeds searching for the next data
195
196 seek02
197 Verify SEEK succeeds searching for the next hole
198
199 seek03
200 Verify SEEK searching for next data fails with ENXIO when offset is beyond the end of the file
201
202 seek04
203 Verify SEEK searching for next hole fails with ENXIO when offset is beyond the end of the file
204
206 The only required option is --server
207 $ nfstest_sparse --server 192.168.0.11
208
210 The user id in the local host must have access to run commands as root
211 using the 'sudo' command without the need for a password.
212
213 Valid only for NFS version 4.2 and above.
214
216 nfstest.test_util(3), nfstest.utils(3), nfstest_alloc(1),
217 nfstest_cache(1), nfstest_delegation(1), nfstest_dio(1),
218 nfstest_file(1), nfstest_interop(1), nfstest_io(1), nfstest_lock(1),
219 nfstest_pkt(1), nfstest_pnfs(1), nfstest_posix(1), nfstest_ssc(1),
220 nfstest_xid(1), packet.nfs.nfs4_const(3)
221
222
224 No known bugs.
225
227 Jorge Mora (mora@netapp.com)
228
229
230
231NFStest 2.1.5 14 February 2017 NFSTEST_SPARSE(1)