CFDEMcoupling v3.X Installation

Submitted by limone on Fri, 07/14/2017 - 17:30

Dear All,

I am following the installation of CFDEMcoupling v3.X from: https://www.cfdem.com/media/CFDEM/docu/CFDEMcoupling_Manual.html#.

When I type the command "cfdemSysTest", I get this message:

[cfdemuser@rbalwmba80000 ~]$ cfdemSysTest
*********************************************
* C F D E M (R) c o u p l i n g *
* *
* by DCS Computing GmbH *
* www.dcs-computing.com *
*********************************************

*********************************
CFDEM(R)coupling system settings:
*********************************
CFDEM_VERSION=PUBLIC
couple to OF_VERSION=3.0.x
compile option=Opt

check if paths are set correctly
valid:yes critical:yes - $CFDEM_PROJECT_DIR = /home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-3.0.x
valid:yes critical:no - $CFDEM_PROJECT_USER_DIR = /home/cfdemuser/CFDEM/cfdemuser-PUBLIC-3.0.x
valid:yes critical:yes - $CFDEM_SRC_DIR = /home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-3.0.x/src
valid:yes critical:yes - $CFDEM_SOLVER_DIR = /home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-3.0.x/applications/solvers
valid:yes critical:yes - $CFDEM_TUT_DIR = /home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-3.0.x/tutorials
valid:yes critical:yes - $CFDEM_LIGGGHTS_SRC_DIR = /home/cfdemuser/LIGGGHTS/LIGGGHTS-PUBLIC/src
valid:yes critical:yes - $CFDEM_LIGGGHTS_LIB_PATH = /home/cfdemuser/LIGGGHTS/LIGGGHTS-PUBLIC/src
valid:yes critical:yes - $CFDEM_LPP_DIR = /home/cfdemuser/LIGGGHTS/lpp/src
valid:yes critical:yes - $CFDEM_ADD_LIBS_DIR = /home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-3.0.x/src/lagrangian/cfdemParticle/etc/addLibs_universal
valid:yes critical:yes - $CFDEM_LIB_DIR = /home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-3.0.x/platforms/linux64GccDPInt32Opt/lib
valid:yes critical:yes - $CFDEM_APP_DIR = /home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-3.0.x/platforms/linux64GccDPInt32Opt/bin
valid:yes critical:no - $CFDEM_USER_LIB_DIR = /home/cfdemuser/CFDEM/cfdemuser-PUBLIC-3.0.x/platforms/linux64GccDPInt32Opt/lib
valid:yes critical:no - $CFDEM_USER_APP_DIR = /home/cfdemuser/CFDEM/cfdemuser-PUBLIC-3.0.x/platforms/linux64GccDPInt32Opt/bin
valid:yes critical:no - $CFDEM_TEST_HARNESS_PATH = /home/cfdemuser/CFDEM/cfdemuser-PUBLIC-3.0.x/log/logFilesCFDEM-PUBLIC-3.0.x
valid:NO critical:no - $C3PO_SRC_DIR = does not exist

library names
$CFDEM_LIGGGHTS_LIB_NAME = lmp_auto
$CFDEM_LIB_NAME = lagrangianCFDEM-PUBLIC-3.0.x
$LD_LIBRARY_PATH = /home/cfdemuser/CFDEM/cfdemuser-PUBLIC-3.0.x/platforms/linux64GccDPInt32Opt/lib:/home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-3.0.x/platforms/linux64GccDPInt32Opt/lib:/home/cfdemuser/OpenFOAM/ThirdParty-3.0.x/platforms/linux64Gcc/gperftools-svn/lib:/home/cfdemuser/OpenFOAM/OpenFOAM-3.0.x/platforms/linux64GccDPInt32Opt/lib/openmpi-system:/home/cfdemuser/OpenFOAM/ThirdParty-3.0.x/platforms/linux64GccDPInt32Opt/lib/openmpi-system:/usr/local/lib:/home/cfdemuser/OpenFOAM/cfdemuser-3.0.x/platforms/linux64GccDPInt32Opt/lib:/home/cfdemuser/OpenFOAM/site/3.0.x/platforms/linux64GccDPInt32Opt/lib:/home/cfdemuser/OpenFOAM/OpenFOAM-3.0.x/platforms/linux64GccDPInt32Opt/lib:/home/cfdemuser/OpenFOAM/ThirdParty-3.0.x/platforms/linux64GccDPInt32Opt/lib:/home/cfdemuser/OpenFOAM/OpenFOAM-3.0.x/platforms/linux64GccDPInt32Opt/lib/dummy:/home/cfdemuser/CFDEM/cfdemuser-PUBLIC-3.0.x/platforms/linux64GccDPInt32Opt/lib:/home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-3.0.x/platforms/linux64GccDPInt32Opt/lib
$WM_NCOMPPROCS = 20
$WM_LABEL_SIZE = 32

Additional lib settings
CFDEM_ADD_LIBS_DIR/CFDEM_ADD_LIBS_NAME = /home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-3.0.x/src/lagrangian/cfdemParticle/etc/addLibs_universal/additionalLibs_3.0.x
CFDEM_ADD_LIB_PATHS =
CFDEM_ADD_LIBS =

