AMGX icon indicating copy to clipboard operation
AMGX copied to clipboard

[Build]Compiling with Pre-Installed OpenMPI

Open kkmund146 opened this issue 1 year ago • 2 comments

I would like to install AMGX on a remote computing cluster. This cluster has OpenMPI 4.1.5 available as a loadable module, but I also have OpenMPI 5.0.3 downloaded as an external package within another program.

I would like to have AMGX use OpenMPI 5.0.3. I have attempted to do this during the configuration phase by using code such as:

<$cmake -DCMAKE_PREFIX_PATH=[path to openmpi5.0.3] ../> <$cmake -DMPI_C_HEADER_DIR=[path to openmpi5.0.3] ../>

However, despite trying these variations, OpenMPI is not seen and I get the output:

Is there a way to point AMGX to my current download/installation of OpenMPI 5.0.3?

kkmund146 avatar Nov 01 '24 02:11 kkmund146

Hi @kkmund146 ,

I think it boils down to how to make CMake to work with your MPI installation. You might try following steps from CMake documentation: https://cmake.org/cmake/help/latest/module/FindMPI.html#variables-for-locating-mpi

marsaev avatar Nov 04 '24 23:11 marsaev

  1. Build OpenMPI with CUDA support for multiple GPUs
  2. Install cmake 3.27 for building AmgX mkdir -p /opt/cmake wget https://github.com/Kitware/CMake/releases/download/v3.27.2/cmake-3.27.2-linux-x86_64.sh sh cmake-3.27.2-linux-x86_64.sh --skip-license --prefix=/opt/cmake echo 'export PATH=/opt/cmake/bin:$PATH' >> /etc/bash.bashrc`

https://blog.nextfoam.co.kr/2024/01/10/gpu-accelerated-openfoam-with-petsc4foam/

bosung-gotocloud avatar Nov 05 '24 02:11 bosung-gotocloud