|
[Sponsors] |
[OpenFOAM.org] Error in sourcing OpenFOAM 5.x |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
February 28, 2018, 06:57 |
Error in sourcing OpenFOAM 5.x
|
#1 |
Member
Join Date: Dec 2015
Posts: 74
Rep Power: 11 |
Hello to everyone,
I’m trying to install OpenFOAM 5.x on Centos 6.8. I’m following the instruction in http://openfoamwiki.net/index.php/In...CentOS_SL_RHEL However I get an error when executing the point 8, using the command: Code:
source $HOME/OpenFOAM/OpenFOAM-5.x/etc/bashrc WM_COMPILER_TYPE=ThirdParty WM_COMPILER=Gcc48 WM_MPLIB=OPENMPI FOAMY_HEX_MESH=yes Code:
-bash: asdfsd/: No such file or directory -bash: asdfsd/: No such file or directory -bash: _foamSource: command not found -bash: _foamEval: command not found -bash: asdfsd/: No such file or directory -bash: asdfsd/: No such file or directory -bash: asdfsd/: No such file or directory -bash: _foamSource: command not found -bash: _foamSource: command not found -bash: asdfsd/: No such file or directory -bash: _foamSource: command not found -bash: asdfsd/: No such file or directory -bash: _foamSource: command not found -bash: asdfsd/: No such file or directory -bash: _foamSource: command not found -bash: asdfsd/: No such file or directory -bash: _foamSource: command not found -bash: asdfsd/: No such file or directory -bash: asdfsd/: No such file or directory -bash: asdfsd/: No such file or directory -bash: asdfsd/: No such file or directory -bash: asdfsd/: No such file or directory Code:
OpenFoam-5.x/: No such file or directory How can I fix this error? Thanks, WhiteW |
|
February 28, 2018, 18:20 |
|
#2 |
Retired Super Moderator
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,981
Blog Entries: 45
Rep Power: 128 |
Quick questions:
For example, the following path cannot be used due to the spaces in two of these folders: Code:
/home/Bruno Santos/My CFD Software/OpenFOAM
__________________
|
|
March 1, 2018, 04:01 |
|
#3 |
Member
Join Date: Dec 2015
Posts: 74
Rep Power: 11 |
Hi Bruno, thanks for your reply.
The complete path of the folder is: Code:
/home/wissam/OpenFOAM/asdfsd Code:
/home/wissam/OpenFOAM/OpenFOAM-5.x I tried to edit the OpenFOAM bashrc; if I add after the definition of WM_PROJECT_INST_DIR: Code:
echo $WM_PROJECT_INST_DIR Code:
asdfsd/ OpenFOAM-5.x/ ThirdParty-5.x/ /home/wissam/OpenFOAM However when OpenFOAM is compiled, again, the same error appears when I run a solver. Any idea? Thanks, WhiteW |
|
March 4, 2018, 11:00 |
|
#4 |
Member
Join Date: Dec 2015
Posts: 74
Rep Power: 11 |
I also tried to change the name of OpenFOAM folder, avoinding the '.' and the '-' however, nothing works.
|
|
March 4, 2018, 16:33 |
|
#5 |
Retired Super Moderator
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,981
Blog Entries: 45
Rep Power: 128 |
Quick answer: Something very wrong is going on. Try the following steps:
__________________
|
|
March 5, 2018, 05:45 |
|
#6 |
Member
Join Date: Dec 2015
Posts: 74
Rep Power: 11 |
Hi Bruno,
with respect the online procedure I did this: - when I run "git clone" comand I get the error: Code:
git clone https://github.com/OpenFOAM/OpenFOAM-5.x.git Cloning into 'OpenFOAM-5.x'... error: SSL connect error while accessing https://github.com/OpenFOAM/OpenFOAM-5.x.git/info/refs?service=git-upload-pack fatal: HTTP request failed - I used the option "--no-check-certificate" on the wget comands - when downloading CGAL I get the error about a too long file name so, I used the comand Code:
wget -O download/CGAL-4.10.tar.xz https://github.com/CGAL/cgal/releases/download/releases%2FCGAL-4.10/CGAL-4.10.tar.xz --no-check-certificate Now I did everything in a new user (fermat) in my Centos machine. My new bashrc, now does not contain any reference to OpenFOAM. When I run your point 4: Code:
export | grep -i -e OpenFOAM -e foam Code:
declare -x PWD="/home/fermat/OpenFOAM" Code:
declare -x FOAM_INST_DIR="altro/ OpenFOAM-5.x/ /home/fermat/OpenFOAM" declare -x FOAM_SETTINGS="WM_COMPILER_TYPE=ThirdParty WM_COMPILER=Gcc48 WM_MPLIB=OPENMPI FOAMY_HEX_MESH=yes" declare -x FOAM_SIGFPE="" declare -x PWD="/home/fermat/OpenFOAM" declare -x WM_PROJECT="OpenFOAM" OpenFOAM-5.x/ /home/fermat/OpenFOAM/OpenFOAM-5.x" OpenFOAM-5.x/ /home/fermat/OpenFOAM" declare -x WM_PROJECT_USER_DIR="/home/fermat/OpenFOAM/fermat-5.x" OpenFOAM-5.x/ /home/fermat/OpenFOAM/ThirdParty-5.x" Thanks, WhiteW |
|
March 5, 2018, 19:45 |
|
#7 |
Retired Super Moderator
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,981
Blog Entries: 45
Rep Power: 128 |
Quick answer: I don't know what's happening exactly, but for whatever reason, the environment variable "FOAM_INST_DIR" is being defined in a very weird way.
Please edit the file "OpenFOAM-5.x/etc/bashrc", then look for the following lines: Code:
[ "$BASH" -o "$ZSH_NAME" ] && \ export FOAM_INST_DIR=$(cd $(dirname ${BASH_SOURCE:-$0})/../.. && pwd -P) || \ export FOAM_INST_DIR=$HOME/$WM_PROJECT Code:
# [ "$BASH" -o "$ZSH_NAME" ] && \ # export FOAM_INST_DIR=$(cd $(dirname ${BASH_SOURCE:-$0})/../.. && pwd -P) || \ export FOAM_INST_DIR=$HOME/$WM_PROJECT Then start a new terminal and try running the source command once again (the one from step #5 on my previous post). Then check again what export + grep gives you (step #4). As for the problems with downloading CGAL, that error message is really strange... you can download the file manually on your browser, by using the link that starts with https, namely: Code:
https://github.com/CGAL/cgal/releases/download/releases%2FCGAL-4.10/CGAL-4.10.tar.xz
__________________
|
|
March 6, 2018, 05:46 |
|
#8 |
Member
Join Date: Dec 2015
Posts: 74
Rep Power: 11 |
Hi Bruno,
I edited the OpenFOAM bashrc, then I run the source without problem, only the following warning: Code:
Warning in /home/fermat/OpenFOAM/OpenFOAM-5.x/etc/config.sh/settings: Cannot find /home/fermat/OpenFOAM/ThirdParty-5.x/platforms/linux64/gcc-4.8.5 installation. Please install this compiler version or if you wish to use the system compiler, change the 'WM_COMPILER_TYPE' setting to 'system' Code:
declare -x BOOST_ARCH_PATH="/home/fermat/OpenFOAM/ThirdParty-5.x/platforms/linux64Gcc48/boost_1_55_0" declare -x CGAL_ARCH_PATH="/home/fermat/OpenFOAM/ThirdParty-5.x/platforms/linux64Gcc48/CGAL-4.10" declare -x FOAMY_HEX_MESH="yes" declare -x FOAM_APP="/home/fermat/OpenFOAM/OpenFOAM-5.x/applications" declare -x FOAM_APPBIN="/home/fermat/OpenFOAM/OpenFOAM-5.x/platforms/linux64Gcc48DPInt32Opt/bin" declare -x FOAM_ETC="/home/fermat/OpenFOAM/OpenFOAM-5.x/etc" declare -x FOAM_EXT_LIBBIN="/home/fermat/OpenFOAM/ThirdParty-5.x/platforms/linux64Gcc48DPInt32/lib" declare -x FOAM_INST_DIR="/home/fermat/OpenFOAM" declare -x FOAM_JOB_DIR="/home/fermat/OpenFOAM/jobControl" declare -x FOAM_LIBBIN="/home/fermat/OpenFOAM/OpenFOAM-5.x/platforms/linux64Gcc48DPInt32Opt/lib" declare -x FOAM_MPI="openmpi-2.1.1" declare -x FOAM_RUN="/home/fermat/OpenFOAM/fermat-5.x/run" declare -x FOAM_SETTINGS="WM_COMPILER_TYPE=ThirdParty WM_COMPILER=Gcc48 WM_MPLIB=OPENMPI FOAMY_HEX_MESH=yes" declare -x FOAM_SIGFPE="" declare -x FOAM_SITE_APPBIN="/home/fermat/OpenFOAM/site/5.x/platforms/linux64Gcc48DPInt32Opt/bin" declare -x FOAM_SITE_LIBBIN="/home/fermat/OpenFOAM/site/5.x/platforms/linux64Gcc48DPInt32Opt/lib" declare -x FOAM_SOLVERS="/home/fermat/OpenFOAM/OpenFOAM-5.x/applications/solvers" declare -x FOAM_SRC="/home/fermat/OpenFOAM/OpenFOAM-5.x/src" declare -x FOAM_TUTORIALS="/home/fermat/OpenFOAM/OpenFOAM-5.x/tutorials" declare -x FOAM_USER_APPBIN="/home/fermat/OpenFOAM/fermat-5.x/platforms/linux64Gcc48DPInt32Opt/bin" declare -x FOAM_USER_LIBBIN="/home/fermat/OpenFOAM/fermat-5.x/platforms/linux64Gcc48DPInt32Opt/lib" declare -x FOAM_UTILITIES="/home/fermat/OpenFOAM/OpenFOAM-5.x/applications/utilities" declare -x GMP_ARCH_PATH="/home/fermat/OpenFOAM/ThirdParty-5.x/platforms/linux64/gmp-5.1.2" declare -x LD_LIBRARY_PATH="/home/fermat/OpenFOAM/ThirdParty-5.x/platforms/linux64Gcc48/gperftools-svn/lib:/home/fermat/OpenFOAM/ThirdParty-5.x/platforms/linux64Gcc48/ParaView-5.4.0/lib/paraview-5.4:/home/fermat/OpenFOAM/OpenFOAM-5.x/platforms/linux64Gcc48DPInt32Opt/lib/openmpi-2.1.1:/home/fermat/OpenFOAM/ThirdParty-5.x/platforms/linux64Gcc48DPInt32/lib/openmpi-2.1.1:/home/fermat/OpenFOAM/ThirdParty-5.x/platforms/linux64Gcc48/openmpi-2.1.1/lib:/home/fermat/OpenFOAM/ThirdParty-5.x/platforms/linux64Gcc48/openmpi-2.1.1/lib64:/home/fermat/OpenFOAM/ThirdParty-5.x/platforms/linux64/mpc-1.0.1/lib64:/home/fermat/OpenFOAM/ThirdParty-5.x/platforms/linux64/mpfr-3.1.2/lib64:/home/fermat/OpenFOAM/ThirdParty-5.x/platforms/linux64/gmp-5.1.2/lib64:/home/fermat/OpenFOAM/ThirdParty-5.x/platforms/linux64/gcc-4.8.5/lib64:/home/fermat/OpenFOAM/fermat-5.x/platforms/linux64Gcc48DPInt32Opt/lib:/home/fermat/OpenFOAM/site/5.x/platforms/linux64Gcc48DPInt32Opt/lib:/home/fermat/OpenFOAM/OpenFOAM-5.x/platforms/linux64Gcc48DPInt32Opt/lib:/home/fermat/OpenFOAM/ThirdParty-5.x/platforms/linux64Gcc48DPInt32/lib:/home/fermat/OpenFOAM/OpenFOAM-5.x/platforms/linux64Gcc48DPInt32Opt/lib/dummy" declare -x MANPATH="/home/fermat/OpenFOAM/ThirdParty-5.x/platforms/linux64Gcc48/openmpi-2.1.1/share/man:/home/fermat/OpenFOAM/ThirdParty-5.x/platforms/linux64/gcc-4.8.5/man:/usr/share/man:" declare -x MPFR_ARCH_PATH="/home/fermat/OpenFOAM/ThirdParty-5.x/platforms/linux64/mpfr-3.1.2" declare -x MPI_ARCH_PATH="/home/fermat/OpenFOAM/ThirdParty-5.x/platforms/linux64Gcc48/openmpi-2.1.1" declare -x OPAL_PREFIX="/home/fermat/OpenFOAM/ThirdParty-5.x/platforms/linux64Gcc48/openmpi-2.1.1" declare -x PATH="/home/fermat/OpenFOAM/ThirdParty-5.x/platforms/linux64Gcc48/gperftools-svn/bin:/home/fermat/OpenFOAM/ThirdParty-5.x/platforms/linux64Gcc48/ParaView-5.4.0/bin:/home/fermat/OpenFOAM/ThirdParty-5.x/platforms/linux64Gcc48/openmpi-2.1.1/bin:/home/fermat/OpenFOAM/ThirdParty-5.x/platforms/linux64/gcc-4.8.5/bin:/home/fermat/OpenFOAM/fermat-5.x/platforms/linux64Gcc48DPInt32Opt/bin:/home/fermat/OpenFOAM/site/5.x/platforms/linux64Gcc48DPInt32Opt/bin:/home/fermat/OpenFOAM/OpenFOAM-5.x/platforms/linux64Gcc48DPInt32Opt/bin:/home/fermat/OpenFOAM/OpenFOAM-5.x/bin:/home/fermat/OpenFOAM/OpenFOAM-5.x/wmake:/opt/CD-adapco/11.06.010-R8/STAR-View+11.06.010/bin:/opt/CD-adapco/11.06.010-R8/STAR-CCM+11.06.010-R8/star/bin:/opt/shared/CD-adapco/STAR-View+10.04.011:/opt/shared/CD-adapco/STAR-CCM+10.04.011-R8/star/bin:/opt/torque413/sbin:/opt/torque413/bin:/opt/maui33/bin:/opt/maui33/sbin:/usr/lib64/qt-3.3/bin:/usr/local/bin:/bin:/usr/bin:/usr/local/sbin:/usr/sbin:/sbin:/opt/ofed154/bin:/opt/ofed154/sbin:/home/fermat/bin" declare -x PV_PLUGIN_PATH="/home/fermat/OpenFOAM/OpenFOAM-5.x/platforms/linux64Gcc48DPInt32Opt/lib/paraview-5.4" declare -x PWD="/home/fermat/OpenFOAM" declare -x ParaView_DIR="/home/fermat/OpenFOAM/ThirdParty-5.x/platforms/linux64Gcc48/ParaView-5.4.0" declare -x ParaView_INCLUDE_DIR="/home/fermat/OpenFOAM/ThirdParty-5.x/platforms/linux64Gcc48/ParaView-5.4.0/include/paraview-5.4" declare -x WM_DIR="/home/fermat/OpenFOAM/OpenFOAM-5.x/wmake" declare -x WM_PROJECT="OpenFOAM" declare -x WM_PROJECT_DIR="/home/fermat/OpenFOAM/OpenFOAM-5.x" declare -x WM_PROJECT_INST_DIR="/home/fermat/OpenFOAM" declare -x WM_PROJECT_USER_DIR="/home/fermat/OpenFOAM/fermat-5.x" declare -x WM_THIRD_PARTY_DIR="/home/fermat/OpenFOAM/ThirdParty-5.x" |
|
March 6, 2018, 17:02 |
|
#9 |
Retired Super Moderator
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,981
Blog Entries: 45
Rep Power: 128 |
OK, then now it's finally working as intended... even if it doesn't look like it.
Now you are meant to continue from step #9 on section "CentOS 6.9" on this page: https://openfoamwiki.net/index.php/I...HEL#CentOS_6.9 However, since you are having problems downloading files, you will need to download manually the following files: Code:
http://ftpmirror.gnu.org/gmp/gmp-5.0.1.tar.bz2 http://ftpmirror.gnu.org/mpfr/mpfr-2.4.2.tar.bz2 http://ftpmirror.gnu.org/mpc/mpc-0.8.1.tar.gz http://ftpmirror.gnu.org/gcc/gcc-4.5.1/gcc-4.5.1.tar.bz2 http://ftp.mirrorservice.org/sites/sourceware.org/pub/binutils/releases/binutils-2.23.tar.bz2 Then you can proceed with step #9. |
|
March 6, 2018, 17:14 |
|
#10 |
Member
Join Date: Dec 2015
Posts: 74
Rep Power: 11 |
Hi Bruno,
I finished the installation, now everything works well, also the solvers. Thanks for your help, as usual! WhiteW |
|
April 16, 2018, 23:35 |
|
#11 |
Member
Ali Noaman Ibrahim
Join Date: Sep 2015
Location: US_Chicago
Posts: 97
Rep Power: 11 |
Hi Bruno:-
I have followed all the steps in the link:- http://openfoamwiki.net/index.php/In...CentOS_SL_RHEL However, when reached step 16: -source /opt/rh/python27/enable , I got:- -bash: /opt/rh/python27/enable: No such file or directory Knowing that I could not install python from step 4 since I don't have root access, so what to do? Thanks! |
|
April 17, 2018, 20:41 |
|
#12 | |
Retired Super Moderator
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,981
Blog Entries: 45
Rep Power: 128 |
Quick answer: That is an optional step... Notice that right below the first block of code in step #16.1, is the following sentence:
Quote:
|
||
April 18, 2018, 21:05 |
|
#13 | |
Member
Ali Noaman Ibrahim
Join Date: Sep 2015
Location: US_Chicago
Posts: 97
Rep Power: 11 |
Quote:
Thanks! |
||
April 18, 2018, 21:46 |
|
#14 |
Member
Ali Noaman Ibrahim
Join Date: Sep 2015
Location: US_Chicago
Posts: 97
Rep Power: 11 |
Hi Bruno:-
Unfortunately, when I tried to build up OF(step 18), The mpi is messed up with version 2.2.1 as you could see from the inserted log file. Any idea ? https://drive.google.com/file/d/1AV8...ew?usp=sharing |
|
April 18, 2018, 22:00 |
|
#15 |
Member
Ali Noaman Ibrahim
Join Date: Sep 2015
Location: US_Chicago
Posts: 97
Rep Power: 11 |
I have run :
Code:
./makeGcc gmp-5.1.2 mpfr-3.1.2 mpc-1.0.1 gcc-4.8.5 Code:
make[5]: *** [_gcov_fork.o] Error 1 make[5]: Leaving directory `/home/aibrah8/OpenFOAM/ThirdParty-5.x/build/linux64/gcc-4.8.5/x86_64-unknown-linux-gnu/32/libgcc' make[4]: *** [multi-do] Error 1 make[4]: Leaving directory `/home/aibrah8/OpenFOAM/ThirdParty-5.x/build/linux64/gcc-4.8.5/x86_64-unknown-linux-gnu/libgcc' make[3]: *** [all-multi] Error 2 make[3]: *** Waiting for unfinished jobs.... make[3]: Leaving directory `/home/aibrah8/OpenFOAM/ThirdParty-5.x/build/linux64/gcc-4.8.5/x86_64-unknown-linux-gnu/libgcc' make[2]: *** [all-stage1-target-libgcc] Error 2 make[2]: Leaving directory `/home/aibrah8/OpenFOAM/ThirdParty-5.x/build/linux64/gcc-4.8.5' make[1]: *** [stage1-bubble] Error 2 make[1]: Leaving directory `/home/aibrah8/OpenFOAM/ThirdParty-5.x/build/linux64/gcc-4.8.5' make: *** [all] Error 2 Error building: gcc-4.8.5 Then when I run:- Code:
./getBinutils ./makeBinutils gcc-4.8.5 > log.makeBinutils 2>&1 Code:
gcc-4.8.5 isn't built yet. Fortunately, I resolved it by: Code:
./makeGcc -no-multilib gcc-4.8.5 Last edited by wyldckat; April 22, 2018 at 14:35. Reason: merged consecutive posts and added code markers |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
[OpenFOAM.org] OpenFOAM 5.x (mrklein patch) and macOS High Sierra | podallaire | OpenFOAM Installation | 14 | March 27, 2020 15:45 |
OpenFOAM 5.x: Two conversation issues | bastil | OpenFOAM Running, Solving & CFD | 5 | August 9, 2017 13:56 |
UNIGE February 13th-17th - 2107. OpenFOAM advaced training days | joegi.geo | OpenFOAM Announcements from Other Sources | 0 | October 1, 2016 20:20 |
Installing OpenFOAM 2.1.1 on CentOS 5.x | phuchuynh | OpenFOAM Installation | 1 | October 10, 2012 17:58 |
New OpenFOAM Forum Structure | jola | OpenFOAM | 2 | October 19, 2011 07:55 |