LIGGGHTS library link (created during compilation of CFDEM)
ls: cannot access /home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-3.0.x/platforms/linux64GccDPInt32Opt/lib/liblmp*: No such file or directory
*******************
g++:
/usr/bin/g++
g++ (GCC) 4.8.5 20150623 (Red Hat 4.8.5-11)
Copyright (C) 2015 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

gcc:
/usr/bin/gcc
gcc (GCC) 4.8.5 20150623 (Red Hat 4.8.5-11)
Copyright (C) 2015 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

mpic++:
/usr/local/bin/mpic++
g++ (GCC) 4.8.5 20150623 (Red Hat 4.8.5-11)
Copyright (C) 2015 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

mpirun:
/usr/local/bin/mpirun
mpirun (Open MPI) 2.1.1

Report bugs to http://www.open-mpi.org/community/help/
**********************
additional packages...
[cfdemuser@rbalwmba80000 ~]$

If I go inside the folder
/home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-3.0.x/platforms/linux64GccDPInt32Opt/lib/liblmp*: No such file or directory
It is empty. Any suggestion ?

Best regards,
Simon

alice's picture

alice | Mon, 07/17/2017 - 07:29

Hello Simon,
did you already run cfdemCompCFDEMall? In case yes, please have a look at the log file of the LIGGGHTS compilation log file (src/lagrangian/cfdemParticel/etc/log/log_compileLIGGGHTS) and see what it says. Otherwise please run the above mentioned shell command to compile all sources.
Cheers,
Alice

limone | Mon, 07/17/2017 - 10:56

Hi Alice !

Thank you very much for your help. I followed your instructions and the log file is here following:

// log_compileLIGGGHTS-2017-07-17-10:38 //

/home/cfdemuser/LIGGGHTS/LIGGGHTS-PUBLIC/src

rm -rf Obj_auto MAKE/Makefile.auto.options lmp_auto liblmp_auto.a liblmp_auto.so
Creating list of contact models completed.
make[1]: Entering directory `/home/cfdemuser/LIGGGHTS/LIGGGHTS-PUBLIC/src/Obj_auto'
Makefile:538: *** Could not obtain VTK_MAJOR_VERSION. Stop.
make[1]: Leaving directory `/home/cfdemuser/LIGGGHTS/LIGGGHTS-PUBLIC/src/Obj_auto'
make: *** [auto] Error 2
make[1]: Entering directory `/home/cfdemuser/LIGGGHTS/LIGGGHTS-PUBLIC/src/Obj_auto'
Makefile:538: *** Could not obtain VTK_MAJOR_VERSION. Stop.
make[1]: Leaving directory `/home/cfdemuser/LIGGGHTS/LIGGGHTS-PUBLIC/src/Obj_auto'
make: *** [auto] Error 2

Now, I have no idea on what to do.............

Best,
Simone

alice's picture

alice | Tue, 07/18/2017 - 07:57

Hello Simone,
the LIGGGHTS installation failed because of issues with the VTK version. Did you install vtk on your system (see instructions) or do you already have a version on your system? In the latter case, which one?
Cheers,
Alice

limone | Tue, 07/18/2017 - 15:14

Hi Alice,

Let me explain what I did in my CentOS workstation:

