Whamcloud - gitweb
LU-16916 tests: fix client_evicted() not to ignore EOPNOTSUPP
[fs/lustre-release.git] / lustre / tests / performance-sanity.sh
1 #!/bin/bash
2 set -e
3
4 TESTNAME=$(basename $0 .sh)
5 LOG=${LOG:-"$TMP/${TESTNAME}.log"}
6
7 LUSTRE=${LUSTRE:-$(dirname $0)/..}
8 . $LUSTRE/tests/test-framework.sh
9 init_test_env $@
10 init_logging
11
12 ALWAYS_EXCEPT="$PERFORMANCE_SANITY_EXCEPT "
13 # bug number:    LU-16658
14 ALWAYS_EXCEPT+=" 6 "
15
16 build_test_filter
17
18 [ -x "$MDSRATE" ] || FAIL_ON_ERROR=true error "No mdsrate program. Aborting."
19 which mpirun > /dev/null 2>&1 ||
20         FAIL_ON_ERROR=true error "No mpirun program. Aborting."
21
22 get_mpiuser_id $MPI_USER
23 MPI_RUNAS=${MPI_RUNAS:-"runas -u $MPI_USER_UID -g $MPI_USER_GID"}
24 $GSS_KRB5 && refresh_krb5_tgt $MPI_USER_UID $MPI_USER_GID $MPI_RUNAS
25
26 # mdsrate-create-small
27 test_3() {
28     echo "File creation performance tests for file objects"
29     bash mdsrate-create-small.sh
30 }
31 run_test 3 "small file create/open/delete ======"
32
33 # mdsrate-create-large
34 test_4() {
35         # LU-2600/LU-4108 - Decrease load on zfs
36         [ "$SLOW" = no -a "$mds1_FSTYPE" = zfs ] &&
37                 NUM_FILES=10000
38         echo "Large file creation performance"
39         bash mdsrate-create-large.sh
40 }
41 run_test 4 "large file create/open/delete"
42
43 # mdsrate-lookup-1dir
44 test_5() {
45     echo "Single directory lookup retrieval rate"
46     bash mdsrate-lookup-1dir.sh
47 }
48 run_test 5 "lookup rate 10M file dir ======"
49
50 # mdsrate-lookup-10dir
51 test_6() {
52     echo "Directory lookup retrieval rate 10 directories, 1 million files each"
53     bash mdsrate-lookup-10dirs.sh
54 }
55 run_test 6 "lookup rate 10M file 10 dir ======"
56
57 # mdsrate-stat-small
58 test_7() {
59     echo "File attribute retrieval rate for small file creation"
60     bash mdsrate-stat-small.sh
61 }
62 run_test 7 "getattr small file ======"
63
64 # mdsrate-stat-large
65 test_8() {
66     echo "File attribute retrieval rate for large file creation"
67     bash mdsrate-stat-large.sh
68 }
69 run_test 8 "getattr large files ======"
70
71 complete $SECONDS
72 check_and_cleanup_lustre
73 [ -f "$LOG" ] && cat $LOG || true
74 exit_status