You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
38 lines
1.2 KiB
38 lines
1.2 KiB
#!/bin/bash
|
|
|
|
function usage {
|
|
echo "$0 [concurrency] [fib number]"
|
|
exit 1
|
|
}
|
|
|
|
if [ $# != 2 ] ; then
|
|
usage
|
|
exit 1;
|
|
fi
|
|
|
|
#cores_list=(1 2 4 10 20 40 50 60 77)
|
|
#cores_list=(50 60)
|
|
#cores_list=(1 2 4 6 8 10 20 30 40 50 60 70 77)
|
|
concurrency=$1
|
|
fib_num=$2
|
|
|
|
echo "fib num is $fib_num"
|
|
cores_list=(1 2 4 6 8 10 12 14 16 18 20 24 28 32 36 40 44 48 52 56 60 64 68 72 77)
|
|
#cores_list=(1)
|
|
ulimit -n 655350
|
|
./kill_sledge.sh
|
|
for(( i=0;i<${#cores_list[@]};i++ )) do
|
|
hey_log=${cores_list[i]}"-$fib_num-$concurrency.log" #8-38-100
|
|
server_log="server-"${cores_list[i]}"-$fib_num-$concurrency.log"
|
|
#./start.sh ${cores_list[i]} >/dev/null 2>&1 &
|
|
./start.sh ${cores_list[i]} > $server_log 2>&1 &
|
|
echo "sledge start with worker core ${cores_list[i]}"
|
|
taskset --cpu-list 80-159 hey -disable-compression -disable-keepalive -disable-redirects -z "60"s -c "$concurrency" -m POST -d "$fib_num" "http://127.0.0.1:10030/fib" > $hey_log
|
|
#taskset --cpu-list 80-159 hey -disable-compression -disable-keepalive -disable-redirects -z "60"s -c "$concurrency" "http://127.0.0.1:10030/fib" > $hey_log
|
|
./kill_sledge.sh
|
|
done
|
|
|
|
folder_name="$fib_num""_c$concurrency"
|
|
mkdir $folder_name
|
|
mv *.log $folder_name
|