How to increase openfire memory


Structure of openfire.

  • Windows Server 2008 R2 with 8GB Memory 4 processors Xerox 2.20GB.

  • Openfire 3.9.3

  • Spark 2.6.3

The file “c: \ Program Files (x86) \ Openfire \ bin \ openfired.vmoptions” is defined parameters used for the -Xms512m and -Xmx1536m.

Only due to the growth of users accessing the spark, some users can not log in with the spark, because the “Memory of Java” server reaches 100% usage. Especially in the morning they are all connecting the same time.

I tried to increase the -Xmx “openfired.vmoptions” to 2048M, for example, does not activate the openfire. Occurs the following message: Trhreo rJ VoMc ccEroruued During initialization of VMClodu l nnoott bredse started. The maximum heap size (-Xmx) might be too large or an antivirus or firewall tool Could block the execution.

erve enough space for object heap.

The most that is possible to increase memory is 1536m.

The server is left 6Gb of memory and could not rise to the openfire.

What should I do to solve this problem?



All i know, you probably need to switch to 64-bit Java, but i can’t tell how, i don’t know and i’m not good at this Java memory management stuff. Maybe you can find something related to that searching on this forum or the Internet. Btw, why not using the service option?

I think you can use the following configuration to try

But does not guarantee that this is the best.

-server -Xms6144m -Xmx6144m -XX:PermSize=256m -XX:MaxPermSize=256m -XX:MaxNewSize=512m -Djava.awt.headless=true


I installed java 64 bit and changed the jre folder openfire to get the 64bit java. Only when trying to start openfire is requesting to install the 32bit java or create an environment variable. As a screen attached. I created the environment variable and restarted the server, I tried to start the openfire, still showing the screen attached.

This issue of the openfire memory is generating a big problem in the company, because when it gets to 100% memory, users who are not connecting and tries to connect, fails. Only after restart openfire.

Before the integration with AD, the users were registered in openfire, had no such problem.

I do not know what else to do.


AntonioMensagem de erro ao abrir com java 64bits.JPG


As I understand it, these parameters are inserted in openfired.vmoptions?

If I tried and failed. Is the message below:

The JVM Could Not Be started. The maximum heap size (-Xmx) might be too large or an antivirus or firewall tool Could block the execution.

Invalid maximum heap size: -Xmx6144m

The specified size exceeds the maximum representable size.



How many free memory server currently have?


After several surveys, the problem is the openfire on windows. Even with windows 64bit, the survey, can manage a maximum 1.5gb per process.

So, I prepared another server with Centos Linux and java 64bit. Moved the jre folder / opt / openfire to jre.old and changed the parameter OPENFIRE_OPTS = Xmx4096 which is in the / etc / sysconfig / openfire because it was installed .RPM. Remembering that I left with mysql database.

I test with 6Gb and functioned normally.

In summary: It windows restriction.