|
[Sponsors] |
[Other] Bashrc problem on multiple OpenFOAM versions |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
February 2, 2018, 15:15 |
Bashrc problem on multiple OpenFOAM versions
|
#1 |
New Member
Rolanzo
Join Date: Jan 2016
Location: Texas, USA
Posts: 18
Rep Power: 10 |
Hi everyone,
I really need help on running multiple OpenFOAM versions. I have been using OpenFOAM-3.0.1 for 1.5 year already but mostly only modifying on modifying and creating solvers nothing fancy and it has been working great. At this point, I need to use blockMatrixTools to solve a set of equations so I downloaded foam-extend-3.1 version following below link. http://openfoamwiki.net/index.php/In...oam-extend-3.1 I then added below to .bashrc file Code:
cd ~/foam/foam-extend-3.1 source etc/bashrc echo "alias fe31='source \$HOME/foam/foam-extend-3.1/etc/bashrc'" >> $HOME/.bashrc Code:
alias of30='source \$HOME/OpenFOAM/OpenFOAM-3.0.1/etc/bashrc' http://openfoamwiki.net/index.php/In...with_the_Shell In .bashrc file, this below line already exists, I am not sure if it was me who did this when I started working on OpenFOAM 1.5 year ago or it was originally there. source /opt/openfoam30/etc/bashrc So I deleted this line in .bashrc file then I went back to check my original version (OpenFOAM-3.0.1) ~/OpenFOAM/OpenFOAM-3.0.1 but after I used source etc/bashrc, it shows follow error Code:
bash: /home/myName/foam/OpenFOAM-3.0.1/bin/foamEtcFile: No such file or directory bash: /home/myName/foam/OpenFOAM-3.0.1/bin/foamCleanPath: No such file or directory bash: /home/myName/foam/OpenFOAM-3.0.1/etc/config/settings.sh: No such file or directory Code:
alias of30='source \$HOME/OpenFOAM/OpenFOAM-3.0.1/etc/bashrc' alias fe31='source \$HOME/foam/foam-extend-3.1/etc/bashrc' If I type Code:
ls /opt Code:
openfoam30 paraviewopenfoam44 Code:
bash: /home/myName/foam/OpenFOAM-3.0.1/bin/foamEtcFile: No such file or directory bash: /home/myName/foam/OpenFOAM-3.0.1/bin/foamCleanPath: No such file or directory bash: /home/myName/foam/OpenFOAM-3.0.1/etc/config/settings.sh: No such file or directory bash: /home/myName/foam/OpenFOAM-3.0.1/etc/config/aliases.sh: No such file or directory On of30 if I type Code:
echo $WM_PROJECT_DIR Code:
/home/myName/foam/OpenFOAM-3.0.1 Code:
echo $WM_PROJECT_USER_DIR Code:
/home/myName/foam/myName-3.0.1 I have attached file bash files from etc/bashrc from both OpenFOAM-3.0.1 and extend-3.1 as shown in attached files. I have been trying to find solutions from many sites but have yet to figure out how to fix this problem. Now, I only want my original version (OpenFOAM-3.0.1) to at least work so I can continue to work on something I was working on previously. As for extend-3.1, I also tried to compile some random solver but got the same error as when I tried to compile 3.0.1 version, which is something is missing (no such file or directory). Please kindly advise what part I did wrong or how to fix this problem? Any advices or suggestions would be highly appreciated. Thank you. Rolanzo |
|
February 3, 2018, 11:03 |
|
#2 |
Retired Super Moderator
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,981
Blog Entries: 45
Rep Power: 128 |
Greetings Rolanzo,
The problem seems to be that the instructions that you followed were not clear enough on how the "~/.bashrc" file should be modified. I've updated the instructions on the foam-extend related installation pages at openfoamwiki.net, so that it's clearer that the users are meant to simply run the commands given there, instead of manually editing the ".bashrc" file themselves. Now, in your "~/.bashrc" file, I ask you to:
After this, the following steps should get things up and running again:
Best regards, Bruno
__________________
|
|
February 5, 2018, 00:59 |
|
#3 |
New Member
Rolanzo
Join Date: Jan 2016
Location: Texas, USA
Posts: 18
Rep Power: 10 |
Hi wyldckat, Thank you so much for your response! I am now able to run both OpenFOAM-3.0.1(of30) and foam-extend-3.1 (fe31). However, I still have some problem regarding compiling a solver on foam-extend-3.1. I am trying to build a solver based on blockCoupledScalarTransportFoam. I started by copying an original solver and trying to compile using wmake. But here is what I get after wmake:
Code:
fatal error: fvCFD.H: No such file or directory #include "fvCFD.H" Thank you in advance for your help! |
|
February 5, 2018, 19:31 |
|
#4 |
New Member
Rolanzo
Join Date: Jan 2016
Location: Texas, USA
Posts: 18
Rep Power: 10 |
Today when I turned on my computer to start working. I tried again and when I opened a new terminal and typed fe31 to run extend-3.1. I got an error that I did not get yesterday as below, not sure whats going on.
Code:
modprobe: ERROR: could not insert 'fglrx': No such device Error! Fail to load fglrx kernel module! Maybe you can switch to root user to load kernel module directly modprobe: ERROR: could not insert 'fglrx': No such device Error! Fail to load fglrx kernel module! Maybe you can switch to root user to load kernel module directly modprobe: ERROR: could not insert 'fglrx': No such device Error! Fail to load fglrx kernel module! Maybe you can switch to root user to load kernel module directly Thank you. |
|
March 4, 2018, 16:42 |
|
#5 | |||
Retired Super Moderator
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,981
Blog Entries: 45
Rep Power: 128 |
Quick answers and sorry for the late replies:
Quote:
Either way, the error is because the include path for either "finiteVolume" or "OpenFOAM" is missing. For example, from here: https://github.com/OpenFOAM/OpenFOAM...m/Make/options Quote:
Quote:
It's been a while since you asked, so I don't know if you managed to solve the problem.
__________________
|
||||
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Getting Started with OpenFOAM | wyldckat | OpenFOAM | 26 | June 21, 2024 07:54 |
[Other] Multiple versions of OpenFOAM in one machine? | bussaco8 | OpenFOAM Installation | 1 | June 5, 2018 13:47 |
[Other] Using different MPI types and versions with OpenFOAM | spaceprop | OpenFOAM Installation | 2 | May 28, 2018 04:31 |
OpenFOAM static build on Cray XT5 | asaijo | OpenFOAM Installation | 9 | April 6, 2011 13:21 |
Problem installing OpenFOAM 1.5 installation on RHEL 4. | vwsj84 | OpenFOAM Installation | 4 | April 23, 2009 05:48 |