CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Installation (https://www.cfd-online.com/Forums/openfoam-installation/)
-   -   [OpenFOAM.org] Instructions to install OpenFOAM-2.4.x on CentOS-6.10 (https://www.cfd-online.com/Forums/openfoam-installation/208078-instructions-install-openfoam-2-4-x-centos-6-10-a.html)

redbullah October 8, 2018 13:51

Instructions to install OpenFOAM-2.4.x on CentOS-6.10
 
Hi,
I know there is a guide exists for CentOS-6.6, is it usable on CentOS-6.10?

wyldckat October 8, 2018 14:02

Quick answer: At the start of that section, I wrote sometime ago the following note:
Quote:

The instructions below were tested with CentOS 6.6, but might work with 6.5 or newer versions.
So if they do not work with CentOS 6.10, please let me know.

redbullah October 8, 2018 14:24

Well, first thing is I get this error when I run
Code:

module load openmpi-x86_64 || export PATH=$PATH:/usr/lib64/openmpi/bin
which is said to be safely ignored:

Code:

+(0):ERROR:0: Unable to locate a modulefile for 'openmpi-x86_64'
I also get the error:
Code:

note: 'keypad' is defined in DSO /lib64/libtinfo.so.5 so try adding it to the linker command line
and then run the said commands if I get this. But I am not sure, should I make Cmake again after running that said commands?

Then during make processes in ThirdParty, first error I get is during cmake make:
Code:

...
[ 88%] /opt/rh/devtoolset-2/root/usr/libexec/gcc/x86_64-redhat-linux/4.8.2/ld: CMakeFiles/ccmake.dir/CursesDialog/cmCursesMainForm.cxx.o: undefined reference to symbol 'keypad'
/opt/rh/devtoolset-2/root/usr/libexec/gcc/x86_64-redhat-linux/4.8.2/ld: note: 'keypad' is defined in DSO /lib64/libtinfo.so.5 so try adding it to the linker command line
/lib64/libtinfo.so.5: could not read symbols: Invalid operation
collect2: error: ld returned 1 exit status
make[2]: *** [bin/ccmake] Error 1
make[1]: *** [Source/CMakeFiles/ccmake.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
Building CXX object Source/CMakeFiles/CTestLib.dir/CTest/cmCTestConfigureHandler.cxx.o
...

After that I get other errors but I'll leave them for later since it is the first error that matters, but I can post if you wish.

NOTE: I'm not installing OF to $HOME folder, so I changed all $HOME variables in instructions to wherever I'm installing. But if there are any static $HOME variable used in anything downloaded / wget'ed, they remain unchanged. Just to clarify any related issues.

redbullah October 8, 2018 15:13

Additional question to the previous post: the default installation path of OF-2.4.x is
Code:

$HOME
as far as I know; to change it, changing only the
Code:

foamInstall=$CFD/$WM_PROJECT
variable to
Code:

foamInstall=$WHEREVER/$WM_PROJECT
in the OpenFOAM-2.4.x/etc/bashrc file is sufficient, right? (also changing the instructions accordingly of course)

wyldckat October 8, 2018 16:25

Quick answers:

1. The first error/warning about the openmpi module is normal, because you're possibly installed it just recently, hence it's not yet available to load via module command, unless you start a new terminal.


2. The second error you are getting is because you are not fully following the written instructions. The instructions at https://openfoamwiki.net/index.php/I...HEL#CentOS_6.6 were written and tested to compile a custom GCC 4.8.4 build.

But the error message you are getting is because you are trying to use GCC 4.8.2 from the SCL "devtoolset-2" package. This resulted in you tripping over this bug: https://bugs.openfoam.org/view.php?id=1196

Therefore, if you do not want to compile a custom build of GCC 4.8.4, then you should install and use another "devtoolset-?" package. From the record I have here: https://openfoamwiki.net/index.php/I...tion_.28GCC.29 - the GCC 5.* series is still usable with OpenFOAM 2.4.x.


3. As for installing in another path, you can use the actual path, instead of relying on a variable "$WHEREVER". For example:
Code:

foamInstall=/opt/$WM_PROJECT

redbullah October 8, 2018 17:15

Hi wyldckat, I didn't quite understand what I'm doing wrong, I'm following the instructions line by line. The only error I'm getting in the log.mkgcc log file is
Code:

xgcc: error trying to exec 'cc1': execvp: No such file or directory
in several places. Is this the reason why gcc-4.8.4 is not compiled correctly?
I think I don't have any errors related to the installation location. After applying everything in the instructions, I successfully get the icofoam -help results, but there there are errors also in OpenFOAM's make log file.
Regards.

wyldckat October 8, 2018 17:29

Quick answer: Please package the log files and attach them to your next post, if possible. In the wiki page is mentioned that you can package the files with the following command, e.g.:
Code:

gzip < log.make > log.make.gz

My guess is that GCC 4.8.2 is being loaded automatically in your system, possibly due to a command within your "~/.bashrc" file... or it's loaded automatically by the system, if the administrator made it the default compiler...
The instructions in the wiki page assume that the default GCC version is 4.4.7, if I'm not mistaken.

redbullah October 8, 2018 17:53

Hi,
I wanted to upload all logs and it exceeded the limit, so here I'm sharing a link to Google Drive.

https://drive.google.com/open?id=1Ky...-QcllUeH_nyNFU

Your last message made me think that it might be something with the default settings or the admin, since I have no administrative privileges. My ~/.bashrc file is pretty clean, however gcc --version returns version 4.8.5 for me.

wyldckat October 13, 2018 08:07

Sorry for the delay, but I've only managed to look at the log files now.

So, things are a bit confusing, but the good news is that only the "foamy*Mesh" meshers aren't fully built... and the reason as to why not is really strange.... if you run this command:
Code:

ls -l /cfd/honel/OpenFOAM/ThirdParty-2.4.x/platforms/linux64Gcc48/boost_1_55_0/lib
it should show you that the file "libboost_system.so.1.55.0" should exist, but it was not found while trying to build "libconformalVoronoiMesh.so". If it does exist, then try running Allwmake once again in the OpenFOAM-2.4.x folder, to see if it can now find that file.

Everything else seems to be working just fine.

As for GCC, the log file reports that version 4.8.4 was built successfully.

CMake was not compiled, but whichever version you already have in your system, did the job just fine with CGAL 4.6.

redbullah September 7, 2019 18:18

Quote:

Originally Posted by wyldckat (Post 709903)
Sorry for the delay, but I've only managed to look at the log files now.

So, things are a bit confusing, but the good news is that only the "foamy*Mesh" meshers aren't fully built... and the reason as to why not is really strange.... if you run this command:
Code:

ls -l /cfd/honel/OpenFOAM/ThirdParty-2.4.x/platforms/linux64Gcc48/boost_1_55_0/lib
it should show you that the file "libboost_system.so.1.55.0" should exist, but it was not found while trying to build "libconformalVoronoiMesh.so". If it does exist, then try running Allwmake once again in the OpenFOAM-2.4.x folder, to see if it can now find that file.

Everything else seems to be working just fine.

As for GCC, the log file reports that version 4.8.4 was built successfully.

CMake was not compiled, but whichever version you already have in your system, did the job just fine with CGAL 4.6.

Hello again, yes, as you said, cmake was never compiled. Actually, compilation of cmake is where I get the first error in installation steps. Log file of cmake compilation shows these errors at the end:

Code:

Linking CXX executable ../bin/ccmake
[ 90%] Building CXX object Source/CMakeFiles/CTestLib.dir/CTest/cmCTestCoverageHandler.cxx.o
[ 91%] Building CXX object Source/CMakeFiles/CPackLib.dir/CPack/cmCPackRPMGenerator.cxx.o
[ 91%] Building CXX object Source/CMakeFiles/CTestLib.dir/CTest/cmParseMumpsCoverage.cxx.o
[ 91%] Building CXX object Source/CMakeFiles/CTestLib.dir/CTest/cmParseCacheCoverage.cxx.o
[ 91%] Building CXX object Source/CMakeFiles/CTestLib.dir/CTest/cmParseGTMCoverage.cxx.o
/opt/rh/devtoolset-2/root/usr/libexec/gcc/x86_64-redhat-linux/4.8.2/ld: CMakeFiles/ccmake.dir/CursesDialog/cmCursesMainForm.cxx.o: undefined reference to symbol 'keypad'
/opt/rh/devtoolset-2/root/usr/libexec/gcc/x86_64-redhat-linux/4.8.2/ld: note: 'keypad' is defined in DSO /lib64/libtinfo.so.5 so try adding it to the linker command line
/lib64/libtinfo.so.5: could not read symbols: Invalid operation
collect2: error: ld returned 1 exit status
make[2]: *** [bin/ccmake] Error 1
make[1]: *** [Source/CMakeFiles/ccmake.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
[ 92%] Building CXX object Source/CMakeFiles/CTestLib.dir/CTest/cmParsePHPCoverage.cxx.o
[ 92%] Building CXX object Source/CMakeFiles/CTestLib.dir/CTest/cmCTestEmptyBinaryDirectoryCommand.cxx.o
[ 92%] Building CXX object Source/CMakeFiles/CTestLib.dir/CTest/cmCTestGenericHandler.cxx.o
Linking CXX static library libCPackLib.a
[ 92%] Built target CPackLib
[ 92%] Building CXX object Source/CMakeFiles/CTestLib.dir/CTest/cmCTestHandlerCommand.cxx.o
[ 92%] Building CXX object Source/CMakeFiles/CTestLib.dir/CTest/cmCTestLaunch.cxx.o
[ 93%] Building CXX object Source/CMakeFiles/CTestLib.dir/CTest/cmCTestMemCheckCommand.cxx.o
[ 93%] Building CXX object Source/CMakeFiles/CTestLib.dir/CTest/cmCTestMemCheckHandler.cxx.o
[ 93%] Building CXX object Source/CMakeFiles/CTestLib.dir/CTest/cmCTestMultiProcessHandler.cxx.o
[ 93%] Building CXX object Source/CMakeFiles/CTestLib.dir/CTest/cmCTestReadCustomFilesCommand.cxx.o
[ 94%] Building CXX object Source/CMakeFiles/CTestLib.dir/CTest/cmCTestRunScriptCommand.cxx.o
[ 94%] Building CXX object Source/CMakeFiles/CTestLib.dir/CTest/cmCTestRunTest.cxx.o
[ 94%] Building CXX object Source/CMakeFiles/CTestLib.dir/CTest/cmCTestScriptHandler.cxx.o
[ 94%] Building CXX object Source/CMakeFiles/CTestLib.dir/CTest/cmCTestSleepCommand.cxx.o
[ 94%] Building CXX object Source/CMakeFiles/CTestLib.dir/CTest/cmCTestStartCommand.cxx.o
[ 95%] Building CXX object Source/CMakeFiles/CTestLib.dir/CTest/cmCTestSubmitCommand.cxx.o
[ 95%] Building CXX object Source/CMakeFiles/CTestLib.dir/CTest/cmCTestSubmitHandler.cxx.o
[ 95%] Building CXX object Source/CMakeFiles/CTestLib.dir/CTest/cmCTestTestCommand.cxx.o
[ 95%] Building CXX object Source/CMakeFiles/CTestLib.dir/CTest/cmCTestTestHandler.cxx.o
[ 96%] Building CXX object Source/CMakeFiles/CTestLib.dir/CTest/cmCTestUpdateCommand.cxx.o
[ 96%] Building CXX object Source/CMakeFiles/CTestLib.dir/CTest/cmCTestUpdateHandler.cxx.o
[ 96%] Building CXX object Source/CMakeFiles/CTestLib.dir/CTest/cmCTestUploadCommand.cxx.o
[ 96%] Building CXX object Source/CMakeFiles/CTestLib.dir/CTest/cmCTestUploadHandler.cxx.o
[ 96%] Building CXX object Source/CMakeFiles/CTestLib.dir/CTest/cmCTestVC.cxx.o
[ 97%] Building CXX object Source/CMakeFiles/CTestLib.dir/CTest/cmCTestGlobalVC.cxx.o
[ 97%] Building CXX object Source/CMakeFiles/CTestLib.dir/CTest/cmCTestCVS.cxx.o
[ 97%] Building CXX object Source/CMakeFiles/CTestLib.dir/CTest/cmCTestSVN.cxx.o
[ 97%] Building CXX object Source/CMakeFiles/CTestLib.dir/CTest/cmCTestBZR.cxx.o
[ 97%] Building CXX object Source/CMakeFiles/CTestLib.dir/CTest/cmCTestGIT.cxx.o
[ 98%] Building CXX object Source/CMakeFiles/CTestLib.dir/CTest/cmCTestHG.cxx.o
Linking CXX static library libCTestLib.a
[ 98%] Built target CTestLib
make: *** [all] Error 2
er
real        0m38.327s
user        3m57.085s
sys        0m32.222s
Error building: cmake-2.8.12.1

You said the version I have worked for CGAL, so does that mean I do not have to compile this version of cmake for any other purposes?


All times are GMT -4. The time now is 08:43.