Debian Codegraph @

ctdb/tests/etc-ctdb/events/legacy/00.test.script

raw
1 #!/bin/sh
2 # event script for 'make test'
3
4 . "${CTDB_BASE}/functions"
5
6 load_script_options
7
8 ctdb_check_args "$@"
9
10 event="$1"
11 shift
12
13 case "$event" in
14 monitor)
15 if [ "$CTDB_RUN_TIMEOUT_MONITOR" = "yes" ] ; then
16 timeout=9999
17 echo "Sleeping for ${timeout} seconds..."
18 sleep $timeout
19 fi
20 ;;
21
22 startup)
23 ifaces=$(ctdb ifaces -X | tail -n +2 | cut -d '|' -f2)
24 for i in $ifaces; do
25 ctdb setifacelink "$i" up
26 done
27 ;;
28 esac
29
30 echo "${event} event${*:+ for }$*"