Epica (hosted by EAPS)
Table of Contents
- Getting an account
- ssh configuration
- Password-less ssh
- Environment
- Installing ISSM on Epica
- Installing ISSM with CoDiPack (AD)
Getting an account
Send an email to Ed and request an account (make sure to ask him to add you to the issm group).
Epica has several drives. Your home directory is on a small drive, and /data1 is for backups only. Make sure to install ISSM in /data2:
cd /data2/issm/
mkdir YOURUSERNAME
and replace YOURUSERNAME by your username. This is where you should checkout ISSM and do your work.
ssh configuration
You can add the following lines to ~/.ssh/config on your local machine:
Host epica epica.dartmouth.edu
HostName epica.dartmouth.edu
User YOURUSERNAME
and replace YOURUSERNAME by your Epica username. Once this is done, you can ssh epica by simply doing:
ssh epica
Password-less ssh
You can setup a public key authentication in order to avoid having to input your password all the time you log onto Epica. You need an SSH public/private key pair on your local machine. If you do not have one, you can create one by executing the following command on your local machine (no passphrase necessary; press Enter at each prompt to accept the defaults):
your_localhost$ ssh-keygen -t rsa
Generating public/private rsa key pair.
Enter file in which to save the key (/Users/username/.ssh/id_rsa):
Enter passphrase (empty for no passphrase):
Enter same passphrase again:
Your identification has been saved in /Users/username/.ssh/id_rsa.
Your public key has been saved in /Users/username/.ssh/id_rsa.pub.
Two files are created:
- your private key
/Users/username/.ssh/id_rsa, and - the public key
/Users/username/.ssh/id_rsa.pub.
The private key must be kept private and never shared — keep its file permissions restricted (600). The contents of the public key need to be copied to ~/.ssh/authorized_keys on the remote machine:
your_localhost$ scp ~/.ssh/id_rsa.pub username@your_remotehost:~
Now, log onto Epica and add the content of id_rsa.pub to ~/.ssh/authorized_keys:
your_remotehost$ cat ~/id_rsa.pub >> ~/.ssh/authorized_keys
your_remotehost$ rm ~/id_rsa.pub
If you get an error message about /home/username/.ssh/authorized_keys: No such file or directory, you may need to create a .ssh directory first:
your_remotehost$ mkdir ~/.ssh
your_remotehost$ chmod 700 ~/.ssh
Environment
On Epica, add the following lines to ~/.bashrc:
export ISSM_DIR=PATHTODIR
source $ISSM_DIR/etc/environment.sh
#MATLAB alias
export LD_PRELOAD="/usr/lib/x86_64-linux-gnu/libstdc++.so.6"
alias ma='matlab -nodesktop -nosplash -r "addpath $ISSM_DIR/src/m/dev; devpath;"'
Use:
source ~/.bashrc
or Log out and log back in to apply this change.
Installing ISSM on Epica
You can clone ISSM and install the following packages:
- autotools
- PETSc 3.25 or later
- triangle
Use the following configuration script (adapt to your needs):
./configure \
--prefix=$ISSM_DIR \
--with-matlab-dir="/usr/local/MATLAB/R2026a" \
--with-triangle-dir="$ISSM_DIR/externalpackages/triangle/install" \
--with-metis-dir="$ISSM_DIR/externalpackages/petsc/install" \
--with-petsc-dir="$ISSM_DIR/externalpackages/petsc/install" \
--with-mpi-include="$ISSM_DIR/externalpackages/petsc/install/include" \
--with-mpi-libflags="-L$ISSM_DIR/externalpackages/petsc/install/lib -lmpi -lmpicxx -lmpifort"\
--with-blas-lapack-dir="$ISSM_DIR/externalpackages/petsc/install" \
--with-scalapack-dir="$ISSM_DIR/externalpackages/petsc/install/" \
--with-mumps-dir="$ISSM_DIR/externalpackages/petsc/install/" \
--with-numthreads=10 \
--enable-development \
--enable-debugging
and to avoid conflicts with MATLAB’s own dynamic libraries, use the following alias:
alias ma='LD_PRELOAD=/lib/x86_64-linux-gnu/libstdc++.so.6 matlab -nodesktop -nosplash -r "addpath $ISSM_DIR/src/m/dev; devpath;"'
Installing ISSM with CoDiPack (AD)
You will need to install the following additional packages in the following order:
- codipack
- medipack
- adjointpetsc (use the generic script,
install.sh)
Use the following configuration script:
TBD