summaryrefslogtreecommitdiff
path: root/source4/cluster/ctdb/tests/fetch.sh
blob: 325957e63f786d7aa9b950181a9bfda5ff9063c4 (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
#!/bin/sh

NUMNODES=2
if [ $# -gt 0 ]; then
    NUMNODES=$1
fi

rm -f nodes.txt
for i in `seq 1 $NUMNODES`; do
  echo 127.0.0.$i >> nodes.txt
done

tests/start_daemons.sh $NUMNODES nodes.txt || exit 1


killall -9 -q ctdb_fetch
for i in `seq 1 $NUMNODES`; do
  $VALGRIND bin/ctdb_fetch --socket sock.$i -n $NUMNODES $* &
done
wait

echo "Shutting down"
bin/ctdb shutdown -n all --socket=sock.1
exit 0