*****************************************
(1) Install cmake-3.9.0-rc5 (I followed the guide http://www.vtk.org/Wiki/VTK/Configure_and_Build):
*****************************************

sudo yum remove cmake
cd $HOME
wget https://cmake.org/files/v3.9/cmake-3.9.0-rc5.tar.gz
tar xzvf cmake-3.9.0-rc5.tar.gz
cd cmake-3.9.0-rc5/
sudo ./configure --prefix=/usr/local
sudo make
sudo make install

# Test the cmake version:
cmake --version
# Results of cmake --version:
cmake version 3.9.0-rc5
CMake suite maintained and supported by Kitware (kitware.com/cmake).

*****************************************
(2) Install VTK:
*****************************************

# Prepare directory for download:
mkdir $HOME/projects
cd $HOME/projects

# To download the source code:
git clone git://vtk.org/VTK.git
cd VTK

# To update the code:
git fetch origin
git rebase origin/master

# Configure VTK with CMake:
mkdir $HOME/projects/VTK-build
cd $HOME/projects/VTK-build
ccmake $HOME/projects/VTK

# Build VTK:
cd $HOME/projects/VTK-build
make j4

# Create a symbolic link of "vtk-8.1" called simply "vtk" inside /usr/local/include:
cd /usr/local/include
sudo ln -s vtk-8.1 vtk

*****************************************
(3) Summary:
*****************************************

cmake version 3.9.0-rc5 is inside "/usr/local"
vtk-8.1 is inside "usr/local/include"

*****************************************
(4) cfdemSysTest:
*****************************************

*********************************************
* C F D E M (R) c o u p l i n g *
* *
* by DCS Computing GmbH *
* www.dcs-computing.com *
*********************************************

*********************************
CFDEM(R)coupling system settings:
*********************************
CFDEM_VERSION=PUBLIC
couple to OF_VERSION=3.0.x
compile option=Opt

check if paths are set correctly
valid:yes critical:yes - $CFDEM_PROJECT_DIR = /home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-3.0.x
valid:yes critical:no - $CFDEM_PROJECT_USER_DIR = /home/cfdemuser/CFDEM/cfdemuser-PUBLIC-3.0.x
valid:yes critical:yes - $CFDEM_SRC_DIR = /home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-3.0.x/src
valid:yes critical:yes - $CFDEM_SOLVER_DIR = /home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-3.0.x/applications/solvers
valid:yes critical:yes - $CFDEM_TUT_DIR = /home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-3.0.x/tutorials
valid:yes critical:yes - $CFDEM_LIGGGHTS_SRC_DIR = /home/cfdemuser/LIGGGHTS/LIGGGHTS-PUBLIC/src
valid:yes critical:yes - $CFDEM_LIGGGHTS_LIB_PATH = /home/cfdemuser/LIGGGHTS/LIGGGHTS-PUBLIC/src
valid:yes critical:yes - $CFDEM_LPP_DIR = /home/cfdemuser/LIGGGHTS/lpp/src
valid:yes critical:yes - $CFDEM_ADD_LIBS_DIR = /home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-3.0.x/src/lagrangian/cfdemParticle/etc/addLibs_universal
valid:yes critical:yes - $CFDEM_LIB_DIR = /home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-3.0.x/platforms/linux64GccDPInt32Opt/lib
valid:yes critical:yes - $CFDEM_APP_DIR = /home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-3.0.x/platforms/linux64GccDPInt32Opt/bin
valid:yes critical:no - $CFDEM_USER_LIB_DIR = /home/cfdemuser/CFDEM/cfdemuser-PUBLIC-3.0.x/platforms/linux64GccDPInt32Opt/lib
valid:yes critical:no - $CFDEM_USER_APP_DIR = /home/cfdemuser/CFDEM/cfdemuser-PUBLIC-3.0.x/platforms/linux64GccDPInt32Opt/bin
valid:yes critical:no - $CFDEM_TEST_HARNESS_PATH = /home/cfdemuser/CFDEM/cfdemuser-PUBLIC-3.0.x/log/logFilesCFDEM-PUBLIC-3.0.x
valid:NO critical:no - $C3PO_SRC_DIR = does not exist

library names
$CFDEM_LIGGGHTS_LIB_NAME = lmp_auto
$CFDEM_LIB_NAME = lagrangianCFDEM-PUBLIC-3.0.x
$LD_LIBRARY_PATH = /home/cfdemuser/CFDEM/cfdemuser-PUBLIC-3.0.x/platforms/linux64GccDPInt32Opt/lib:/home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-3.0.x/platforms/linux64GccDPInt32Opt/lib:/home/cfdemuser/OpenFOAM/ThirdParty-3.0.x/platforms/linux64Gcc/gperftools-svn/lib:/home/cfdemuser/OpenFOAM/OpenFOAM-3.0.x/platforms/linux64GccDPInt32Opt/lib/openmpi-system:/home/cfdemuser/OpenFOAM/ThirdParty-3.0.x/platforms/linux64GccDPInt32Opt/lib/openmpi-system:/usr/local/lib:/home/cfdemuser/OpenFOAM/cfdemuser-3.0.x/platforms/linux64GccDPInt32Opt/lib:/home/cfdemuser/OpenFOAM/site/3.0.x/platforms/linux64GccDPInt32Opt/lib:/home/cfdemuser/OpenFOAM/OpenFOAM-3.0.x/platforms/linux64GccDPInt32Opt/lib:/home/cfdemuser/OpenFOAM/ThirdParty-3.0.x/platforms/linux64GccDPInt32Opt/lib:/home/cfdemuser/OpenFOAM/OpenFOAM-3.0.x/platforms/linux64GccDPInt32Opt/lib/dummy:/home/cfdemuser/CFDEM/cfdemuser-PUBLIC-3.0.x/platforms/linux64GccDPInt32Opt/lib:/home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-3.0.x/platforms/linux64GccDPInt32Opt/lib
$WM_NCOMPPROCS = 20
$WM_LABEL_SIZE = 32

Additional lib settings
CFDEM_ADD_LIBS_DIR/CFDEM_ADD_LIBS_NAME = /home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-3.0.x/src/lagrangian/cfdemParticle/etc/addLibs_universal/additionalLibs_3.0.x
/usr/local/include/vtk
CFDEM_ADD_LIB_PATHS =
CFDEM_ADD_LIBS =

LIGGGHTS library link (created during compilation of CFDEM)
ls: cannot access /home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-3.0.x/platforms/linux64GccDPInt32Opt/lib/liblmp*: No such file or directory
*******************
g++:
/usr/bin/g++
g++ (GCC) 4.8.5 20150623 (Red Hat 4.8.5-11)
Copyright (C) 2015 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

gcc:
/usr/bin/gcc
gcc (GCC) 4.8.5 20150623 (Red Hat 4.8.5-11)
Copyright (C) 2015 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

mpic++:
/usr/local/bin/mpic++
g++ (GCC) 4.8.5 20150623 (Red Hat 4.8.5-11)
Copyright (C) 2015 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

mpirun:
/usr/local/bin/mpirun
mpirun (Open MPI) 2.1.1

Report bugs to http://www.open-mpi.org/community/help/
**********************
additional packages...
[cfdemuser@rbalwmba80000 vtk]$

limone | Tue, 07/18/2017 - 15:53

Dear Alice,

I am writing to require some help since we tried to install LIGGGTHS and CFDEMcoupling, but without success.
We have CentOS as Operating System and all the instructions for the installation are mainly for Ubuntu/Debian.

For example we cannot find the libraries for CentOS typing
sudo apt-get install build-essential flex bison cmake zlib1g-dev libboost-system-dev libboost-thread-dev libopenmpi-dev openmpi-bin gnuplot libreadline-dev libncurses-dev libxt-dev libscotch-dev libptscotch-dev

as in the guide : https://www.cfdem.com/media/CFDEM/docu/CFDEMcoupling_Manual.html#. Of course we changed "apt-get" in "yum", but most of those packages are not found.

Do you have installation instructions for CentOS ?
Otherwise how can be get support from you/your colleagues, and which are the prices ? (contacts and prices)
We need the installation urgently.

Best regards,
Simone

j-kerbl's picture

j-kerbl | Tue, 07/18/2017 - 16:19

Hi Simone,

your steps seem reasonable to me. Since OpenFOAM should be up and running, before you started with CFDEMcoupling, you do not need the sudo apt-get line from above, since it are the pre-requisites for OpenFOAM.
I personally have not tried VTK 8 yet, but it should work.

Two remarks from my side:
1.) VTK compilation:
Have you enabled the MPI (Parallel) Group of VTK in ccmake? This is an important switch to build the correct libraries.

