-
Notifications
You must be signed in to change notification settings - Fork 0
/
full-pingpong.sh
51 lines (49 loc) · 2.23 KB
/
full-pingpong.sh
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
#!/bin/bash
# pingponglist 作成:全ノードの組み合わせ作成
if [ -f ./pingponglist ]; then rm ./pingponglist; fi
for NODE in $(cat ./nodelist.txt); do
for NODE2 in $(cat ./nodelist.txt); do
echo "$NODE,$NODE2" >> pingponglist
done
done
max=$(cat ./pingponglist | wc -l)
count=1
checkosver=$(cat /etc/redhat-release | cut -d " " -f 4)
checkalama=$(cat /etc/redhat-release | cut -d " " -f 1)
if [ $checkalama = "AlmaLinux" ]; then
checkosver=$(cat /etc/redhat-release | cut -d " " -f 3)
fi
## TZ=JST-9 date
echo "========================================================================"
echo -n "$(TZ=JST-9 date '+%Y %b %d %a %H:%M %Z')" && echo " - pingpong #: $max, OS: ${checkosver}"
echo "========================================================================"
# run pingpong
case $checkosver in
7.?.???? )
IMPI_VERSION=2018.4.274
for count in `seq 1 $max`; do
line=$(sed -n ${count}P ./pingponglist)
echo "############### ${line} ###############"; >> result
/opt/intel/impi/${IMPI_VERSION}/intel64/bin/mpirun -hosts $line -ppn 1 -n 2 -env I_MPI_FABRICS=shm:ofa /opt/intel/impi/${IMPI_VERSION}/bin64/IMB-MPI1 pingpong | grep -e ' 512 ' -e NODES -e usec; >> result
done
;;
8.?.???? )
IMPI_VERSION=latest #2021.1.1
source /opt/intel/oneapi/mpi/${IMPI_VERSION}/env/vars.sh
for count in `seq 1 $max`; do
line=$(sed -n ${count}P ./pingponglist)
echo "############### ${line} ###############"; >> result
/opt/intel/oneapi/mpi/${IMPI_VERSION}/bin/mpiexec -hosts $line -ppn 1 -n 2 /opt/intel/oneapi/mpi/${IMPI_VERSION}/bin/IMB-MPI1 pingpong | grep -e ' 512 ' -e NODES -e usec; >> result
done
;;
8.?)
IMPI_VERSION=latest #2021.1.1
source /opt/intel/oneapi/mpi/${IMPI_VERSION}/env/vars.sh
for count in `seq 1 $max`; do
line=$(sed -n ${count}P ./pingponglist)
echo "############### ${line} ###############"; >> result
/opt/intel/oneapi/mpi/${IMPI_VERSION}/bin/mpiexec -hosts $line -ppn 1 -n 2 \
/opt/intel/oneapi/mpi/${IMPI_VERSION}/bin/IMB-MPI1 pingpong | grep -e ' 512 ' -e NODES -e usec; >> result
done
;;
esac