Installing GROMACS on Clust

From Docswiki
Jump to navigation Jump to search
  • Download GMX (gromacs-4.5.4.tar.gz [1]) and FFTW ( fftw-3.2.2.tar.gz [2]) source codes and extract in ~/SW
  • FFTW 3.2.2
cd ~/SW/fftw-3.2.2 
./configure --prefix=/home/ss2029/SWins/fftw --enable-threads --enable-shared
make 
make install 

GMX installation later fails if "--enable-shared" flag is not used.

Following files should be created in ~/SWins/fftw/lib:

 
~/SWins/fftw/lib> ls
libfftw3.a   libfftw3.so    libfftw3.so.3.2.4   libfftw3_threads.la  libfftw3_threads.so.3      pkgconfig
libfftw3.la  libfftw3.so.3  libfftw3_threads.a  libfftw3_threads.so  libfftw3_threads.so.3.2.4
  • GROMACS 4.5.4

Set environment variables for configure stage of GMX

export CPPFLAGS="-I/home/ss2029/SWins/fftw/include"
export LDFLAGS="-L/home/ss2029/SWins/fftw/lib"

A little comment here:--Vr274 17:03, 28 October 2011 (UTC) The cleaner solution instead of manually specifying the CPPFLAGS/LDFLAGS is to add the PKG_CONFIG_PATH

  export PKG_CONFIG_PATH="/home/ss2029/SWins/fftw/lib/pkgconfig:$PKG_CONFIG_PATH"

That also resolves the dependencies of fftw3 correctly. Check whether everything is correct by

 pkg-config --libs fftw3

Should list the correct path.

Install serial version

 
cd ~/SW/gromacs-4.5.4  
./configure --prefix=/home/ss2029/SWins/GMX454 --disable-float --without-x --with-fft=fftw3
make 
make install 

"--disable-float" installs in double precision. If all went well, apart from a number of utility programs with prefix "g_", you should see "mdrun_d" in ~/SWins/GMX454/bin which is the main MD engine.

Install MPI version MPI is used only by the MD engine, not by the utility programs. Following just recompiles mdrun with MPI.

 
cd ~/SW/gromacs-4.5.4  
module load mpi/openmpi/64/intel10/1.2.6
./configure --prefix=/home/ss2029/SWins/GMX454 --disable-float --enable-mpi --without-x --program-suffix=_mpi –with-fft=fftw3
make mdrun 
make install-mdrun

Look for "mdrun_mpi" in ~/SWins/GMX454/bin.

Note the MPI version loaded. Compilation failed with "mpi/openmpi/64/pgi71/1.2.6" and "mpi/mpich/64/gnu_/1.2.6".

The version of MPI loaded during installation must be loaded before every execution of mdrun_mpi.

I will shortly post some sample input/output to test the executables.

All set!

Some good tutorials to get started:

http://www.bevanlab.biochem.vt.edu/Pages/Personal/justin/gmx-tutorials

http://www.gromacs.org/Documentation/Tutorials


--Ss2029 11:19, 3 May 2011 (UTC)