|
[Sponsors] |
Running openfoam in parallel on local processors |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
July 23, 2018, 14:54 |
Running openfoam in parallel on local processors
|
#1 |
New Member
Jonty Pedersen
Join Date: Jun 2018
Posts: 8
Rep Power: 8 |
Dear Foamers,
Last time I posted a question that I was trying to answer for hours it was solved in a matter of minutes, so fingers crossed this happens again . I am trying to run a simulation in parallel on local processors. All goes well when I run decomposePar, I get 8 new processor directories (processor0 -> processor7) but when I use the command: Code:
mpirun -np 8 buoyantBoussinesqPimpleFoam in the case directory that I want, I get the output Code:
mpirun has detected an attempt to run as root. Running at root is *strongly* discouraged as any mistake (e.g., in defining TMPDIR) or bug can result in catastrophic damage to the OS file system, leaving your system in an unusable state. You can override this protection by adding the --allow-run-as-root option to your cmd line. However, we reiterate our strong advice against doing so - please do so at your own risk. I am running openfoam on ubuntu if that makes any difference. Many thanks in advance! J |
|
July 24, 2018, 05:59 |
|
#2 |
Senior Member
Robert
Join Date: May 2015
Location: Bremen, GER
Posts: 292
Rep Power: 12 |
Hopefully this is the anywer:
Code:
mpirun -np 8 buoyantBoussinesqPimpleFoam -parallel
__________________
If you liked my answer to your question, please consider leaving a "Like" in return |
|
July 24, 2018, 06:48 |
|
#3 | |
New Member
Jonty Pedersen
Join Date: Jun 2018
Posts: 8
Rep Power: 8 |
Quote:
Many thanks trying though! |
||
July 24, 2018, 08:37 |
|
#4 |
Member
Andreas P.
Join Date: May 2017
Posts: 41
Rep Power: 9 |
Are you maybe running the command from a terminal where you are logged in as root?
|
|
July 24, 2018, 11:10 |
|
#5 | |
New Member
Jonty Pedersen
Join Date: Jun 2018
Posts: 8
Rep Power: 8 |
Quote:
Andreas I think you are totally right! I can't use the: Code:
./startOpenFOAM Code:
sudo ./startOpenFOAM Thank you, J |
||
July 24, 2018, 11:38 |
|
#6 |
Member
Andreas P.
Join Date: May 2017
Posts: 41
Rep Power: 9 |
I am not familiar with the "./startOpenFOAM" command.
Typically you just need to source the bashrc-file that is located in the etc/-directory of your OpenFOAM installation. This is done by going into the main directory of your OpenFOAM and then typing "source etc/bashrc". This should also be possible without root rights. Did you maybe install/compile OpenFOAM as a root user and thus only the root user has access to all OpenFOAM files? Maybe check the rights of the startOpenFOAM script by typing "ls -al startOpenFOAM" and have a look who has got execution rights (just google for rights management in linux). |
|
July 24, 2018, 12:46 |
|
#7 |
Member
Cyrille Bonamy
Join Date: Mar 2015
Location: Grenoble, France
Posts: 86
Rep Power: 11 |
it is not a problem if the openfoam installation has been done by root.
But the case that you want run must be yours and not root. So just check the permissions and the owner of the testcase directory. |
|
July 24, 2018, 15:07 |
|
#8 | |
New Member
Jonty Pedersen
Join Date: Jun 2018
Posts: 8
Rep Power: 8 |
Quote:
Thanks again you are a life saver, J |
||
July 24, 2018, 15:08 |
|
#9 |
New Member
Jonty Pedersen
Join Date: Jun 2018
Posts: 8
Rep Power: 8 |
||
March 10, 2019, 16:47 |
|
#10 |
Member
Maries
Join Date: Mar 2010
Location: Coimbatore, India
Posts: 76
Rep Power: 16 |
Hi,
Did you solve this issue? I too have similar issue. Thanks in advance |
|
September 18, 2019, 08:02 |
OF installed via Docker
|
#11 |
New Member
Vincent
Join Date: Aug 2019
Location: Germany
Posts: 14
Rep Power: 7 |
I have the exactly same problem.
I believe this happens, when you have installed OF via Docker. Using the "ls -al startOpenFOAM" command shows, who has the rights to the file. This command "sudo usermod -a -G docker $USER" will add permission to your user to start and navigate Docker. Now you are able to start OpenFOAM (./startOpenFOAM), without using the sudo prefix, but the problem on using the mpirun command remains, as somehow Docker is still starting in the root mode. Does anyone have input on how to fix this? Edit: Couldn't resolve the problem. Went with building OpenFOAM ESI version from source. Last edited by vince_cfd; September 19, 2019 at 04:55. |
|
October 31, 2019, 08:34 |
|
#12 |
New Member
Marina
Join Date: Sep 2019
Posts: 6
Rep Power: 7 |
Hi,
I have the same problem, have anybody found a solution? Thanks in advanced. |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Map of the OpenFOAM Forum - Understanding where to post your questions! | wyldckat | OpenFOAM | 10 | September 2, 2021 06:29 |
pimpleDyMFoam computation randomly stops | babapeti | OpenFOAM Running, Solving & CFD | 5 | January 24, 2018 06:28 |
Explicitly filtered LES | saeedi | Main CFD Forum | 16 | October 14, 2015 12:58 |
Micro Scale Pore, icoFoam | gooya_kabir | OpenFOAM Running, Solving & CFD | 2 | November 2, 2013 14:58 |
Upgraded from Karmic Koala 9.10 to Lucid Lynx10.04.3 | bookie56 | OpenFOAM Installation | 8 | August 13, 2011 05:03 |