2.) Makefile auto configuration:
The LIGGGHTS-PUBLIC/src/MAKE/Makefile.user Makefile needs to be modified.
You will need to manually edit the VTK variables, since you have a user-defined VTK installation and your VTK version (8.1 ?) is very new.
See  https://www.cfdem.com/media/DEM/docu/Section_start.html#making-liggghts-r-public
So you need to set VTK_INC_USR=/path/to/vtk/include and VTK_LIB_USR=/path/to/vtk/lib to your VTK specific directories.
Then it should auto-detect the version and proceed without a problem.

If the problem persists and you need the quickest solution, switch off VTK in Makefile.user. You might buy some time to figure out the VTK issues.
BUT USING VTK IS STRONGLY RECOMMENDED. So this would be a temporary workaround.

Cheers,
Josef

limone | Mon, 07/24/2017 - 18:39

Hi Josef,

Thank you for your kind reply. Following/Adapting your instructions, we have fixed the problem for LIGGGTHS, but we got an error for OpenFoam/CFDEM.
First, I show you what we changed to successfully install LIGGGTHS in CentOS Linux 7 (OS Type: 64-bit, GNOME: Version 3.14.2):

*****************************************
(1) Install cmake-3.8.2:
*****************************************

# we removed cmake-3.9.0-rc5 (previously installed) for compatibility reasons
sudo yum remove cmake
cd /usr/local
wget https://cmake.org/files/v3.8/cmake-3.8.2.tar.gz
tar xzvf cmake-3.8.2.tar.gz
cd cmake-3.8.2
sudo ./configure --prefix=/usr/local
sudo ./bootstrap
sudo make
sudo make install

# Test the cmake version:
cmake --version
# Results of cmake --version:
cmake version 3.8.2
CMake suite maintained and supported by Kitware (kitware.com/cmake).

*****************************************
(2) Install VTK-8.1:
*****************************************

# Prepare directory for download:
mkdir $HOME/projects
cd $HOME/projects

# To download the source code:
git clone http://vtk.org/VTK.git
cd VTK

# To update the code:
git fetch origin
git rebase origin/master

# Configure VTK with CMake:
mkdir $HOME/projects/VTK-build
cd $HOME/projects/VTK-build
ccmake $HOME/projects/VTK
# Very Important: inside ccmake, first press "c" to configure and then press "g" to generate !

# Build VTK:
cd $HOME/projects/VTK-build
# Once inside the VTK-build folder we typed the command "make -j4", but it did not work (error: "missing target").
# The problem was the name of the "Makefile". We did a copy of that file, naming it as "makefile" (we think it is an error of cmake)
cp Makefile makefile
# Then the comand "make -j4" was working and we built the directories in /usr/local/include by using "sudo"
sudo make -j4
sudo make install

# Create a symbolic link of "vtk-8.1" called simply "vtk" inside /usr/local/include.
# In this way, the rest of the LIGGGTHS compilation is working
cd /usr/local/include
sudo ln -s vtk-8.1 vtk

*****************************************
(3) Summary:
*****************************************

As you indicated we manually set the variables VTK_INC_USR and VTK_LIB_USR in
/home/cfdemuser/LIGGGHTS/LIGGGHTS-PUBLIC/src/MAKE/Makefile.user

