blob: 06b8388d0d86e51dd1efd7d3e76a43d71ebd5ca5 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
|
# Hey Emacs, this is a -*- shell-script -*- !!! :-)
#######################################
# Enables all of the event scripts used in cluster tests, except for
# the mandatory scripts
_ctdb_enable_cluster_test_event_scripts()
{
local scripts="
10.interface
49.winbind
50.samba
60.nfs
"
local s
for s in $scripts; do
try_command_on_node all ctdb event script enable legacy "$s"
done
}
setup_ctdb()
{
_ctdb_enable_cluster_test_event_scripts
}
#######################################
_service_ctdb()
{
cmd="$1"
if [ -e /etc/redhat-release ]; then
service ctdb "$cmd"
else
/etc/init.d/ctdb "$cmd"
fi
}
# Stop/start CTDB on all nodes. Override for local daemons.
ctdb_nodes_stop()
{
local nodespec="${1:-all}"
onnode -p "$nodespec" "$CTDB_TEST_WRAPPER" _service_ctdb stop
}
ctdb_nodes_start()
{
local nodespec="${1:-all}"
onnode -p "$nodespec" "$CTDB_TEST_WRAPPER" _service_ctdb start
}
|