How does one set max PermGen size on Windows service-based Openfire

I ran into out of memory on our Openfire 3.3.2 install relating to PermGen space - e.g. -

07.09.07 04:31:58 [org.jivesoftware.openfire.container.PluginManager.loadPlugin(PluginManager.jav a:462)

] Error loading plugin: C:\Program Files\Openfire\plugins\gateway

java.lang.OutOfMemoryError: PermGen space

How do you set the max permgen size paremeter when launching Openfire as a Windows service? I assume that increasing it would give us more overhead and avoid similar errors in the future. (Or does anyone else have other ideas?)

Thanks very much - ATM

Hi,

are you already using the openfired.vmoptions file ( desc. in http://www.igniterealtime.org/builds/openfire/docs/latest/documentation/install- guide.html ) to set Xmx to a high value?

You need to add there the line

-XX:MaxPermSize=96m

and as you need 64 MB you can set the initial PermSize to 64 MB or more:

-XX:PermSize=72m

Did you install a lot of plugins … usually 64 MB are fine. So I hope that 96 MB are fine, but one can set the MaxPermSize to 128m or even to 256m if one needs to.

LG

Thanks - that is excellent!

I believe the issue was caused by an incomplete upgrade of the IM gateway plugin. It was attempting to reload every few seconds and must have filled up some kind of log space or the like. Restarting the server seemed to resolve everything, so I will hold off on manually upping PermGen space unless it happens again and proves to be required.