# VTK specific variables
#
# Path that contains the includes (vtkVersion.h)
# VTK_INC_USR=-I/home/cfdemuser/projects/VTK/Common/Core
VTK_INC_USR=-I/usr/local/include/vtk
# Path that contains the VTK libraries
# VTK_LIB_USR=-L/home/cfdemuser/projects/VTK-build/lib
VTK_LIB_USR=-L/home/cfdemuser/projects/VTK-build/lib

*****************************************
(4) Summary:
*****************************************

cmake version 3.8.2 is inside "/usr/local"
vtk-8.1 is inside "usr/local/include"

*****************************************
(5) cfdemSysTest:
*****************************************

Now, "cfdemSysTest" does not show anymore the previous error:
"LIGGGHTS library link (created during compilation of CFDEM)
ls: cannot access /home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-3.0.x/platforms/linux64GccDPInt32Opt/lib/liblmp*: No such file or directory"
.........as you can see...........

[cfdemuser@rbalwmba80000 ~]$ cfdemSysTest

*********************************************
* C F D E M (R) c o u p l i n g *
* *
* by DCS Computing GmbH *
* www.dcs-computing.com *
*********************************************

*********************************
CFDEM(R)coupling system settings:
*********************************
CFDEM_VERSION=PUBLIC
couple to OF_VERSION=3.0.x
compile option=Opt

check if paths are set correctly
valid:yes critical:yes - $CFDEM_PROJECT_DIR = /home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-3.0.x
valid:yes critical:no - $CFDEM_PROJECT_USER_DIR = /home/cfdemuser/CFDEM/cfdemuser-PUBLIC-3.0.x
valid:yes critical:yes - $CFDEM_SRC_DIR = /home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-3.0.x/src
valid:yes critical:yes - $CFDEM_SOLVER_DIR = /home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-3.0.x/applications/solvers
valid:yes critical:yes - $CFDEM_TUT_DIR = /home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-3.0.x/tutorials
valid:yes critical:yes - $CFDEM_LIGGGHTS_SRC_DIR = /home/cfdemuser/LIGGGHTS/LIGGGHTS-PUBLIC/src
valid:yes critical:yes - $CFDEM_LIGGGHTS_LIB_PATH = /home/cfdemuser/LIGGGHTS/LIGGGHTS-PUBLIC/src
valid:yes critical:yes - $CFDEM_LPP_DIR = /home/cfdemuser/LIGGGHTS/lpp/src
valid:yes critical:yes - $CFDEM_ADD_LIBS_DIR = /home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-3.0.x/src/lagrangian/cfdemParticle/etc/addLibs_universal
valid:yes critical:yes - $CFDEM_LIB_DIR = /home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-3.0.x/platforms/linux64GccDPInt32Opt/lib
valid:yes critical:yes - $CFDEM_APP_DIR = /home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-3.0.x/platforms/linux64GccDPInt32Opt/bin
valid:yes critical:no - $CFDEM_USER_LIB_DIR = /home/cfdemuser/CFDEM/cfdemuser-PUBLIC-3.0.x/platforms/linux64GccDPInt32Opt/lib
valid:yes critical:no - $CFDEM_USER_APP_DIR = /home/cfdemuser/CFDEM/cfdemuser-PUBLIC-3.0.x/platforms/linux64GccDPInt32Opt/bin
valid:yes critical:no - $CFDEM_TEST_HARNESS_PATH = /home/cfdemuser/CFDEM/cfdemuser-PUBLIC-3.0.x/log/logFilesCFDEM-PUBLIC-3.0.x
valid:NO critical:no - $C3PO_SRC_DIR = does not exist

library names
$CFDEM_LIGGGHTS_LIB_NAME = lmp_auto
$CFDEM_LIB_NAME = lagrangianCFDEM-PUBLIC-3.0.x
$LD_LIBRARY_PATH = /home/cfdemuser/CFDEM/cfdemuser-PUBLIC-3.0.x/platforms/linux64GccDPInt32Opt/lib:/home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-3.0.x/platforms/linux64GccDPInt32Opt/lib:/home/cfdemuser/OpenFOAM/ThirdParty-3.0.x/platforms/linux64Gcc/gperftools-svn/lib:/home/cfdemuser/OpenFOAM/OpenFOAM-3.0.x/platforms/linux64GccDPInt32Opt/lib/openmpi-system:/home/cfdemuser/OpenFOAM/ThirdParty-3.0.x/platforms/linux64GccDPInt32Opt/lib/openmpi-system:/usr/local/lib:/home/cfdemuser/OpenFOAM/cfdemuser-3.0.x/platforms/linux64GccDPInt32Opt/lib:/home/cfdemuser/OpenFOAM/site/3.0.x/platforms/linux64GccDPInt32Opt/lib:/home/cfdemuser/OpenFOAM/OpenFOAM-3.0.x/platforms/linux64GccDPInt32Opt/lib:/home/cfdemuser/OpenFOAM/ThirdParty-3.0.x/platforms/linux64GccDPInt32Opt/lib:/home/cfdemuser/OpenFOAM/OpenFOAM-3.0.x/platforms/linux64GccDPInt32Opt/lib/dummy:/home/cfdemuser/CFDEM/cfdemuser-PUBLIC-3.0.x/platforms/linux64GccDPInt32Opt/lib:/home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-3.0.x/platforms/linux64GccDPInt32Opt/lib
$WM_NCOMPPROCS = 20
$WM_LABEL_SIZE = 32

