CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > OpenFOAM Native Meshers: snappyHexMesh and Others

running out of memory

Register Blogs Members List Search Today's Posts Mark Forums Read

Reply
 
LinkBack Thread Tools Display Modes
Old   April 6, 2012, 12:48
Default running out of memory
  #1
Senior Member
 
Mihai Pruna
Join Date: Apr 2010
Location: Boston
Posts: 190
Blog Entries: 1
Rep Power: 8
mihaipruna is on a distinguished road
I have an Ubuntu partition with 20GB. I get the "new" error when running a mesh with 4 million cells. I'm not sure what my swap is.
Should I change the partition size of the ubuntu installation?
or is tehre a way to change the swap file size inside Ubuntu?
__________________
Mihai Pruna's Bio
mihaipruna is offline   Reply With Quote

Old   April 12, 2012, 04:25
Default
  #2
Member
 
Join Date: Apr 2012
Location: France
Posts: 72
Rep Power: 6
Rider is on a distinguished road
Hi,

Can you copy your error message here ?
Rider is offline   Reply With Quote

Old   April 12, 2012, 05:14
Default
  #3
Member
 
Join Date: Apr 2012
Location: France
Posts: 72
Rep Power: 6
Rider is on a distinguished road
In my case, I have this error message :

Code:
Shell refinement iteration 9
----------------------------

Marked for refinement due to refinement shells    : 1279182 cells.
Determined cells to refine in = 24.85 s
Selected for internal refinement : 1341362 cells (out of 10902074)
new cannot satisfy memory request.
This does not necessarily mean you have run out of virtual memory.
It could be due to a stack violation caused by e.g. bad use of pointers or an out of date shared library
Abandon
Anybody know if I can do this snappyHexMesh with my computer, or it's "juste" because I don't have enough memory ?

(My configuration : 4 cores at 2,4 GHz ; 6 go of memory and 100 go of disque space)
Rider is offline   Reply With Quote

Old   April 13, 2012, 05:48
Default
  #4
Member
 
Join Date: Apr 2012
Location: France
Posts: 72
Rep Power: 6
Rider is on a distinguished road
I tried to execute the same simulation on another computer and I had this errors message :

Code:
Shell refinement iteration 0
----------------------------

Marked for refinement due to refinement shells    : 5415653 cells.
Determined cells to refine in = 211.29 s
Selected for internal refinement : 5631462 cells (out of 6458511)
Processus arrêté
client@Client:~/Essai_oGrid$
Or, this :

Code:
Shell refinement iteration 0
----------------------------

Marked for refinement due to refinement shells    : 5415539 cells.
Determined cells to refine in = 53.77 s
Selected for internal refinement : 5631340 cells (out of 6458385)
--------------------------------------------------------------------------
mpirun noticed that process rank 6 with PID 3902 on node Client exited on signal 9 (Killed).
--------------------------------------------------------------------------
client@Client:~/Essai_oGrid$
Rider is offline   Reply With Quote

Old   April 15, 2012, 11:30
Default
  #5
Member
 
Join Date: Apr 2012
Location: France
Posts: 72
Rep Power: 6
Rider is on a distinguished road
Any ideas ?
Rider is offline   Reply With Quote

Old   April 16, 2012, 09:53
Default
  #6
Senior Member
 
Join Date: Aug 2010
Location: Groningen, The Netherlands
Posts: 216
Rep Power: 11
colinB is on a distinguished road
Hi,

when I had this error message I usually run out of RAM.

As a rule of thumb one can say that you shouldn't use more than 1 M
cells per 1 GB of RAM (which is the absolute maximum).
In your case I see you have already 10902074 cells
so way too much for your hardware (6 GB of RAM).

The other messages you posted are referring to the same issue.

Hint: limit the maximum number of cells in the sHMD to lets say 5M
in your case or even less (entity: maxGlobalCells in sHMD).
Be aware that the total number of cells might still be more then the number
of cells specified here, for the refinement is aborted after sHM is hitting
the boundary.
E.g. maxGlobalcells set to 1M you have a background mesh of 500k and
due to cutting ut a geometry 50k cells are removed and then first level of
refinement starts and you end up with 950k he continues refinement and in
the next step you might end up with 2 Mio which is twice the number of
what you specified. But then he will stop refinement.

