diff --git a/rank-swapper-agent/Makefile b/rank-swapper-agent/Makefile index 7aefe6ec5f0320ff57f1066ca4fe63c46a9ddcaa..b5d328f88804b5ba50384c1809d77bf67fc51826 100644 --- a/rank-swapper-agent/Makefile +++ b/rank-swapper-agent/Makefile @@ -1,4 +1,4 @@ -export OMPI := /<path-to-my-openmpi-installation>/openmpi-install +export OMPI := /home/openmpi-install export PATH := $(PATH):$(OMPI)/bin export LD_LIBRARY_PATH := $(LD_LIBRARY_PATH):$(OMPI)/bin # requirement: GNU make, see https://unix.stackexchange.com/questions/11530/adding-directory-to-path-through-makefile/261844#261844 diff --git a/rank-swapper-agent/client.sh b/rank-swapper-agent/client.sh index cb1d85889e5ee0f9657cf4452d3b32ee04aa9eef..50f1a093fcef685c236547f4fcbbe06971a31f17 100755 --- a/rank-swapper-agent/client.sh +++ b/rank-swapper-agent/client.sh @@ -1,14 +1,16 @@ #!/bin/bash -export OMPI=/<path-to-my-openmpi-installation>/openmpi-install +export OMPI=/home/openmpi-install export PATH=$PATH:$OMPI/bin export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$OMPI/bin PROCESSES=1 HOSTFILE="--hostfile hostfile.txt" +# makes the usage of hardware-threads instead of just cores possible ENABLE_HYPERTHREADING="--bind-to hwthread" ALLOW_OVERLOAD="--bind-to core:overload-allowed" ENABLE_OVERSUBSCRIBE="--map-by :OVERSUBSCRIBE" -# --bind-to hwthread: makes the usage of threads instead of just cores possible -mpirun --np $PROCESSES $ALLOW_OVERLOAD $ENABLE_OVERSUBSCRIBE $HOSTFILE hello +#FIXME run as root is necessary for running it inside docker but it should be disabled for production! +ALLOW_RUN_AS_ROOT="--allow-run-as-root" +mpirun --np $PROCESSES $ALLOW_OVERLOAD $ENABLE_OVERSUBSCRIBE $HOSTFILE $ALLOW_RUN_AS_ROOT hello diff --git a/rank-swapper-agent/hello_c.c b/rank-swapper-agent/hello_c.c index d8b3e6111762a2a5f8010d7eda71b1b6c37faddc..4693db3eb76df6b9ac72db49269c4998f9b2646a 100644 --- a/rank-swapper-agent/hello_c.c +++ b/rank-swapper-agent/hello_c.c @@ -15,7 +15,7 @@ #include "mpi.h" -#define SOCKET_PATH "/home/beach/Dokumente/Uni/Informatik_BA/Bachelorarbeit_MPI/sockets_mpi_test/socket" +#define SOCKET_PATH "/home/ompi/openmpi-rank-swapper-agent/socket" #define BUFFLEN 64 /* Spawn Modes (dynamic job spawning): diff --git a/rank-swapper-agent/locserv.c b/rank-swapper-agent/locserv.c index 828ae8e66770e6e0ae51300adc1c7b903303a601..1628c9e213ff8989e5ddfff0d4579ce0a4720a93 100644 --- a/rank-swapper-agent/locserv.c +++ b/rank-swapper-agent/locserv.c @@ -23,7 +23,7 @@ #include <time.h> #include <unistd.h> -#define SOCKET_PATH "/home/beach/Dokumente/Uni/Informatik_BA/Bachelorarbeit_MPI/sockets_mpi_test/socket" +#define SOCKET_PATH "/home/ompi/openmpi-rank-swapper-agent/socket" #define MAX_CONNECTIONS 10 #define RANK_STR_LEN 8 #define BUFFLEN 64