CFD Online Discussion Forums

CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   OpenFOAM Running, Solving & CFD (http://www.cfd-online.com/Forums/openfoam-solving/)
-   -   OpenFOAM is just using 2GB RAM? (http://www.cfd-online.com/Forums/openfoam-solving/125470-openfoam-just-using-2gb-ram.html)

kornickel October 26, 2013 04:45

OpenFOAM is just using 2GB RAM?
 
Hi everyone,

everytime I'm running a solver in OpenFOAM (simpleFoam, rhoSimpleFoam) it's just using 2GB of my 8GB memory, no matter if I'm running the case in parallel or not. Does anybody know why?
Doesn't OpenFOAM need more memory at all or is there a limitation in my system?

Best regards,

Frank Ubber

wyldckat October 26, 2013 05:12

Greetings Frank,

That's perfectly normal if you are using a 32bit architecture of a Linux Distribution and/or using a 32bit build of OpenFOAM. To confirm each one, run:
Code:

uname -m
echo $WM_OPTIONS

  • If 32bit, it should give you:
    Code:

    i686
    linuxGccDPOpt

  • If 64bit:
    Code:

    x86_64
    linux64GccDPOpt

As for when running in parallel: each parallel application should be able to use 2GB, so in theory you could run 4 applications in parallel, where each one would occupy up to 2GB or RAM.

Best regards,
Bruno

Kaskade October 29, 2013 05:02

How many meshes have you tried? Apart from some overhead running in parallel doesn't need more RAM. Maybe your mesh is just that small/coarse.

kornickel October 29, 2013 14:46

Thanks for your answers! I think wyldckat is right, I tried it with several meshes and I was just wondering. Now I have a case including MRF.

I think it doesn't work because OpenFOAM still can't run MRF cases in parallel, is that right? At least when I run my case in parallel it still uses just 2GB and solving takes much more time than just running in on one server.

Kaskade October 29, 2013 15:11

OpenFOAM can use MRF in parallel. But don't forget to add the AMIs to the nonRotatingPatches, otherwise it won't converge.

64bit Linux is faster than 32 bit Linux by the way. Just in case you aren't using it.

kornickel October 31, 2013 12:45

Thanks, cascade! I don't have AMIs, just normal cyclic patches. Is that what you mean? And it actually does run in parallel, it's just about half as fast as when I run it on one core.
And I also have a 64bit Linux system running so I can't see why it's so slow!?

Kaskade October 31, 2013 13:09

I don't know the name of the setting of the back of my head, but you need to mention the cyclic patches in the decomposeParDict. Otherwise the patches are separated and the amount of communication increases.

I usually set up AMIs for my MRF cases, so I have the option to run transient later on.

Also: run "renumberMesh" before and "mpirun -np *numberofcores* renumberMesh -parallel" after decomposing. Might help, doesn't have to.

How many cores do you have? Are you running Linux native or in a vm?

If your system is 64bit, OpenFOAM is 64bit as well. Did you compile it or install the binaries?

kornickel October 31, 2013 13:18

Wow! That's a lot of useful information, thanks! I never ran a parallel simulation when I used cyclic patches. I did a quick research and found the option "preservePatches (cyclic_left cyclic_right);" in the decomposeParDict. Is that the way I mention these cyclic patches?

My machine has 8 cores (but I'm just going to use 4 of them), I am running OpenFOAM on Ubuntu 12.04 LTS native and I installed OpenFOAM via apt-get install.

Kaskade October 31, 2013 13:24

Yes, "preservePatches" is what I meant.

What command do you use to run the simulation? Is the correct number of cores being used?


All times are GMT -4. The time now is 01:59.