powered by Jive Software

High memory usage - how to use 64-bits Java on Windows Server


We’re experiencing some problem with our Openfire/Spark server, running on Windows Server 2008 R2.

The server is running fine for a few days when it suddenly stops.

Looking att the webadmin (not when spark stops working, at that point webadmin doesn’t work either) you can see that the memory slowly increasing upwards from 97% at startup time.

I’ve been reading for ours at the forum but can’t find any answers to my questions.

I’ve understood that you can delegate more memory to 64-bits Java but i can’t figure out how to tell Openfire to use 64-bits instead of 32-bits.

If I just uninstall 32-bits, I get an error message when trying to start the openfire service, saying “…error 1: Incorrect funtion”

I’ve also read that when working in production enviroments you shouldn’t have the embedded DB.

As were using Windows we have som MSSQL servers and in case of moving the database we want to use MSSQL, but i can’t find any guides how to migrate to MSSQL, just MySQL http://community.igniterealtime.org/docs/DOC-1540

So in case of someone out there have any kind of input i would appriciate it ALOT!

Thanks in advance,


Set the system property xmpp.pep.enabled to false and cycle the Openfire server.

If you want to use a 64bit JVM, you need to install a 64bit JRE and set the JAVA_HOME in the Openfire startup scripts to point to the 64bit JRE.

1 Like

Hi David,

That sounds like the deal.

Though, I can’t figure out which file you mean and which value to edit.

The only file i can found that has those variables inside is this:
“C:\Program Files (x86)\Openfire\bin\openfirectl”

There you can find that JAVA_HOME is set to “JAVA_HOME=”${OPENFIRE_HOME}/jre"" and that the OPENFIRE_HOME has two different variables,



But i can’t understand how these values can match our Windows enviroment…

Could you be more specific were to find the file and which values to edit?



I’m not a Windows person, so I’m not 100% sure what you need to change - You at least need to go and download a 64bit JRE from java.sun.com (stick with 1.6). That install should set your JAVA_HOME system variable, so when you start Openfire it will use the new JRE rather than falling back to the installed one.

The config file you mentioned seems to be for UNIX.

That should do the trick, but it isn’t going to fix your problem, simply delay it for a longer period. It looks like you have run into the PEP issue that David already mentioned (it is one of the announcements on the community home page).