3 if [ "$#" -lt "3" ]; then
4 echo "usage: $0 ROUND_TIME PEERS PINGING_PEERS";
5 echo "example: $0 30s 16 1";
13 if [ $PEERS -eq 1 ]; then
14 echo "cannot run 1 peer";
18 LINKS=`echo "l($PEERS) * l($PEERS) * $PEERS" | bc -l`
19 LINKS=`printf "%.0f" $LINKS`
20 NSE=`echo "l($PEERS)/l(10)" | bc -l`
21 echo "using $PEERS peers, $LINKS links";
23 sed -e "s/%LINKS%/$LINKS/;s/%NSE%/$NSE/" profiler.conf > .profiler.conf
25 ./gnunet-mesh-profiler $ROUNDTIME $PEERS $PINGS $4 |& tee log | grep -v DEBUG