OpenSearch 実装用マシンの性能テストを行う
ヤフーオークションで購入した HPE ProLiant XL170r Gen9 で OpenSearch を実装する前段階で性能テストを兼ねて InfiniBand Network Fabric の設定を記録する
1. OS インストール後の基本確認
OS とカーネルの健全性を確認する段階。
cat /etc/os-release
uname -r
2. 開発ツールの導入
MVAPICH2 や OMB をビルドできる環境を整える。
sudo dnf groupinstall -y "Development Tools"
sudo dnf -y install gcc gcc-c++ make
sudo dnf -y install -y rdma-core-devel numactl-devel
3. InfiniBand ドライバの確認(mlx4)
ConnectX‑3(mlx4)ドライバが正しくロードされているか確認。
lsmod | grep mlx4
4. RDMA ユーティリティの導入
Fabric の健全性確認に必要な rdma-core ツール群。
sudo dnf -y install libibverbs-utils
5. InfiniBand / RDMA の状態確認
NIC・ポート・GID・リンク状態を確認する重要ステップ。
ibv_devinfo
ibv_devinfo -v
rdma link
ibstat
6. OpenSM(IS5022 用 Subnet Manager)
IS5022 は SM を内蔵しないため、必須。
※Node2 、Node4 のみ
opensm の導入手順
6-1. パッケージのインストール
sudo dnf -y install opensm
6-2. OpenSM の起動と自動起動設定
sudo systemctl enable --now opensm
6-3. 状態確認
systemctl status opensm
OpenSM 起動後に起きる変化
● ibstat が Active になる
State: Active
Base lid: 1
SM lid: 1
sudo systemctl enable opensm
sudo systemctl start opensm
systemctl status opensm
7. MVAPICH2(RDMA Verbs)ビルド
wget https://mvapich.cse.ohio-state.edu/download/mvapich/mv2/mvapich2-2.3.7-2.tar.gz
tar xvf mvapich2-2.3.7-2.tar.gz
cd mvapich2-2.3.7-2
./configure --prefix=/opt/mvapich2 \
--enable-fortran=no \
--with-device=ch3:mrail \
--with-rdma=gen2 \
--with-verbs
make -j48 ※環境に合わせて 詳細は gmake 参照
sudo make install
echo 'export PATH=/opt/mvapich2/bin:$PATH' >> ~/.bashrc
echo 'export LD_LIBRARY_PATH=/opt/mvapich2/lib:$LD_LIBRARY_PATH' >> ~/.bashrc
cd
9. OSU Micro‑Benchmarks(OMB)のリンク確認
MVAPICH2 に内蔵されている OMB が RDMA verbs でリンクされているか確認。
ldd /opt/mvapich2/libexec/osu-micro-benchmarks/mpi/pt2pt/osu_bw
sudo vim /etc/security/limits.d/99-rdma.conf
centos soft memlock unlimited
centos hard memlock unlimited
ulimit -l
sudo ulimit -l unlimited
reboot(ログアウト)
再ログインして値を確認
ulimit -l
8. RDMA Verbs 用の環境変数設定(.bashrc)
MVAPICH2 の RDMA verbs パスを正しく動作させるための必須設定。
export PATH=/opt/mvapich2/bin:$PATH
export LD_LIBRARY_PATH=/opt/mvapich2/lib:$LD_LIBRARY_PATH
export MV2_USE_RDMA_CM=0
export MV2_USE_IB_HCA=mlx4_0
export MV2_USE_IB_PORT=1
export MV2_DEFAULT_GID_INDEX=0
export MV2_HOMOGENEOUS_CLUSTER=1
export MV2_SUPPRESS_JOB_STARTUP_PERFORMANCE_WARNING=1
10. RDMA Verbs 帯域テスト(osu_bw)
HPE ProLiant XL170r Gen9
テスト構成は以下の上下で実施とし、左右で事前確認と手順書の確認を個別に行う
Node4(192.168.1.64) Node2(192.168.1.62)
read ↑↓ write read ↑↓ write
Node3(192.168.1.63) Node1(192.168.1.61)
063 → 064、064 → 063 の両方向で実行。
11. RDMA 帯域テスト
mpirun -np 2 -hosts cent061,cent062 \
/opt/mvapich2/libexec/osu-micro-benchmarks/mpi/pt2pt/osu_bw
mpirun -np 2 -hosts cent062,cent061 \
/opt/mvapich2/libexec/osu-micro-benchmarks/mpi/pt2pt/osu_bw
mpirun -np 2 -hosts cent063,cent064 \
/opt/mvapich2/libexec/osu-micro-benchmarks/mpi/pt2pt/osu_bw
mpirun -np 2 -hosts cent064,cent063 \
/opt/mvapich2/libexec/osu-micro-benchmarks/mpi/pt2pt/osu_bw
データ転送結果
cent063
[centos@cent063 ~]$ mpirun -np 2 -hosts cent063,cent064 /opt/mvapich2/libexec/osu-micro-benchmarks/mpi/pt2pt/osu_bw
# OSU MPI Bandwidth Test v5.9
# Size Bandwidth (MB/s)
1 4.64
2 9.30
4 18.95
8 37.42
16 73.37
32 141.94
64 313.79
128 610.19
256 1289.30
512 2071.74
1024 2798.59
2048 3352.99
4096 3598.11
8192 3762.49
16384 3844.11
32768 3885.63
65536 3906.86
131072 3935.28
262144 3931.59
524288 3938.88
1048576 3935.52
2097152 3953.72
4194304 3958.26
[centos@cent063 ~]$
cent064
[centos@cent064 ~]$ mpirun -np 2 -hosts cent064,cent063 /opt/mvapich2/libexec/osu-micro-benchmarks/mpi/pt2pt/osu_bw
# OSU MPI Bandwidth Test v5.9
# Size Bandwidth (MB/s)
1 2.69
2 5.41
4 10.80
8 21.49
16 43.19
32 86.84
64 167.12
128 329.53
256 604.66
512 1045.32
1024 1698.04
2048 2369.13
4096 3405.43
8192 3739.52
16384 3817.42
32768 3735.31
65536 3889.67
131072 3907.14
262144 3938.65
524288 3951.86
1048576 3955.75
2097152 3955.77
4194304 3958.42
[centos@cent064 ~]$
以上
参考、関連リンク
ドライバーダウンロードサイト
https://network.nvidia.com/products/adapter-software/ethernet/windows/winof-2/
InfiniBand Network Fabricネットワークの確認
https://docs.oracle.com/cd/G14306_01/amogd/verifying-infiniband-network.html
How to set Mellanox ConnectX VPI to Ethernet or Infiniband in Linux
https://youtu.be/XLPgDEbUMgk?si=HS4KdOzqDlhXoW9r
データフローアクセラレーションとHPCワークロードをターゲットとしたストリーミングコレクティブインターフェース
https://dl.acm.org/doi/full/10.1145/3712285.3759811
オハイオ州立大学
https://mvapich.cse.ohio-state.edu/
MVAPICH2
https://mvapich.cse.ohio-state.edu/downloads/
クイックスタートガイド PDF
https://mvapich-docs.readthedocs.io/_/downloads/en/mvapich-plus/pdf/
ユーザーズガイド
https://mvapich.cse.ohio-state.edu/userguide/
筑波大学 GPU-Aware MPI with ROCm
https://www.ccs.tsukuba.ac.jp/wp-content/uploads/sites/14/2025/09/11.-GPU-Aware_MPI.pdf
nVidia 公式
https://forums.developer.nvidia.com/t/can-i-use-mvapich-with-cuda-fortran/276710
NVIDIA ネットワーキング: ConnectX ネットワーク インターフェイス カードの概要
https://youtu.be/xXXrX1CcuBw?si=R57cyjZFq8li8oHA
