Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add NSF NCAR example #36

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open

Add NSF NCAR example #36

wants to merge 2 commits into from

Conversation

dphow
Copy link

@dphow dphow commented Feb 25, 2025

Primarily added example for Derecho install at NCAR.

Only other change was setting TMP directory to NCAR scratch (our scratch purges) though the solution might be applied differently for general future users.

I also made the choice to have a central JUHPC_SETUP directory with then the JULIAUP_INSTALLDIR targeting user directories. To be further tested and finalized for our user community soon.

Copy link
Collaborator

@omlins omlins left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for your PR!

@@ -143,7 +143,9 @@ fi

export JULIAUP_BINDIR="$JULIAUP_INSTALLDIR/bin" # juliaup and julia binaries

if [ -d "/dev/shm" ]; then
if [ ! -z "$NCAR_HOST"]; then
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

in order to support your use case, I think it would be better to add a keyword argument --tmp and create internally in the variable JULIAUP_TMP (here:

JUHPC/juhpc

Lines 126 to 139 in ff9247f

# Parse and check the keyword arguments
shift 2
for arg in "$@"; do
case $arg in
--postinstall=*) export JUHPC_POST_INSTALL_JL="${arg#*=}" ;;
--verbose=*) export JUHPC_VERBOSE="${arg#*=}" ;;
*) error "Unknown argument: $arg" ;;
esac
done
if ! [[ "$JUHPC_VERBOSE" =~ ^[0-2]$ ]]; then
error "JUHPC_VERBOSE must be between 0 and 2."
fi
). Then, it can be assigned to TMP if it is set and else do as before.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Only other change was setting TMP directory to NCAR scratch (our scratch purges) though the solution might be applied differently for general future users.

By the way: why do you want to do that? Do you not have /tmp or /dev/shm on your system? Note that this is only used for a temporary installation of julia required to do the setup; the installation will be removed in the end.

@@ -301,7 +303,8 @@ info "... done: wrapper created."
info "Creating activate script..."

export JULIAUP_DEPOT="$JULIAUP_INSTALLDIR/depot"
export JULIA_DEPOT="$JULIAUP_INSTALLDIR/depot"
# Added default $HOME/.julia path for backwards compatibility with exisitng Julia user installs
export JULIA_DEPOT="$JULIAUP_INSTALLDIR/depot:$HOME/.julia"
Copy link
Collaborator

@omlins omlins Mar 5, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not convinced that it is a good idea to mix with user installations. Also, we can have many different JUHPC setups that don't interfere with each other; adding this common depot or would break this great feature.

JULIAUP_INSTALLDIR="/glade/work/\$USER/julia/\$NCAR_HOST/juliaup"
VERSION="v0.3.0"
#wget https://raw.githubusercontent.com/JuliaParallel/JUHPC/$VERSION/juhpc -O ./juhpc
./juhpc $JUHPC_SETUP_INSTALLDIR $JULIAUP_INSTALLDIR --verbose=2 | tee juhpc_install.log
Copy link
Collaborator

@omlins omlins Mar 5, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants