2 # SPDX-License-Identifier: GPL-2.0
5 # This file is part of Lustre, http://www.lustre.org/
7 # lustre/tests/run-llog.sh
9 # Script to run the llog_test unit tests
12 LUSTRE=${LUSTRE:-$(dirname "$0")/..}
13 . "$LUSTRE/tests/test-framework.sh"
19 MGS=$($LCTL dl | awk '/mgs/ { print $4 }')
20 [ -z "$MGS" ] && echo "$0: SKIP: no MGS available, skipping llog test" && exit 0
22 load_module kunit/llog_test || exit 1
23 $LCTL modules > "$TMP/ogdb-$(hostname)"
24 echo "NOW reload debugging syms.."
28 # Using ignore_errors will allow lctl to cleanup even if the test fails.
29 eval "$LCTL <<-EOF || RC=2
30 attach llog_test llt_name llt_uuid
33 --device llt_name cleanup
34 --device llt_name detach
39 rmmod -v llog_test || RC2=3
40 [ $RC -eq 0 ] && [ "$RC2" ] && RC=$RC2