Change-Id: I232eff9099bd6c39206004c72783bfd25d1b9f26 Signed-off-by: chenlo2x <longx.o.chen@intel.com> Reviewed-on: https://review.gerrithub.io/398554 Tested-by: SPDK Automated Test System <sys_sgsw@intel.com> Reviewed-by: Jim Harris <james.r.harris@intel.com> Reviewed-by: Daniel Verkamp <daniel.verkamp@intel.com> Reviewed-by: <shuhei.matsumoto.xt@hitachi.com>
23 lines
333 B
Bash
Executable File
23 lines
333 B
Bash
Executable File
#!/usr/bin/env bash
|
|
|
|
set -xe
|
|
|
|
pid="$1"
|
|
|
|
if [[ -z "$pid" ]]; then
|
|
echo "usage: $0 pid"
|
|
exit 1
|
|
fi
|
|
|
|
# delete any existing temporary iscsi.conf files
|
|
rm -f /tmp/iscsi.conf*
|
|
|
|
kill -USR1 "$pid"
|
|
|
|
if [ ! -f `ls /tmp/iscsi.conf.*` ]; then
|
|
echo "iscsi_tgt did not generate config file"
|
|
exit 1
|
|
fi
|
|
|
|
mv `ls /tmp/iscsi.conf.*` /tmp/iscsi.conf
|