Small tools for users of Lumi
Shared settings are in settings.sh
Here you can set the timeouts, toggle if ssh to compute nodes is enabled
and change the name of the supercomputer.
Minimal ssh server + client using dropbear to use on compute nodes. Use only for debugging.
Just copy/move the SSH folder to where you want to have it installed
run setup.sh and add the bin folder to your path
start-ssh-server will launch the server and
job-ssh <jobid> <node> [optinal commands] will then allow you to ssh to the node
To avoid clutter in $HOME all keys are generated per job basis under the installation directory.
dump.mp4
A much more light weight alternative is to just use dropbear directly:
Starting the server
mkdir -p /tmp/$USER && dropbearkey -t ed25519 -f /tmp/$USER/drop_id && dropbear -F -m -p 4040 -E -r /tmp/$USER/drop_id
Generting connection keys (only one time needed)
dropbearkey -t ed25519 -f $HOME/.ssh/drop_ssh_key | grep "^ssh-ed25519" >> $HOME/.ssh/authorized_keys
Connecting
dbclient -i $HOME/.ssh/drop_ssh_key -p 4040 nid005032
Will start a juptyer notebook and print connection information so that users can forward a port to Lumi and then connect to the notebook in their local browser.
Scripts for starting a minimal vnc server + novnc proxy
_start_vncmain script responsible for starting the VNC and proxy_get_vnc_displayruns the main script in the background and setsDISPLAY+some utility functions. The utility function arestop-vncstops the vnc, resetsDISPLAYand removes and related functionsvnc-statusreturns 0 if the vnc is runningvnc-infoPrints the connection information for the vnc
_get_vnc_display has to be sourced so that the variables and utility
function can be set in the current shell. This can be achieved by:
source /path/to/_get_vnc_displayalias start-vnc="source /path/to/_get_vnc_display"function start-vnc { source /path/to/_get_vnc_display "$@" ;} && export -f start-vnc
Aliases are not exported to subshells + shopt -s expand_aliases does not help
us with sbatch scripts. So the alias needs to be set in the job file (e.g by loading a module)
and can not be inherited from the submission environment.
Note, the vnc script does not start any program so connecting
works but only a gray screen is shown before some programs are started
The base container includes xterm which can be used as a sanity check
As the vnc is sourced a job will end after the last command is done If for some reason this is not wanted and extra wait has to be added to the end of the script