Wiki

Clone wiki

jCODE-public / Intel

Intel

For your own workstation/laptop or on a cluster, it is recommended to install the libraries in your own personal directory

/home/<username>/opt/<name of the library>

Architecture

The following assumes you are installing everything on a 64-bit Linux station with the Intel compilers. If you are not, some parameters might be different.

Intel Compilers

The CFD package is compatible with several suites of compilers and architectures. For your own workstation, we recommend using the Intel compilers. If you haven't installed the compilers yet, here is what to do.

  • Before installing the Intel compilers, make sure you have the following programs installed

gcc
gcc-c++
gfortran

If they are not available, install them.

  • Download the compilers from the Intel website. Download both the C++ and the Fortran compilers. Choose the Intel 64 version.
  • Un-tar the zipped files
tar -zxvf l_cproc_p_...
tar -zxvf l_cprof_p_...
  • For both compilers, go in the corresponding directory and run the install program.

./install.sh

  • When asked for, use the serial number found in the email you received.
  • Choose a Custom Install. In the custom install, choose all default option except for the directory where to install the compilers. Instead, use

/home/<username>/opt/intel/

  • Follow the instructions and you are done.

Known problem. If the install program complains about 32 bit libraries, follow this procedure instead.

  • Quit the install program
  • Create a file named input and type the following in it
ACTIVATION=exist_lic
CONTINUE_WITH_INSTALLDIR_OVERWRITE=yes
CONTINUE_WITH_OPTIONAL_ERROR=yes
PSET_INSTALL_DIR=/opt/intel/
INSTALL_MODE=RPM
ACCEPT_EULA=accept

Run the following command

./install.sh --silent input

If for some reason that still does not work, explicitly follow the instructions found here, and you should be able to install the compilers.

Finalizing and testing Last thing to do is to add the following line to your _.bashrc_ file in your home directories (two directories: one as *root* and one as a *user*)

source /home/<username>/opt/intel/bin/intel64/iccvars_intel64.sh

Quit your terminal, open a new one, and type

icc -V
ifort -V

Should you get the following messages (or similar) for each compiler, everything has been installed properly

Intel(R) C Intel(R) 64 Compiler Professional for applications running on Intel(R) 64, Version 11.1 
Copyright (C) 1985-2010 Intel Corporation.  All rights reserved.
FOR NON-COMMERCIAL USE ONLY

MPICH

Download the file mpich2-1.2.1p1.tar.gz (or some equivalent), unpack it, and go into the new folder. Installing MPICH involves four steps:

  • defining the compilers and the optimization flags
export CC=icc
export CXX=icpc
export F77=ifort
export CFLAGS="-O3 -xHOST -ip"
export CXXFLAGS="-O3 -xHOST -ip"
export FFLAGS="-O3 -xHOST -ip"
  • testing and configuring the system

./configure --prefix=/home/<username>/opt/mpich2 --with-device=ch3:shm --with-pm=gforker

  • if using openmpi

./configure CC=icc CXX=icpc F77=ifort FC=ifort --prefix=/home/<username>/opt/openmpi-1.4.3/

  • compiling the libraries

make

  • installing the libraries
bash
bash ~/.bashrc
source  /home/<username>/opt/intel/bin/intel64/iccvars_intel64.sh
make install

To make sure that the MPI compilers/libraries were created properly, look in the directory where you installed MPICH. In the bin subdirectory, you should find

  • mpicc
  • mpicxx
  • mpif77
  • mpif90

If they are there then you are all set. If not, go back to the configure step and make sure no errors were detected.

That's it for all required compilers/libraries. You may now install the Installation of the CFD package.

Updated