Additional lib settings
CFDEM_ADD_LIBS_DIR/CFDEM_ADD_LIBS_NAME = /home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-3.0.x/src/lagrangian/cfdemParticle/etc/addLibs_universal/additionalLibs_3.0.x
/home/cfdemuser
CFDEM_ADD_LIB_PATHS =
CFDEM_ADD_LIBS =

LIGGGHTS library link (created during compilation of CFDEM)
lrwxrwxrwx. 1 cfdemuser cfdemuser 59 Jul 24 17:15 /home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-3.0.x/platforms/linux64GccDPInt32Opt/lib/liblmp_auto.so -> /home/cfdemuser/LIGGGHTS/LIGGGHTS-PUBLIC/src/liblmp_auto.so
*******************
g++:
/usr/bin/g++
g++ (GCC) 4.8.5 20150623 (Red Hat 4.8.5-11)
Copyright (C) 2015 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

gcc:
/usr/bin/gcc
gcc (GCC) 4.8.5 20150623 (Red Hat 4.8.5-11)
Copyright (C) 2015 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

mpic++:
/usr/local/bin/mpic++
g++ (GCC) 4.8.5 20150623 (Red Hat 4.8.5-11)
Copyright (C) 2015 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

mpirun:
/usr/local/bin/mpirun
mpirun (Open MPI) 2.1.1

Report bugs to http://www.open-mpi.org/community/help/
**********************
additional packages...
[cfdemuser@rbalwmba80000 ~]$

*****************************************
(6) cfdemCompCFDEMsrc or cfdemCompCFDEMall
*****************************************

We then compiled LIGGGTHS and no error occured. But the compilation of "cfdemCompCFDEMsrc" (or "cfdemCompCFDEMall") gave us the following error:

" -pthread -Wl,-rpath -Wl,/usr/local/lib -Wl,--enable-new-dtags -L/usr/local/lib -lmpi -L/home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-3.0.x/platforms/linux64GccDPInt32Opt/lib -lfiniteVolume -lturbulenceModels -lincompressibleTurbulenceModels -lfvOptions -lmeshTools -llagrangian -Wl,--whole-archive -llmp_auto -Wl,--no-whole-archive -lmpi_cxx -o /home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-3.0.x/platforms/linux64GccDPInt32Opt/lib/liblagrangianCFDEM-PUBLIC-3.0.x.so
/usr/bin/ld: cannot find -lmpi_cxx
collect2: error: ld returned 1 exit status
make: *** [/home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-3.0.x/platforms/linux64GccDPInt32Opt/lib/liblagrangianCFDEM-PUBLIC-3.0.x.so] Error 1
"

*****************************************
QUESTION: Do you have any suggestion for this last error ? Can be OpenFoam ?
*****************************************

Just for your information we have this installation (from "versionInfo_H"):
word CFDEMversion="cfdem-3.7.0";
word compatibleLIGGGHTSversion="3.7.0";
word OFversion="3.0.x-commit-ac3f6c67e02f0aac3777c27f9fb7558fc3536e37";

Regards,
Simone

limone | Mon, 07/24/2017 - 18:46

Errata Corrige

There is a typo. The header "(3) Summary" should be "(3) VTK Variables".

Regards,
Simone

j-kerbl's picture

j-kerbl | Fri, 07/28/2017 - 14:24

Hi Simone,

sorry for the delay, there was a lot going on. The procedure looks alright!

The error states it cannot find the library libmpi_cxx.so, which should be a part of the OpenMPI installation. In your case it should be somewhere similar to /usr/local/lib(64?)/ .

I have tested it and you should be able to remove the entry -lmpi_cxx in the additional_libs https://github.com/CFDEMproject/CFDEMcoupling-PUBLIC/blob/master/src/lagrangian/cfdemParticle/etc/addLibs_universal/additionalLibs_3.0.x#L9 . It isn't necessary anymore, since we changed the compilation routine in the last release.

Cheers,
Josef

limone | Wed, 08/16/2017 - 15:21

Hi Josef,

Thank you for this crucial email! I successfully installed CFDEM in my workstation!
I can say that cfdem-3.7.0 is working on CentOS Linux 7 (OS Type: 64-bit, GNOME: Version 3.14.2), with the aforementioned instructions (previous posts in this thread) and two last modifications:

(1) I followed again the installation of OpenFoam for CentOS in https://openfoamwiki.net/index.php/Installation/Linux/OpenFOAM-3.0.x/Cen...
noticing that some library for CentOS was missing (the problem about the libraries arose from the installation guide of CFDEM coupling which was for Debian Ubuntu, but not for CentOS - we did not find a guide for CentOS). Therefore, just with a copy and past of the following command in the terminal, we installed the missing libraries, fixing the problem:
yum groupinstall 'Development Tools'
yum install openmpi openmpi-devel zlib-devel texinfo gstreamer-plugins-base-devel \
libXext-devel libGLU-devel libXt-devel libXrender-devel libXinerama-devel libpng-devel \
libXrandr-devel libXi-devel libXft-devel libjpeg-turbo-devel libXcursor-devel \
readline-devel ncurses-devel python python-devel

