Whamcloud - gitweb
LU-16756 kernel: RHEL 9.2 server support
[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 always_except LU-16658 6
14 build_test_filter
15
16 [ -x "$MDSRATE" ] || FAIL_ON_ERROR=true error "No mdsrate program. Aborting."
17 which mpirun > /dev/null 2>&1 ||
18         FAIL_ON_ERROR=true error "No mpirun program. Aborting."
19
20 get_mpiuser_id $MPI_USER
21 MPI_RUNAS=${MPI_RUNAS:-"runas -u $MPI_USER_UID -g $MPI_USER_GID"}
22 $GSS_KRB5 && refresh_krb5_tgt $MPI_USER_UID $MPI_USER_GID $MPI_RUNAS
23
24 # mdsrate-create-small
25 test_3() {
26     echo "File creation performance tests for file objects"
27     bash mdsrate-create-small.sh
28 }
29 run_test 3 "small file create/open/delete ======"
30
31 # mdsrate-create-large
32 test_4() {
33         # LU-2600/LU-4108 - Decrease load on zfs
34         [ "$SLOW" = no -a "$mds1_FSTYPE" = zfs ] &&
35                 NUM_FILES=10000
36         echo "Large file creation performance"
37         bash mdsrate-create-large.sh
38 }
39 run_test 4 "large file create/open/delete"
40
41 # mdsrate-lookup-1dir
42 test_5() {
43     echo "Single directory lookup retrieval rate"
44     bash mdsrate-lookup-1dir.sh
45 }
46 run_test 5 "lookup rate 10M file dir ======"
47
48 # mdsrate-lookup-10dir
49 test_6() {
50     echo "Directory lookup retrieval rate 10 directories, 1 million files each"
51     bash mdsrate-lookup-10dirs.sh
52 }
53 run_test 6 "lookup rate 10M file 10 dir ======"
54
55 # mdsrate-stat-small
56 test_7() {
57     echo "File attribute retrieval rate for small file creation"
58     bash mdsrate-stat-small.sh
59 }
60 run_test 7 "getattr small file ======"
61
62 # mdsrate-stat-large
63 test_8() {
64     echo "File attribute retrieval rate for large file creation"
65     bash mdsrate-stat-large.sh
66 }
67 run_test 8 "getattr large files ======"
68
69 complete $SECONDS
70 check_and_cleanup_lustre
71 [ -f "$LOG" ] && cat $LOG || true
72 exit_status