diff --git a/test/iscsi_tgt/trace_record/trace_record.sh b/test/iscsi_tgt/trace_record/trace_record.sh index ef18fcc188..a3ca257380 100755 --- a/test/iscsi_tgt/trace_record/trace_record.sh +++ b/test/iscsi_tgt/trace_record/trace_record.sh @@ -52,6 +52,11 @@ echo "iscsi_tgt is listening. Running tests..." timing_exit start_iscsi_tgt +mkdir -p ${TRACE_TMP_FOLDER} +./app/trace_record/spdk_trace_record -s iscsi -p ${iscsi_pid} -f ${TRACE_RECORD_OUTPUT} -q 1>${TRACE_RECORD_NOTICE_LOG} & +record_pid=$! +echo "Trace record pid: $record_pid" + RPCS= RPCS+="add_portal_group $PORTAL_TAG $TARGET_IP:$ISCSI_PORT\n" RPCS+="add_initiator_group $INITIATOR_TAG $INITIATOR_NAME $NETMASK\n" @@ -70,11 +75,6 @@ iscsiadm -m discovery -t sendtargets -p $TARGET_IP:$ISCSI_PORT iscsiadm -m node --login -p $TARGET_IP:$ISCSI_PORT waitforiscsidevices $(( $CONNECTION_NUMBER + 1 )) -mkdir -p ${TRACE_TMP_FOLDER} -./app/trace_record/spdk_trace_record -s iscsi -p ${iscsi_pid} -f ${TRACE_RECORD_OUTPUT} -q 1>${TRACE_RECORD_NOTICE_LOG} & -record_pid=$! -echo "Trace record pid: $record_pid" - trap 'iscsicleanup; killprocess $iscsi_pid; killprocess $record_pid; delete_tmp_files; iscsitestfini $1 $2; exit 1' SIGINT SIGTERM EXIT echo "Running FIO"