Tim,

The GC just automagically works right?

:)

There's been issues around thread local in Lucene.  The main code for
core management is CoreContainer, which I believe is fairly easy to
digest.  If there's an issue you may find it there.

Jason

2010/2/9 Tim Terlegård <tim.terleg...@gmail.com>:
> If I unload the core and then click "Perform GC" in jconsole nothing
> happens. The 8 GB RAM is still used.
>
> If I load the core again and then run the query with the sort fields,
> then jconsole shows that the memory usage immediately drops to 1 GB
> and then rises to 8 GB again as it caches the stuff.
>
> So my suspicion is that the sort cache still references all these
> objects even after the core is unloaded. But somehow it knows that the
> current sort cache is obsolete. After loading the core again and
> executing the query with sort fields the sort cache references a new
> object and the memory usage drops.
>
> Bug? I could check the source code, but don't know where to look. Any hints?
>
> /Tim
>
> 2010/2/9 Lance Norskog <goks...@gmail.com>:
>> The 'jconsole' program lets you monitor GC operation in real-time.
>>
>> http://java.sun.com/developer/technicalArticles/J2SE/jconsole.html
>>
>> On Mon, Feb 8, 2010 at 8:44 AM, Simon Rosenthal
>> <simon_rosent...@yahoo.com> wrote:
>>> What Garbage Collection parameters is the JVM using ?   the memory will not
>>> always be freed immediately after an event like unloading a core or starting
>>> a new searcher.
>>>
>>> 2010/2/8 Tim Terlegård <tim.terleg...@gmail.com>
>>>
>>>> To me it doesn't look like unloading a Solr Core frees the memory that
>>>> the core has used. Is this how it should be?
>>>>
>>>> I have a big index with 50 million documents. After loading a core it
>>>> takes 300 MB RAM. After a query with a couple of sort fields Solr
>>>> takes about 8 GB RAM. Then I unload (CoreAdminRequest.unloadCore) the
>>>> core. The core is not shown in /solr/ anymore. Solr still takes 8 GB
>>>> RAM. Creating new cores is super slow because I have hardly any memory
>>>> left. Do I need to free the memory explicitly somehow?
>>>>
>>>> /Tim
>>>>
>>>
>>
>>
>>
>> --
>> Lance Norskog
>> goks...@gmail.com
>>
>

Reply via email to