From d72f6581a8d34935afe7ed94d687e3be1e8fb730 Mon Sep 17 00:00:00 2001 From: Trupesh Patel Date: Thu, 23 May 2024 16:08:15 -0500 Subject: [PATCH] Fixed ulimit and added missing *.TBL fils --- singularity/templates/extern/install_extern_libraries.sh | 6 ++++-- singularity/templates/guide/HelloNGEN.sh | 9 +++++++++ 2 files changed, 13 insertions(+), 2 deletions(-) diff --git a/singularity/templates/extern/install_extern_libraries.sh b/singularity/templates/extern/install_extern_libraries.sh index c4ff296..2377a36 100644 --- a/singularity/templates/extern/install_extern_libraries.sh +++ b/singularity/templates/extern/install_extern_libraries.sh @@ -27,7 +27,7 @@ echo "-- Now Installing External Library noah-owp-modular ..." echo "-----------------------------------------------------------" cd /ngen/extern/noah-owp-modular # cmake -B cmake_build -S . -cmake -DnetCDF_MOD_PATH=/usr/include/openmpi-x86_64/ -B cmake_build -S . +cmake -DNETCDF_MODULE_DIR=/usr/lib64/gfortran/modules/openmpi/ -B cmake_build -S . cmake --build cmake_build --target surfacebmi -- -j 2 echo "===========================================================" @@ -87,7 +87,9 @@ cp /tmp/guide/HelloNGEN.sh /ngen/HelloNGEN.sh chown -R root /dmod /ngen /root chmod a+x /dmod/bin/* /ngen/HelloNGEN.sh /root find /ngen/extern/ -name "*.so*" -exec ln -s "{}" /dmod/shared_libs/ \; - +find /ngen/extern/noah-owp-modular -type f -iname "*.TBL" -exec cp '{}' /dmod/datasets/static \; ls -ahl /dmod/shared_libs echo "===========================================================" +ls -ahl /dmod/datasets/static +echo "===========================================================" echo "===========================================================" \ No newline at end of file diff --git a/singularity/templates/guide/HelloNGEN.sh b/singularity/templates/guide/HelloNGEN.sh index 46a1cf6..1a3dae7 100644 --- a/singularity/templates/guide/HelloNGEN.sh +++ b/singularity/templates/guide/HelloNGEN.sh @@ -8,6 +8,15 @@ MAGENTA='\e[35m' CYAN='\e[36m' RESET='\e[0m' +# Increasing `ulimit` to Open files +ulimit -n 500000 + +# Loading Lmod +source /etc/profile.d/modules.sh + +# Loading OpenMPI module for Parallel Run +module load mpi + workdir="${1:-/ngen}" cd "${workdir}" || { echo -e "${RED}Failed to change directory to ${workdir}${RESET}"; exit 1; } set -e