1
0
mirror of https://github.com/samba-team/samba.git synced 2025-02-04 17:47:26 +03:00

ctdb-tests: Create 20.multipathd.sh

Contains testing support used only by tests for 20.multipathd event
script.

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
This commit is contained in:
Martin Schwenke 2018-03-19 20:40:40 +11:00 committed by Amitay Isaacs
parent e489929335
commit 38b54a60f5
2 changed files with 18 additions and 23 deletions

View File

@ -0,0 +1,18 @@
setup_multipathd ()
{
for i ; do
case "$i" in
\!*)
_t="${i#!}"
echo "Marking ${_t} as having no active paths"
FAKE_MULTIPATH_FAILURES="${FAKE_MULTIPATH_FAILURES}${FAKE_MULTIPATH+FAILURES:+ }${_t}"
;;
*)
_t="$i"
esac
CTDB_MONITOR_MPDEVICES="${CTDB_MONITOR_MPDEVICES}${CTDB_MONITOR_MPDEVICES:+ }${_t}"
done
export CTDB_MONITOR_MPDEVICES FAKE_MULTIPATH_FAILURES
export FAKE_SLEEP_FORCE=0.1
}

View File

@ -935,29 +935,6 @@ setup_httpd ()
######################################################################
# multipathd fakery
setup_multipathd ()
{
for i ; do
case "$i" in
\!*)
_t="${i#!}"
echo "Marking ${_t} as having no active paths"
FAKE_MULTIPATH_FAILURES="${FAKE_MULTIPATH_FAILURES}${FAKE_MULTIPATH+FAILURES:+ }${_t}"
;;
*)
_t="$i"
esac
CTDB_MONITOR_MPDEVICES="${CTDB_MONITOR_MPDEVICES}${CTDB_MONITOR_MPDEVICES:+ }${_t}"
done
export CTDB_MONITOR_MPDEVICES FAKE_MULTIPATH_FAILURES
export FAKE_SLEEP_FORCE=0.1
}
######################################################################
# Result and test functions
# Set some globals and print the summary.