Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/container-changes' into containe…
Browse files Browse the repository at this point in the history
…r-changes

# Conflicts:
#	compss/runtime/adaptors/execution/src/main/java/es/bsc/compss/invokers/binary/MPIInvoker.java
  • Loading branch information
nihadness committed Jul 18, 2023
2 parents df2ec6e + caca172 commit 65130fc
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -534,7 +534,8 @@ public Object executeCMD(String[] cmd, StdIOStream stdIOStreamValues, ExecutionS
int maxNumProcsPerNode = hostnames2numThreads.entrySet().stream()
.max((entry1, entry2) -> entry1.getValue() > entry2.getValue() ? 1 : -1).get().getValue();

maxNumProcsPerNode *= theoreticalNumProcs;
// todo: nm: make sure mpmd doesn't fail
maxNumProcsPerNode *= theoreticalNumProcs / theoreticalNumProcs;
// Re-set COMPSs properties
// We do not reset COMPSs properties because it does not have to match SLURM
// System.setProperty(Invoker.COMPSS_NUM_NODES, String.valueOf(uniqueNumNodes));
Expand Down
9 changes: 7 additions & 2 deletions compss/runtime/scripts/utils/mpi_run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,19 @@
echo "Running mpi_run.sh"
echo "$ENV_LOAD_MODULES_SCRIPT"
WORKING_DIR=$PWD
env | grep "SLURM_" | sed 's/SLURM/export SLURM/g' | sed 's/=/="/g' | sed -e 's/$/"/' > $COMPSS_MASTER_WORKING_DIR/slurm_vars

echo "mpi_run.sh Working Dir: $WORKING_DIR"

env | grep "SLURM_" | sed 's/SLURM/export SLURM/g' | sed 's/=/="/g' | sed -e 's/$/"/' > ${WORKING_DIR}/slurm_vars

env | grep "SLURM_" | sed 's/SLURM/export SINGULARITYENV_/g' | sed 's/=/="/g' | sed -e 's/$/"/' >> $WORKING_DIR/slurm_vars

env


ssh -o StrictHostKeyChecking=no $(hostname) /bin/bash <<EOF
source $COMPSS_MASTER_WORKING_DIR/slurm_vars
source ${WORKING_DIR}/slurm_vars
cd $WORKING_DIR
export COMPSS_MPIRUN_TYPE=$COMPSS_MPIRUN_TYPE
Expand Down

0 comments on commit 65130fc

Please sign in to comment.