Skip to content

Commit

Permalink
Fix docker MPI issues? (#185) (#207)
Browse files Browse the repository at this point in the history
* Fix docker MPI issues due to lack of SYS_PTRACE permissions (disable Vader) (Closes #185)

* Disable Infiniband for OpenMPI

* enable tcp via loopback

* Set RelWithDebInfo as default build type
  • Loading branch information
dweindl authored Dec 2, 2019
1 parent 45cc0e5 commit 11af0f0
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 3 deletions.
2 changes: 1 addition & 1 deletion CMakeModules/BuildType.cmake
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Set a default build type if none was specified.
# If inside git repository build debug, otherwise release.
set(default_build_type "Release")
set(default_build_type "RelWithDebInfo")
if(EXISTS "${CMAKE_SOURCE_DIR}/.git")
set(default_build_type "Debug")
endif()
Expand Down
2 changes: 1 addition & 1 deletion container/charliecloud/parpe_base/install_parpe.sh
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ CC=mpicc CXX=mpiCC cmake \
-DCERES_INCLUDE_DIRS="/usr/include/;/usr/include/eigen3" \
-DMPI_INCLUDE_DIRS=/usr/include/openmpi-x86_64/ \
-DBUILD_TESTS=ON \
"-DTESTS_MPIEXEC_COMMAND=mpiexec;--allow-run-as-root;-n;4;--oversubscribe" \
"-DTESTS_MPIEXEC_COMMAND=mpiexec;--allow-run-as-root;-n;4;--oversubscribe;--mca;btl_vader_single_copy_mechanism;none;--mca;btl;^openib;--mca;oob_tcp_if_include;lo;--mca;btl_tcp_if_include;lo;--mca;orte_base_help_aggregate;0" \
..
make -j12 VERBOSE=1

Expand Down
4 changes: 4 additions & 0 deletions examples/parpeamici/steadystate/run-examples.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,10 @@ HDF5_FILE_TEST=$2
MPIEXEC="mpiexec --oversubscribe -n 5"
# Allow running as root in docker
grep docker /proc/1/cgroup -qa && MPIEXEC="${MPIEXEC} --allow-run-as-root"
# If we are running in docker, we generally don't have SYS_PTRACE permissions
# and thus, cannot use vader. Also disable Infiniband.
grep docker /proc/1/cgroup -qa && mpiexec --version | grep open-mpi && MPIEXEC="${MPIEXEC} --oversubscribe --mca btl_vader_single_copy_mechanism none --mca btl ^openib -mca oob_tcp_if_include lo --mca btl_tcp_if_include lo --mca orte_base_help_aggregate 0"


rm -f test.log

Expand Down
2 changes: 1 addition & 1 deletion shippable.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ build:
- CTEST_OUTPUT_ON_FAILURE=1 make ExperimentalMemCheck; cat Testing/Temporary/MemoryChecker.*.log

# coverage report
- cd $PARPE_BASE/build && make parpe_coverage_cobertura
- cd $PARPE_BASE/build && CTEST_OUTPUT_ON_FAILURE=1 make parpe_coverage_cobertura
- mkdir -p $PARPE_BASE/shippable/codecoverage && cp $PARPE_BASE/build/parpe_coverage_cobertura.xml $PARPE_BASE/shippable/codecoverage

# on_failure:
Expand Down

0 comments on commit 11af0f0

Please sign in to comment.