test/nvmf: TLS test
This new test uses new ssl socket implementation to create and test NVMe/TCP with TLS. Signed-off-by: Boris Glimcher <Boris.Glimcher@emc.com> Change-Id: I8c8f81fbc20d5811ecbc94d849a364e4f3f3945c Signed-off-by: Boris Glimcher <Boris.Glimcher@emc.com> Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/12379 Community-CI: Broadcom CI <spdk-ci.pdl@broadcom.com> Tested-by: SPDK CI Jenkins <sys_sgci@intel.com> Reviewed-by: Ben Walker <benjamin.walker@intel.com> Reviewed-by: Shuhei Matsumoto <smatsumoto@nvidia.com> Reviewed-by: Jim Harris <james.r.harris@intel.com>
This commit is contained in:
parent
2fb5ff4985
commit
3781c0ea85
@ -72,6 +72,7 @@ fi
|
|||||||
run_test "nvmf_queue_depth" test/nvmf/target/queue_depth.sh "${TEST_ARGS[@]}"
|
run_test "nvmf_queue_depth" test/nvmf/target/queue_depth.sh "${TEST_ARGS[@]}"
|
||||||
run_test "nvmf_multipath" test/nvmf/target/multipath.sh "${TEST_ARGS[@]}"
|
run_test "nvmf_multipath" test/nvmf/target/multipath.sh "${TEST_ARGS[@]}"
|
||||||
run_test "nvmf_zcopy" test/nvmf/target/zcopy.sh "${TEST_ARGS[@]}"
|
run_test "nvmf_zcopy" test/nvmf/target/zcopy.sh "${TEST_ARGS[@]}"
|
||||||
|
run_test "nvmf_tls" test/nvmf/target/tls.sh "${TEST_ARGS[@]}"
|
||||||
|
|
||||||
timing_enter host
|
timing_enter host
|
||||||
|
|
||||||
|
34
test/nvmf/target/tls.sh
Executable file
34
test/nvmf/target/tls.sh
Executable file
@ -0,0 +1,34 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
testdir=$(readlink -f $(dirname $0))
|
||||||
|
rootdir=$(readlink -f $testdir/../../..)
|
||||||
|
|
||||||
|
source $rootdir/test/common/autotest_common.sh
|
||||||
|
source $rootdir/test/nvmf/common.sh
|
||||||
|
|
||||||
|
rpc_py="$rootdir/scripts/rpc.py"
|
||||||
|
|
||||||
|
nvmftestinit
|
||||||
|
nvmfappstart -m 0x2 --wait-for-rpc
|
||||||
|
|
||||||
|
if [ "$TEST_TRANSPORT" != tcp ]; then
|
||||||
|
echo "Unsupported transport: $TEST_TRANSPORT"
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
|
|
||||||
|
$rpc_py sock_set_default_impl -i ssl
|
||||||
|
$rpc_py framework_start_init
|
||||||
|
$rpc_py nvmf_create_transport $NVMF_TRANSPORT_OPTS
|
||||||
|
$rpc_py nvmf_create_subsystem nqn.2016-06.io.spdk:cnode1 -a -s SPDK00000000000001 -m 10
|
||||||
|
$rpc_py nvmf_subsystem_add_listener nqn.2016-06.io.spdk:cnode1 -t $TEST_TRANSPORT \
|
||||||
|
-a $NVMF_FIRST_TARGET_IP -s $NVMF_PORT
|
||||||
|
$rpc_py bdev_malloc_create 32 4096 -b malloc0
|
||||||
|
$rpc_py nvmf_subsystem_add_ns nqn.2016-06.io.spdk:cnode1 malloc0 -n 1
|
||||||
|
|
||||||
|
# Send IO
|
||||||
|
"${NVMF_TARGET_NS_CMD[@]}" $SPDK_EXAMPLE_DIR/perf -S ssl -q 64 -o 4096 -w randrw -M 30 -t 10 \
|
||||||
|
-r "trtype:${TEST_TRANSPORT} adrfam:IPv4 traddr:${NVMF_FIRST_TARGET_IP} trsvcid:${NVMF_PORT} \
|
||||||
|
subnqn:nqn.2016-06.io.spdk:cnode1"
|
||||||
|
|
||||||
|
trap - SIGINT SIGTERM EXIT
|
||||||
|
nvmftestfini
|
Loading…
Reference in New Issue
Block a user