1#!/usr/bin/env bash 2 3testdir=$(readlink -f $(dirname $0)) 4rootdir=$(readlink -f $testdir/../..) 5source $rootdir/test/common/autotest_common.sh 6source $rootdir/test/spdkcli/common.sh 7source $rootdir/test/iscsi_tgt/common.sh 8 9MATCH_FILE="spdkcli_raid.test" 10SPDKCLI_BRANCH="/bdevs" 11testdir=$(readlink -f $(dirname $0)) 12. $testdir/common.sh 13 14trap 'on_error_exit;' ERR 15 16timing_enter run_spdk_tgt 17run_spdk_tgt 18timing_exit run_spdk_tgt 19 20timing_enter spdkcli_create_malloc 21$spdkcli_job "'/bdevs/malloc create 8 512 Malloc1' 'Malloc1' True 22'/bdevs/malloc create 8 512 Malloc2' 'Malloc2' True 23" 24timing_exit spdkcli_create_malloc 25 26timing_enter spdkcli_create_raid 27$spdkcli_job "'/bdevs/raid_volume create testraid 0 \"Malloc1 Malloc2\" 4' 'testraid' True 28" 29timing_exit spdkcli_create_raid 30 31timing_enter spdkcli_check_match 32check_match 33timing_exit spdkcli_check_match 34 35timing_enter spdkcli_delete_raid 36$spdkcli_job "'/bdevs/raid_volume delete testraid' '' True 37" 38timing_exit spdkcli_delete_raid 39 40timing_enter spdkcli_delete_malloc 41$spdkcli_job "'/bdevs/malloc delete Malloc1' '' True 42'/bdevs/malloc delete Malloc2' '' True 43" 44timing_exit spdkcli_delete_malloc 45 46killprocess $spdk_tgt_pid 47