SO: to reach the maximum number of cells your RAM can handle you watch
the last refinement steps in the log of sHM and look for the refinement
level which has less cells then you want to have in total and then you set
maxGlobalcells to a value less than this and hope it was ok.

hope that helps

regards
colinB is offline   Reply With Quote

Old   April 16, 2012, 10:32
Default
  #7
Senior Member
 
Mihai Pruna
Join Date: Apr 2010
Location: Boston
Posts: 190
Blog Entries: 1
Rep Power: 8
mihaipruna is on a distinguished road
Thanks Colin, I figured out I had to increase the swap size and posted the solution here. I also have reduced the areas of refinement based on distance.

http://www.cfd-online.com/Forums/ope...y-crashes.html
__________________
Mihai Pruna's Bio
mihaipruna is offline   Reply With Quote

Old   April 17, 2012, 06:22
Default
  #8
Member
 
Join Date: Apr 2012
Location: France
Posts: 72
Rep Power: 6
Rider is on a distinguished road
Hi,

Quote:
Originally Posted by mihaipruna View Post
Thanks Colin, I figured out I had to increase the swap size and posted the solution here. I also have reduced the areas of refinement based on distance.

http://www.cfd-online.com/Forums/ope...y-crashes.html
I already do this procedure when I had installed OpenFoam. I put 6 Gio of swap for Gio of memory.

Quote:
Originally Posted by colinB View Post
maxGlobalCells in sHMD
You're right ! My maxGlobalCells was too high ...

Quote:
Originally Posted by colinB View Post
hope that helps
Of course !
Rider is offline   Reply With Quote

Old   April 17, 2012, 09:59
Default
  #9
Member
 
Join Date: Apr 2012
Location: France
Posts: 72
Rep Power: 6
Rider is on a distinguished road
"ColinB"

What proportion have you between maxLocalCells and maxGlobalCells ?

For example

maxLocalCells => 1 000 000
maxGlobalCells => 2 000 000
Rider is offline   Reply With Quote

Old   April 18, 2012, 02:24
Default
  #10
Senior Member
 
Join Date: Aug 2010
Location: Groningen, The Netherlands
Posts: 216
Rep Power: 11
colinB is on a distinguished road
As far as I understood this "ratio" is dependant on the number of processors
you are using and the number of cells specified in here (maxLocalCells) is the
number of maxGlobalCells divided by the number of processors.

However I'm not 100% sure.
So usually for mesh generation with 1 core the number is then the same like
maxGlobalCells with 2 cores it is half and so on.
colinB is offline   Reply With Quote

Old   April 18, 2012, 02:42
Default
  #11
Member
 
Join Date: Apr 2012
Location: France
Posts: 72
Rep Power: 6
Rider is on a distinguished road
Ok, Thanks colinB.

I will try this method
Rider is offline   Reply With Quote

Old   March 17, 2014, 16:28
Default
  #12
New Member
 
Andrew Mortimer
Join Date: Oct 2013
Posts: 15
Rep Power: 5
AndrewMortimer is on a distinguished road
Quote:
Originally Posted by colinB View Post
As far as I understood this "ratio" is dependant on the number of processors
you are using and the number of cells specified in here (maxLocalCells) is the
number of maxGlobalCells divided by the number of processors.

However I'm not 100% sure.
So usually for mesh generation with 1 core the number is then the same like
maxGlobalCells with 2 cores it is half and so on.
I understand this is bringing up a slightly old topic, my meshing keeps crashing when I edit the maxGlobalCells only.

What is the way to work out this ratio?
AndrewMortimer is offline   Reply With Quote

Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Problem in Memory by running blockMesh mamaly60 OpenFOAM Running, Solving & CFD 5 August 11, 2016 15:27
running out of memory in Gambit, Help!!! ahmet FLUENT 19 October 5, 2013 06:01
Memory of PC for running fine mesh size sepidecent Hardware 4 August 16, 2011 20:43
Kubuntu uses dash breaks All scripts in tutorials platopus OpenFOAM Bugs 8 April 15, 2008 07:52
CFX CPU time & real time Nick Strantzias CFX 8 July 23, 2006 17:50


All times are GMT -4. The time now is 06:24.