Skip to content

Commit

Permalink
Various updates
Browse files Browse the repository at this point in the history
Fixes up some steps and scripts
  • Loading branch information
scanon committed Nov 15, 2024
1 parent 64f31fd commit 9f5d136
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion _episodes/41.advanced.md
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ and we're going to pull an OpenFoam container, which was built on top of MPICH a
Since this is a large image, we will pull a copy to /tmp for everyone to share.

```bash
(cd /tmp && [ -e sc22-openfoam_v2012.sif ] || singularity pull docker://quay.io/pawsey/sc22-openfoam:v2012)
(cd /tmp && [ -e sc22-openfoam_v2012.sif ] || singularity pull docker://quay.io/pawsey/sc22-openfoam:v2012 && chmod a+r /tmp/sc22-openfoam_v2012.sif)
```

OpenFoam comes with a collection of executables, one of which is `simpleFoam`. We can use the Linux command `ldd` to investigate the libraries that this executable links to. As `simpleFoam` links to a few tens of libraries, let's specifically look for MPI (`libmpi*`) libraries in the command output:
Expand Down
1 change: 0 additions & 1 deletion exercises/openfoam/mpirun_para.sh
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ export SINGULARITY_BINDPATH="$MPICH_ROOT"
export SINGULARITYENV_LD_LIBRARY_PATH="$MPICH_LIBS:\$LD_LIBRARY_PATH"



# pre-processing
singularity exec $image \
blockMesh | tee log.blockMesh
Expand Down
9 changes: 5 additions & 4 deletions exercises/podman-hpc/podman_hpc_setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,15 @@ export PODMANHPC_HOOKS_DIR=/home/training2/.hooks.d
export PODMANHPC_MODULES_DIR=/home/training2/etc/modules.d

[ -e $PODMANHPC_HOOKS_DIR ] || mkdir $PODMANHPC_HOOKS_DIR
HT=$(which hook_tool)
cat << EOF > $PODMANHPC_HOOKS_DIR/02-hook_tool.json
{
"version": "1.0.0",
"hook": {
"env": [
"HOME=/home/$(id -u -n)"
"HOME=${HOME}"
],
"path": "/home/$(id -u -n)/.local/bin/hook_tool",
"path": "${HT}",
"args": ["hook_tool"]
},
"when": {
Expand All @@ -34,9 +35,9 @@ cat << EOF > $PODMANHPC_HOOKS_DIR/02-hook_tool.json
}
EOF

[ -e .local/bin/mksquashfs.static ] || (cd .local/bin && wget https://portal.nersc.gov/project/bigdata/mksquashfs.static)
[ -e ~/.local/bin/mksquashfs.static ] || (cd ~/.local/bin && wget https://portal.nersc.gov/project/bigdata/mksquashfs.static)

chmod a+rx .local/bin/mksquashfs.static
chmod a+rx ~/.local/bin/mksquashfs.static

export SCRATCH=$HOME

Expand Down

0 comments on commit 9f5d136

Please sign in to comment.