(2) Comment the entry "-lmpi_cxx" in the "additionalLibs_3.0.x" as you kindly indicated.

After these two last modifications we run "cfdemCompCFDEMall" and successfully installed the software!
I think with this thread could be useful to other people who want to install CFDEM-3.7.0 on CentOS Linux 7.

Thank you very much for your great support Josep and Alice!

Best Regards,
Simone

rvonlant | Tue, 04/17/2018 - 14:33

Dear all,

Thank you for sharing your installation experiences on CentOS! So far they have been very helpful.

Following Simone's instructions I was able to install CFDEM-3.8.0 on CentOS 7.4, but only when disabling VTK (USE_VTK = "OFF") in $CFDEM_LIGGGHTS_SRC_DIR/MAKE/Makefile.user. After compiling with cfdemCompCFDEMall I successfully ran the ErgunTestMPI tutorial.

In order to include VTK-8.1.0, I modified the following three entries in the Makefile.user:
USE_VTK = "ON"
VTK_INC_USR=-I/usr/local/include/vtk
VTK_LIB_USR=-L/usr/local/lib

cfdemCompCFDEMall ran through without error messages and the log files then show ...
$CFDEM_PROJECT_DIR/src/lagrangian/cfdemParticle/etc/log/log_compile_results_src_success:
cfdemParticle
scalarTransportModelsCFDEM
fvOptionsCFDEM
$CFDEM_PROJECT_DIR/src/lagrangian/cfdemParticle/etc/log/log_compile_results_sol_success:
cfdemSolverPiso
cfdemSolverIB
cfdemSolverPisoScalar
cfdemSolverPisoSTM

Checking the installation with cfdemSysTest prints ...

*********************************************
* C F D E M (R) c o u p l i n g *
* *
* by DCS Computing GmbH *
* www.dcs-computing.com *
*********************************************

*********************************
CFDEM(R)coupling system settings:
*********************************
CFDEM_VERSION=PUBLIC
couple to OF_VERSION=5.x
compile option=Opt

check if paths are set correctly
valid:yes critical:yes - $CFDEM_PROJECT_DIR = /home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-5.x
valid:yes critical:no - $CFDEM_PROJECT_USER_DIR = /home/cfdemuser/CFDEM/cfdemuser-PUBLIC-5.x
valid:yes critical:yes - $CFDEM_SRC_DIR = /home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-5.x/src
valid:yes critical:yes - $CFDEM_SOLVER_DIR = /home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-5.x/applications/solvers
valid:yes critical:yes - $CFDEM_TUT_DIR = /home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-5.x/tutorials
valid:yes critical:yes - $CFDEM_LIGGGHTS_SRC_DIR = /home/cfdemuser/LIGGGHTS/LIGGGHTS-PUBLIC/src
valid:yes critical:yes - $CFDEM_LIGGGHTS_LIB_PATH = /home/cfdemuser/LIGGGHTS/LIGGGHTS-PUBLIC/src
valid:yes critical:yes - $CFDEM_LPP_DIR = /home/cfdemuser/LIGGGHTS/lpp/src
valid:yes critical:yes - $CFDEM_ADD_LIBS_DIR = /home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-5.x/src/lagrangian/cfdemParticle/etc/addLibs_universal
valid:yes critical:yes - $CFDEM_LIB_DIR = /home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-5.x/platforms/linux64GccDPInt32Opt/lib
valid:yes critical:yes - $CFDEM_APP_DIR = /home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-5.x/platforms/linux64GccDPInt32Opt/bin
valid:yes critical:no - $CFDEM_USER_LIB_DIR = /home/cfdemuser/CFDEM/cfdemuser-PUBLIC-5.x/platforms/linux64GccDPInt32Opt/lib
valid:yes critical:no - $CFDEM_USER_APP_DIR = /home/cfdemuser/CFDEM/cfdemuser-PUBLIC-5.x/platforms/linux64GccDPInt32Opt/bin
valid:yes critical:no - $CFDEM_TEST_HARNESS_PATH = /home/cfdemuser/CFDEM/cfdemuser-PUBLIC-5.x/log/logFilesCFDEM-PUBLIC-5.x
valid:NO critical:no - $C3PO_SRC_DIR = does not exist

