Giter Club home page Giter Club logo

building_julia_on_cray_and_clusters's Introduction

How to build Julia On Cray XC40 supercomputer and computing clusters

Sample scripts to build Julia on Cray and other supercomputing architectures

Since building Julia on Supercomputers is currently not well documented and I spent some time on it, I would like to share my experience on this page.

This is a complimentary material for the workshop presented at SuperComputing Frontiers 2018 conference. I publish it to make your life easier - should you have any questions or comments, please let me know.

I start by explaining how to build Julia on a computing cluster (based on Scientific Linux 6 / Cent OS 6.9) and then move forward to Cray (based on SLES 11).

Building Julia on a computing cluster

This part of the tutorial is based on my experience with ICM's Topola Supercomputer

Julia needs to be built separately for the access node (if needed) and for the workers nodes.

Since the process takes few hours I advise to run screen before the following commands.

Building Julia for the access node

Step 1 Find some directory with enough of free space (at least 4G per julia installation is required)

Step 2 Clone and checkout

git clone https://github.com/JuliaLang/julia.git
cd julia
git checkout v0.6.2

Step 3 Configure the Make.user file

echo "" >> Make.user
echo "USEICC = 0" >> Make.user
echo "USEIFC = 0" >> Make.user
echo "USE_INTEL_MKL = 1" >> Make.user
echo "USE_INTEL_LIBM = 0" >> Make.user
echo "" >> Make.user

Step 4 configure the compilers

module use /icm/hydra/soft/easybuild/modules/all
module load GCC
module load M4
source /apps/compilers/intel/psxe2018u1/compilers_and_libraries_2018.1.163/linux/bin/compilervars.csh intel64
module load /apps/modulefiles/common/python/2.7.9
module load /apps/modulefiles/common/cmake/3.6.2

Step 5 Run make

make

Building Julia for the worker node node

Follow the steps 1-3 frome the previous tutorial

Step 4 Run an interactive session on a worker node

srun --pty --time 24:00:00 --mem=32GB -p topola bash -l

Step 5 Configure the compilers

Note that since we are now running bash , we use different version of Intels's compilervars script

module use /icm/hydra/soft/easybuild/modules/all
module load GCC
module load M4
source /apps/compilers/intel/psxe2018u1/compilers_and_libraries_2018.1.163/linux/bin/compilervars.sh intel64
module load /apps/modulefiles/common/python/2.7.9
module load /apps/modulefiles/common/cmake/3.6.2

Step 6 Run make

make

Building Julia on a Cray XC40 Supercomputer

This tutorial is based on my experience with ICM's Okeanos Cray XC40

Step 1 Clone Julia and checkout

The main problem with building Julia on supercomputers is the outtdated software. Building Julia requires downloading several files from the the internet. In many scenarios you will see errors similiar to this one: error:1407742E:SSL routines:SSL23_GET_SERVER_HELLO:. The solution is to download Julia on some different machine and than compy it to the cluster access node with the scp command. For instructions how to clone see the previous tutorial.

Step 2 Download dependencies

Julia's builder downloads several files from the internet and will not be able to do so on Cray due to old SSL version. Firstly, on the Cray access node go to your julia directory and create deps/srccache/ subfolder, e.g.

cd julia
mkdir deps/srccache/

Now you need some some copy of Julia that you succesfully built on a different machine and run (from a remote machine):

scp julia_source_folder/deps/srccache/* user@hostname:/home/user/julia_target_folder/deps/srccache/

The above command will ignore folders - that is OK you need to only copy archive files.

Step 3 Configure the Make.user file

echo "" >> Make.user
echo "USEICC = 0" >> Make.user
echo "USEIFC = 0" >> Make.user
echo "USE_INTEL_MKL = 1" >> Make.user
echo "USE_INTEL_LIBM = 0" >> Make.user
echo "" >> Make.user

Step 4 configure the compilers

module swap PrgEnv-cray PrgEnv-intel
module load PrgEnv-intel
module load gcc
module load  python/anaconda2.7

Step 5 Install a newer cmake

bash contrib/download_cmake.sh
setenv PATH julia_source_folder/deps/scratch/cmake-3.7.1-Linux-x86_64/bin:$PATH

After setting up cmake try running cmake --version - if you are seeing 3.7.1 you did it correctly.

Step 6 Set the compiler and linker

setenv CC gcc
setenv LD cc

Step 7 Build Julia

To build Julia for worker nodes run:

srun make

To build Julia for an access node run (use a separate copy of the Julia folder):

make

building_julia_on_cray_and_clusters's People

Contributors

pszufe avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.