<html><head><meta http-equiv="content-type" content="text/html; charset=utf-8"></head><body dir="auto"><div></div><div>The duplicate reference to Plumed.o problem reasserts itself when compiling with GPU as the make install step re-runs cmake. The solution here is to follow my previous protocol then after running the make install step you delete the duplicate reference again and run the make install step again. This is now with gromacs-5.0.4 and plumed-2.1.3 using default compilers rather than specifying any</div><blockquote type="cite"><div><div dir="ltr"><br>On Thursday, June 11, 2015 at 4:30:41 PM UTC+1, James Krieger wrote:<blockquote class="gmail_quote" style="margin: 0;margin-left: 0.8ex;border-left: 1px #ccc solid;padding-left: 1ex;"><div dir="ltr">I've found a work-around: using -pe openmpi #nodes with -l dedicated #threads/node (24 in my case) and OMP_NUM_THREADS #threads/nodes. <br><br>On Wednesday, June 10, 2015 at 4:19:49 PM UTC+1, James Krieger wrote:<blockquote class="gmail_quote" style="margin:0;margin-left:0.8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Something's still not right. At this point GROMACS is MPI-aware and can spread across multiple computers (nodes) when submitted to SGE with -pe openmpi in the submission script. However when adding asking it to use plumed for metad it fails unless it stays on a single machine (specified with -pe smp). It's not a problem of plumed not being compiled in MPI mode as using plumed to report on CVs without metad works across multiple nodes.<br><br>On Wednesday, June 10, 2015 at 1:38:19 PM UTC+1, James Krieger wrote:<blockquote style="margin:0;margin-left:0.8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Actually that solution wasn't quite right because I didn't have the mpi 
compilers set up properly. That resulted in gromacs not being mpi-aware 
but rather launching a separate mdrun_mpi process on each node 
requested. <br><br>Instead here's an updated solution that uses the default mpicc and mpicxx wrappers (from openmpi-1.5.4 on my system).<br><br>1. configure/make/install plumed with addition of -fPIC to CFLAGS in 
Makefile.conf before making (plumed-2.1.2 appears to need to be built in
 the src directory)<br><br>tar -xvzf plumed-2.1.2.tgz <br>mv plumed-2.1.2 plumed-2.1.2-src<br>mkdir plumed-2.1.2-install<br>cd plumed-2.1.2-src<br>./configure --prefix=/lmb/home/jkrieger/<div dir="ltr">bin/plumed-2.1.2-install/ CC=mpicc CXX=mpicxx<br>manually add -fPIC to CFLAGS in Makefile.conf (done using vi)<br>make VERBOSE=1 | &amp; tee m.txt<br>make install VERBOSE=1 | &amp; tee mi.txt<br>update PATH, LD_LIBRARY_PATH and PLUMED_KERNEL (added to ~/.login on my system and applied by logging out and back in again)<br><br>2. patch plumed onto gromacs in --runtime mode (as per recommendation of GB)<br><br>cd ~/bin<br>cp -r gromacs-5.0.4-src/ gromacs-5.0.4-src-plumed/<br>mkdir gromacs-5.0.4-build-plumed<br>mkdir gromacs-5.0.4-install-plumed<br>cd gromacs-5.0.4-src-plumed/<br>plumed patch -p --runtime<br><br>3.
 configure/make/install gromacs with separate src/build/install 
