[Thread Prev][Thread Next][Index]

Re: [ferret_users] memory usage creeping up



Hi Jean,

Once Ferret quits, it is not possible for the program to keep memory reserved.  You can use the Linux command "ps -fu <username>" (where <username> is you username on the machine) to display all processes you are running if you want to verify Ferret is no longer around.  If there is still a ferret process running when you think you have exited all of them, you can use the Linux kill command to kill the runaway process (using the PID given in the ps command). 

Linux (like most operating systems) does cache data read from disk, so what you may be noticing is the data from your data sets that you use being held in cache memory.  However, if Linux needs more memory for some process, it will delete the oldest cached data and use that memory.  So you will never get an out-of-memory error message just because a large amount of your memory happens to be used for caching data.  You did not indicate whether you were getting an errors because of the memory usage.

Another thing to note with Ferret is the cancel data and cancel memory Ferret commands will not return memory to the operating system (one exception: when using string arrays - see below).  Only changing the size given with the set memory Ferret command will do that. 

If you are using string arrays, the memory for the strings are allocated separately from system memory, so cancelling string arrays will return memory to the system.  But use of string arrays is very rare.

Regards,
Karl



On Tue, Jul 9, 2013 at 8:35 AM, jean li <xgeast@xxxxxxxxx> wrote:
Hi All:

I find that the memory usage creeping up after using Ferret. Even if I quit Ferret session, the memory couldn't be released. In my ferret code, I use
cancel data and cancel memory but that doesn't seem to help.   I could process the data with  "set mem/size=1500", but after a few runs, it filled up the memory of a 65G Linux cluster.  The same problem occurred on my Linux (Dell) workstation as well. I am using ferret v6.64 on a 64 bit red hat Linux.

Thanks for your help.

Jean








--
Karl M. Smith, Ph.D.
JISAO Univ. Wash. and TMAP/PMEL NOAA
"The contents of this message are mine personally and do
not necessarily reflect any position of the Government
or the National Oceanic and Atmospheric Administration."

[Thread Prev][Thread Next][Index]
Contact Us
Dept of Commerce / NOAA / OAR / PMEL / Ferret

Privacy Policy | Disclaimer | Accessibility Statement