3 # Copyright (c) 2000-2001 Silicon Graphics, Inc. All Rights Reserved.
5 #---------------------------------------------------------------------------
6 # CONFIGURATION SECTION:
7 # Configure this script by changing the variables in this section.
8 # Please change ONLY this section!
9 #---------------------------------------------------------------------------
12 base_dir="/home/poplar45/kfr/dmapi/test/laguna/jaytest"
17 # Path to the mountpoint of the test filesystem:
20 # m_main concatenated with d_name == the full test directory path
22 # EXAMPLE: If m_main is "/dmitest", and the test directory
23 # is "/dmitest/test", set this to "/test"
25 d_name="/kfr/test_dir"
27 # Path to the mountpoint of the nfs2 test filesystem:
28 m_nfs2="/dmapi/kfr/nfs2"
30 # Path to the mountpoint of the nfs3 test filesystem:
31 m_nfs3="/dmapi/kfr/nfs3"
33 # Path to the mountpoint of the realtime test filesystem:
35 # Path to the realtime test directory:
38 #--------------------------------------------------------------------
39 # END OF CONFIGURATION SECTION:
40 # No changes should be made past this point! Please change only
41 # the above shell variables to configure this script.
42 #--------------------------------------------------------------------
44 # Path to the "bindir" directory:
45 bin="$base_dir/bindir"
47 # Path to the "generic file" (a copy of ls):
48 ls_path="$bin/ls_to_copy"
50 # Path to the main test directory:
51 d_main="$m_main$d_name"
53 # Path to the nfs2 test directory:
54 d_nfs2="$m_nfs2$d_name"
56 # Path to the nfs3 test directory:
57 d_nfs3="$m_nfs2$d_name"
66 print "+-------------------------+"
67 print "| DMAPI tests: main menu |"
68 print "+-------------------------+\n"
69 select menu1 in 'DMAPI function tests, which run without a daemon' \
70 'DMAPI event tests, which invoke and monitor a daemon' \
71 'Basic DMAPI existence/version test' \
74 'DMAPI function tests, which run without a daemon')
78 then Vstr='turn off verbose mode'
79 else Vstr='turn on verbose mode'
82 print "+----------------------+"
83 print "| DMAPI function tests |"
84 print "+----------------------+\n"
85 select menu2 in 'ALL of the following function tests:' \
87 ' get/set_eventlist' \
88 ' get/set_fileattr, get_bulkattr, get_dirattrs' \
93 ' EACCES errno and access rights' \
94 ' get_allocinfo vs. xfs_bmap' \
95 ' get_allocinfo with various buffer sizes' \
100 'ALL of the following function tests:')
102 "$bin/test_dmattr $Vflag $ls_path $d_main" \
103 "$bin/test_eventlist $Vflag $ls_path $d_main" \
104 "$bin/test_fileattr $Vflag $ls_path $d_main" \
105 "$bin/test_hole $Vflag $ls_path $d_main" \
106 "$bin/test_invis $Vflag $ls_path $d_main" \
107 "$bin/test_region $Vflag $ls_path $d_main" \
108 "$bin/test_efault $Vflag $ls_path $d_main" \
109 "$bin/test_rights $Vflag $ls_path $d_main" \
110 "$bin/test_allocinfo_1 $bin $d_main" \
111 "$bin/test_allocinfo_2 $bin $d_main"
114 print "Press enter to continue..."; read go
118 eval "$bin/test_dmattr $Vflag $ls_path $d_main"
119 print "Press enter to continue..."; read go
121 ' get/set_eventlist')
122 eval "$bin/test_eventlist $Vflag $ls_path $d_main"
123 print "Press enter to continue..."; read go
125 ' get/set_fileattr, get_bulkattr, get_dirattrs')
126 eval "$bin/test_fileattr $Vflag $ls_path $d_main"
127 print "Press enter to continue..."; read go
130 eval "$bin/test_hole $Vflag $ls_path $d_main"
131 print "Press enter to continue..."; read go
134 eval "$bin/test_invis $Vflag $ls_path $d_main"
135 print "Press enter to continue..."; read go
138 eval "$bin/test_region $Vflag $ls_path $d_main"
139 print "Press enter to continue..."; read go
142 eval "$bin/test_efault $Vflag $ls_path $d_main"
143 print "Press enter to continue..."; read go
145 ' EACCES errno and access rights')
146 eval "$bin/test_rights $Vflag $ls_path $d_main"
148 ' get_allocinfo vs. xfs_bmap')
149 eval "$bin/test_allocinfo_1 $bin $d_main"
150 print "Press enter to continue..."; read go
152 ' get_allocinfo with various buffer sizes')
153 eval "$bin/test_allocinfo_2 $bin $d_main"
154 print "Press enter to continue..."; read go
172 'DMAPI event tests, which invoke and monitor a daemon' )
176 then Pstr='turn off pausing after each command'
177 else Pstr='turn on pausing after each command'
180 print "+--------------------------+"
181 print "| DMAPI daemon/event tests |"
182 print "+--------------------------+\n"
183 select menu2 in 'ALL of the following four:' \
185 ' abort responses to events, and other i/o' \
186 ' unsuccessful commands (bad file permissions)' \
188 'realtime filesystem' \
189 'small event queue' \
196 'ALL of the following four:')
198 "$bin/run_test $Pflag -u $p_user -f standard.dat $bin $d_main $m_main" \
199 "$bin/run_test $Pflag -u $p_user $bin $d_main $m_main" \
200 "$bin/run_test $Pflag -u $p_user -f fail.dat $bin $d_main $m_main" \
201 "$bin/run_test $Pflag -u $p_user -f pending.dat $bin $d_main $m_main"
207 eval "$bin/run_test $Pflag -u $p_user -f standard.dat $bin $d_main $m_main"
209 ' abort responses to events, and other i/o')
210 eval "$bin/run_test $Pflag -u $p_user $bin $d_main $m_main"
212 ' unsuccessful commands (bad file permissions)')
213 eval "$bin/run_test $Pflag -u $p_user -f fail.dat $bin $d_main $m_main"
216 eval "$bin/run_test $Pflag -u $p_user -f pending.dat $bin $d_main $m_main"
222 print "+--------------------------------+"
223 print "| DMAPI daemon/event tests: nfs2 |"
224 print "+--------------------------------+\n"
225 select menu3 in 'ALL of the following four:' \
226 ' nfs2: standard i/o' \
227 ' nfs2: abort responses to events, and other i/o' \
228 ' nfs2: unsuccessful commands (bad file permissions)' \
229 ' nfs2: dm_pending' \
233 'ALL of the following four:')
234 eval "$bin/run_test $Pflag -u $p_user -F nfs2 -M $m_nfs2 -R $d_main -f standard_nfs.dat $bin $d_nfs2 $m_main"
235 eval "$bin/run_test $Pflag -u $p_user -F nfs2 -M $m_nfs2 -R $d_main -f nfs.dat $bin $d_nfs2 $m_main"
236 eval "$bin/run_test $Pflag -u $p_user -F nfs2 -M $m_nfs2 -R $d_main -f fail.dat $bin $d_nfs2 $m_main"
237 eval "$bin/run_test $Pflag -u $p_user -F nfs2 -M $m_nfs2 -R $d_main -f pending_nfs.dat $bin $d_nfs2 $m_main"
239 ' nfs2: standard i/o')
240 eval "$bin/run_test $Pflag -u $p_user -F nfs2 -M $m_nfs2 -R $d_main -f standard_nfs.dat $bin $d_nfs2 $m_main"
242 ' nfs2: abort responses to events, and other i/o')
243 eval "$bin/run_test $Pflag -u $p_user -F nfs2 -M $m_nfs2 -R $d_main -f nfs.dat $bin $d_nfs2 $m_main"
245 ' nfs2: unsuccessful commands (bad file permissions)')
246 eval "$bin/run_test $Pflag -u $p_user -F nfs2 -M $m_nfs2 -R $d_main -f fail.dat $bin $d_nfs2 $m_main"
249 eval "$bin/run_test $Pflag -u $p_user -F nfs2 -M $m_nfs2 -R $d_main -f pending_nfs.dat $bin $d_nfs2 $m_main"
263 print "+--------------------------------+"
264 print "| DMAPI daemon/event tests: nfs3 |"
265 print "+--------------------------------+"
266 select menu3 in 'ALL of the following four:' \
267 ' nfs3: standard i/o' \
268 ' nfs3: abort responses to events, and other i/o' \
269 ' nfs3: unsuccessful commands (bad file permissions)' \
270 ' nfs3: dm_pending' \
274 'ALL of the following four:')
275 eval "$bin/run_test $Pflag -u $p_user -F nfs3 -M $m_nfs3 -R $d_main -f standard_nfs.dat $bin $d_nfs3 $m_main"
276 eval "$bin/run_test $Pflag -u $p_user -F nfs3 -M $m_nfs3 -R $d_main -f nfs.dat $bin $d_nfs3 $m_main"
277 eval "$bin/run_test $Pflag -u $p_user -F nfs3 -M $m_nfs3 -R $d_main -f fail.dat $bin $d_nfs3 $m_main"
278 eval "$bin/run_test $Pflag -u $p_user -F nfs3 -M $m_nfs3 -R $d_main -f pending_nfs.dat $bin $d_nfs3 $m_main"
280 ' nfs3: standard i/o')
281 eval "$bin/run_test $Pflag -u $p_user -F nfs3 -M $m_nfs3 -R $d_main -f standard_nfs.dat $bin $d_nfs3 $m_main"
283 ' nfs3: abort responses to events, and other i/o')
284 eval "$bin/run_test $Pflag -u $p_user -F nfs3 -M $m_nfs3 -R $d_main -f nfs.dat $bin $d_nfs3 $m_main"
286 ' nfs3: unsuccessful commands (bad file permissions)')
287 eval "$bin/run_test $Pflag -u $p_user -F nfs3 -M $m_nfs3 -R $d_main -f fail.dat $bin $d_nfs3 $m_main"
290 eval "$bin/run_test $Pflag -u $p_user -F nfs3 -M $m_nfs3 -R $d_main -f pending_nfs.dat $bin $d_nfs3 $m_main"
300 'realtime filesystem')
301 eval "$bin/run_test $Pflag -u $p_user -f realtime.dat $bin $d_rt $m_rt"
304 # Set dm_max_queued to about 5 or so before running!
305 eval "$bin/run_test $Pflag -u $p_user -s 2 -f smallq.dat $bin $d_main $m_main"
321 'Basic DMAPI existence/version test')
322 eval "$bin/check_dmapi $Vflag"
323 print "Press enter to continue..."; read go