library names
$CFDEM_LIGGGHTS_LIB_NAME = lmp_auto
$CFDEM_LIB_NAME = lagrangianCFDEM-PUBLIC-5.x
$LD_LIBRARY_PATH = /home/cfdemuser/CFDEM/cfdemuser-PUBLIC-5.x/platforms/linux64GccDPInt32Opt/lib:/home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-5.x/platforms/linux64GccDPInt32Opt/lib:/home/cfdemuser/OpenFOAM/ThirdParty-5.x/platforms/linux64Gcc/gperftools-svn/lib:/home/cfdemuser/OpenFOAM/OpenFOAM-5.x/platforms/linux64GccDPInt32Opt/lib/openmpi-system:/home/cfdemuser/OpenFOAM/ThirdParty-5.x/platforms/linux64GccDPInt32/lib/openmpi-system:/usr/lib64/openmpi/lib:/home/cfdemuser/OpenFOAM/cfdemuser-5.x/platforms/linux64GccDPInt32Opt/lib:/home/cfdemuser/OpenFOAM/site/5.x/platforms/linux64GccDPInt32Opt/lib:/home/cfdemuser/OpenFOAM/OpenFOAM-5.x/platforms/linux64GccDPInt32Opt/lib:/home/cfdemuser/OpenFOAM/ThirdParty-5.x/platforms/linux64GccDPInt32/lib:/home/cfdemuser/OpenFOAM/OpenFOAM-5.x/platforms/linux64GccDPInt32Opt/lib/dummy
$WM_NCOMPPROCS = 20
$WM_LABEL_SIZE = 32

Additional lib settings
CFDEM_ADD_LIBS_DIR/CFDEM_ADD_LIBS_NAME = /home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-5.x/src/lagrangian/cfdemParticle/etc/addLibs_universal/additionalLibs_5.x
CFDEM_ADD_LIB_PATHS =
CFDEM_ADD_LIBS =

LIGGGHTS library link (created during compilation of CFDEM)
lrwxrwxrwx 1 cfdemuser cfdemuser 59 Apr 17 13:12 /home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-5.x/platforms/linux64GccDPInt32Opt/lib/liblmp_auto.so -> /home/cfdemuser/LIGGGHTS/LIGGGHTS-PUBLIC/src/liblmp_auto.so
*******************
g++:
/usr/bin/g++
g++ (GCC) 4.8.5 20150623 (Red Hat 4.8.5-16)
Copyright (C) 2015 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

gcc:
/usr/bin/gcc
gcc (GCC) 4.8.5 20150623 (Red Hat 4.8.5-16)
Copyright (C) 2015 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

mpic++:
/usr/lib64/openmpi/bin/mpic++
g++ (GCC) 4.8.5 20150623 (Red Hat 4.8.5-16)
Copyright (C) 2015 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

mpirun:
/usr/lib64/openmpi/bin/mpirun
mpirun (Open MPI) 1.10.6

Report bugs to http://www.open-mpi.org/community/help/
**********************
additional packages...

To me, everything seems to be installed properly. However, when I try to run the ErgunTestMPI tutorial I get the following messages ...

// run_parallel_cfdemSolverPiso_ErgunTestMPI_CFDDEM //

/home/cfdemuser/CFDEM/CFDEMcoupling-PUBLIC-5.x/tutorials/cfdemSolverPiso/ErgunTestMPI/CFD

rm: cannot remove ‘couplingFiles/*’: No such file or directory
cfdemSolverPiso: error while loading shared libraries: libvtklz4-8.1.so.1: cannot open shared object file: No such file or directory
-------------------------------------------------------
Primary job terminated normally, but 1 process returned
a non-zero exit code.. Per user-direction, the job has been aborted.
-------------------------------------------------------
--------------------------------------------------------------------------
mpirun detected that one or more processes exited with non-zero status, thus causing
the job to be terminated. The first process to do so was:

Process name: [[30082,1],0]
Exit code: 127
--------------------------------------------------------------------------

It complains about not finding libvtklz4-8.1.so.1, which is located in /usr/local/lib, the exact path specified for VTK_LIB_USR. Can anyone please tell me what I did wrong?

Here is how I installed VTK-8.1.0:
sudo yum remove cmake
sudo yum install cmake3
cd $HOME
wget https://www.vtk.org/files/release/8.1/VTK-8.1.0.tar.gz
tar xzvf VTK-8.1.0.tar.gz
mkdir VTK-build
cd VTK-build
ccmake3 ../VTK-8.1.0
# Within ccmake:
# 1. Type c and wait.
# 2. Set these variables to these values:
# CMAKE_BUILD_TYPE Release
# VTK_Group_MPI ONfoam
# 3. Type c to configure again, and repeat until
# Press [g] to generate and exit
# appears at the bottom of the screen.
# 4. Type g to generate the build scripts and to exit ccmake.
make -j
sudo make install
cd /usr/local/include
sudo ln -s vtk-8.1 vtk

Any help is highly appreciated.

Thanks and best regards,
Richard

j-kerbl's picture

j-kerbl | Thu, 04/19/2018 - 09:28

Hi Richard,

I think /usr/local/lib is not a part of the standard library path, opposed to other Linux distros.
If so, you'll need to add it to the LD_LIBRARY_PATH, so it looks for the libs there.
Add
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/lib
to your .bashrc in front of the CFDEM and OF stuff and reload it. Then it should find the vtk lib.

Cheers,
Josef

rvonlant | Mon, 04/23/2018 - 16:02

Thank you so much, Josef!
I was hoping for a simple solution like this :)
Kind regards,
Richard