directories (as per recommendation of MA) with removal of duplicate 
reference to Plumed.o from <span style="font-size:12.8000001907349px">build-dir/src/</span><span style="font-size:12.8000001907349px">gromacs/<wbr>CMakeFiles/libgromacs.</span><span style="font-size:12.8000001907349px">dir/<wbr>link.txt (as per recommendation of GB)<br><br>cd ../</span>gromacs-5.0.4-build-plumed<br>cmake -DGMX_MPI=ON ../gromacs-5.0.4-src-plumed/ -DGMX_BUILD_OWN_FFTW=ON -DCMAKE_INSTALL_PREFIX=/lmb/<wbr>home/jkrieger/bin/gromacs-5.0.<wbr>4-install-plumed -DCMAKE_C_COMPILER=mpicc -DCMAKE_CXX_COMPILER=mpicxx<br>remove duplicate reference to Plumed.o from <span style="font-size:12.8000001907349px">build-dir/src/</span><span style="font-size:12.8000001907349px">gromacs/<wbr>CMakeFiles/libgromacs.</span><span style="font-size:12.8000001907349px">dir/<wbr>link.txt (again with vi)<br></span><span style="font-size:12.8000001907349px">make VERBOSE=1 | &amp; tee m.txt<br>make install VERBOSE=1 | &amp; tee mi.txt<br>update PATH and LD_LIBRARY_PATH (vi ~/.login, log out, log in again)</span></div><br><br>On Tuesday, June 9, 2015 at 7:23:14 PM UTC+1, James Krieger wrote:<blockquote style="margin:0;margin-left:0.8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Here is the solution. Thanks to both Giovanni Bussi and Mark Abraham for your help.<br><br>0. configure/make/install mpi compilers (separate src, build and install directories are used as suggested by MA)<br><br>tar -xvzfc mpich-3.1.4.tar.gz mpich-3.1.4-src<br>mkdir mpich-3.1.4-build<br>mkdir mpich-3.1.4-install<br>cd mpich-3.1.4-build<br>../mpich-3.1.4-src/configure --prefix=/lmb/home/jkrieger/<wbr>bin/mpich-3.1.4-install | &amp; tee c.txt<br>make VERBOSE=1 | &amp; tee m.txt<br>make install VERBOSE=1 | &amp; tee mi.txt<br><br>1. configure/make/install plumed with addition of -fPIC to CFLAGS in Makefile.conf before making (plumed-2.1.2 appears to need to be built in the src directory)<br><br>tar -xvzfc plumed-2.1.2.tgz plumed-2.1.2-src<br>mkdir plumed-2.1.2-install<br>cd plumed-2.1.2-src<br>./configure --prefix=/lmb/home/jkrieger/<wbr>bin/plumed-2.1.2-install/ CC=/lmb/home/jkrieger/bin/<wbr>mpich-3.1.4-install/bin/mpicc CXX=/lmb/home/jkrieger/bin/<wbr>mpich-3.1.4-install/bin/mpicxx<br>manually add -fPIC to CFLAGS in Makefile.conf (done using vi)<br>make VERBOSE=1 | &amp; tee m.txt<br>make install VERBOSE=1 | &amp; tee mi.txt<br>update PATH and LD_LIBRARY_PATH (added to ~/.login on my system and applied by logging out and back in again)<br><br>2. patch plumed onto gromacs in --runtime mode (as per recommendation of GB)<br><br>cd ~/bin<br>cp -r gromacs-5.0.4-src/ gromacs-5.0.4-src-plumed/<br>mkdir gromacs-5.0.4-build-plumed<br>mkdir gromacs-5.0.4-install-plumed<br>cd gromacs-5.0.4-src-plumed/<br>plumed patch -p --runtime<br><br>3. configure/make/install gromacs with separate src/build/install directories (as per recommendation of MA) with removal of duplicate reference to Plumed.o from <span style="font-size:12.8000001907349px">build-dir/src/</span><span style="font-size:12.8000001907349px">gromacs/<wbr>CMakeFiles/libgromacs.</span><span style="font-size:12.8000001907349px">dir/<wbr>link.txt (as per recommendation of GB)<br><br>cd ../</span>gromacs-5.0.4-build-plumed<br>cmake -DGMX_MPI=ON ../gromacs-5.0.4-src-plumed/ -DGMX_BUILD_OWN_FFTW=ON -DCMAKE_INSTALL_PREFIX=/lmb/<wbr>home/jkrieger/bin/gromacs-5.0.<wbr>4-install-plumed -DCMAKE_C_COMPILER=/lmb/home/<wbr>jkrieger/bin/mpich-3.1.4-<wbr>install/bin/mpicc -DCMAKE_CXX_COMPILER=/lmb/<wbr>home/jkrieger/bin/mpich-3.1.4-<wbr>install/bin/mpicxx<br>remove duplicate reference to Plumed.o from <span style="font-size:12.8000001907349px">build-dir/src/</span><span style="font-size:12.8000001907349px">gromacs/<wbr>CMakeFiles/libgromacs.</span><span style="font-size:12.8000001907349px">dir/<wbr>link.txt (again with vi)<br></span><span style="font-size:12.8000001907349px">make VERBOSE=1 | &amp; tee m.txt<br>make install VERBOSE=1 | &amp; tee mi.txt<br>update PATH and LD_LIBRARY_PATH (vi ~/.login, log out, log in again)</span><br></div></blockquote></div></blockquote></div></blockquote></div></blockquote></div>
</div></blockquote></body></html>