<freenetproject.org at ...> writes:

> 
> After running Freenet for a while (Actually only 2 weeks this time), I
> sometimes get the exclamation icon in the tray. The last thing in
> freenet.log is:
> 
> Exception in thread "YThread-2184" java.lang.OutOfMemoryError: Java heap
> space

This is not a freenet bug as such, it's caused by it using a lot of memory and
overrunning the default amount that java allocates. IIRC this is about 96MB on
win2k which is a bit stingy these days. So, you need to allow it to have more
(or/and reduce your maxNodeConnections, maximumThreads etc in freeenet.ini to
try to make it use less. CofE reports that the newest JRE [1.5.0_04] seems to
use more memory than previous ones so you could even try downgrading, but I
would tend to recommend against that.)

The way you are supposed to do it in windows is set the memory line in
Flaunch.ini, in the directory where freenet is installed. By default it will
look something like this :

 [Freenet Launcher]
 JavaExec=C:\Program Files\Java\j2re1.4.2_02\bin\java.exe
 Javaw=C:\Program Files\Java\j2re1.4.2_02\bin\javaw.exe
 JavaMem=default
 Priority=0
 PriorityClass=64

Obviously you change the "JavaMem" line, it appears the format is e.g.
"JavaMem=150" to set the maximum to 150MB.

Incidentally, you can in theory increase this limit for all java apps you might
run by going to control panel->java, then to the tab that lets you put in
command line options for the JVM (you may see multiple ones), and adding e.g.
"-Xmx150m". The "default" line in Flaunch.ini probably means to use whatever
this system default is.

Bob



Reply via email to