Fix runner

This commit is contained in:
Quentin 2019-09-05 10:06:14 +02:00
parent 40a3b4f68a
commit 75a9823fd6
2 changed files with 29 additions and 11 deletions

View file

@ -1,6 +1,6 @@
tor_bw_small:
./run-3 \
1 . \
1,tor_bw_small . \
orig-client 60 1000 100, orig-client 600 100 100, orig-client 6000 10 100, orig-client 60000 1 100 . \
orig-server, orig-server, orig-server, orig-server . \
tor3 -f /etc/torrc_simple, tor3 -f /etc/torrc_simple, tor3 -f /etc/torrc_simple, tor3 -f /etc/torrc_simple . \
@ -8,7 +8,7 @@ tor_bw_small:
tor_bw_full:
./run-3 \
10 . \
10,tor_bw_full . \
orig-client 600 1000 100, orig-client 6000 100 100, orig-client 60000 10 100, orig-client 600000 1 100 . \
orig-server, orig-server, orig-server, orig-server . \
tor3 -f /etc/torrc_simple, tor3 -f /etc/torrc_simple, tor3 -f /etc/torrc_simple, tor3 -f /etc/torrc_simple . \
@ -16,7 +16,7 @@ tor_bw_full:
tor_guards_small:
./run-3 \
1 . \
1,tor_guards_small . \
dup2-client 600 100 100 8, \
dup2-client 600 100 100 8, \
dup2-client 600 100 100 8, \
@ -36,7 +36,7 @@ tor_guards_small:
tor_guards_full:
./run-3 \
16 . \
16,tor_guards_full . \
dup2-client 6000 100 100 8, \
dup2-client 6000 100 100 8, \
dup2-client 6000 100 100 8, \
@ -74,9 +74,25 @@ tor_guards_full:
tor3 -f /etc/torrc_guard_8, \
tor3 -f /etc/torrc_simple
tor_relays_full:
./run-3 \
16,tor_relays_full . \
orig-client 6000 100 100, \
orig-client 6000 100 100, \
orig-client 6000 100 100 . \
orig-server, \
orig-server, \
orig-server-single . \
tor3 -f /etc/torrc_simple, \
tor2 -f /etc/torrc_simple, \
tor2 -f /etc/torrc_simple . \
tor3 -f /etc/torrc_simple, \
tor2 -f /etc/torrc_simple, \
tor2 -f /etc/torrc_single_hop
tor_relays_small:
./run-3 \
1 . \
1,tor_relays_small . \
orig-client 600 100 100, \
orig-client 600 100 100, \
orig-client 600 100 100 . \

View file

@ -28,9 +28,10 @@ IFS=$OLD_IFS
|| die "Same number of declaration is required. Got ${#CLIENT_TARGETS[@]} clients, ${#SERVER_TARGETS[@]} servers, ${#TOR_DAEMON_CLIENT[@]} Tor daemon clients and ${#TOR_DAEMON_SERVER[@]} Tor daemon servers"
instances=${#CLIENT_TARGETS[@]}
REPEAT=${CONFIG[0]}
IDENTIFIER=${CONFIG[1]}
echo ":: Configuration Summary"
echo "repeat=$REPEAT"
echo "repeat=$REPEAT, identifier=$IDENTIFIER"
for i in $(seq 0 $(expr $instances - 1)); do
echo " instance=$i - server=${SERVER_TARGETS[$i]} - client=${CLIENT_TARGETS[$i]} - tor server=${TOR_DAEMON_SERVER[$i]} - tor client=${TOR_DAEMON_CLIENT[$i]}"
done
@ -47,7 +48,7 @@ echo "Create output folder..."
docker run \
--rm \
--user root \
-v `pwd`/out:/home/donar \
-v `pwd`/out:/home/donar/out \
registry.gitlab.inria.fr/qdufour/donar \
chown -R 1000:1000 /home/donar
@ -58,7 +59,7 @@ docker run \
-d \
--name "donarxp_server_${i}" \
-e HOME='/tmp' \
-v `pwd`/out:/home/donar \
-v `pwd`/out:/home/donar/out \
registry.gitlab.inria.fr/qdufour/donar \
${TOR_DAEMON_SERVER[$i]}
@ -67,7 +68,7 @@ docker run \
-d \
--name "donarxp_client_${i}" \
-e HOME='/tmp' \
-v `pwd`/out:/home/donar \
-v `pwd`/out:/home/donar/out \
registry.gitlab.inria.fr/qdufour/donar \
${TOR_DAEMON_CLIENT[$i]}
@ -77,11 +78,12 @@ sleep 10
echo ":: Start experiment..."
for j in $(seq 1 $REPEAT); do
run_fold=`mktemp -up . XXXXXXXXXXXXXXXX`
echo "start - batch_count=$j - id=$run_fold"
run_fold=`mktemp -up ./out XXXXXXXXXXXXXXXX`
echo "start - batch_count=$j - folder=$run_fold"
echo " reset containers"
for i in $(seq 0 $(expr $instances - 1)); do
docker exec donarxp_client_${i} sh -c "mkdir -p $run_fold-$i; echo repeat=$REPEAT,identifier=$IDENTIFIER > $run_fold-$i/info.txt"
docker exec donarxp_client_${i} sh -c 'killall --quiet -9 bash; killall --quiet -9 donar; killall --quiet -9 measlat; killall --quiet -9 udpecho; killall --quiet -9 torecho'
docker exec donarxp_server_${i} sh -c 'killall --quiet -9 bash; killall --quiet -9 donar; killall --quiet -9 measlat; killall --quiet -9 udpecho; killall --quiet -9 torecho'
done