powered by Jive Software

200 users and java memory is full!

Hi all,

We have just rolled out Openfire and Spark in our Organization. We have just got 200 usres and Java memroy is getting filled up to 90%(sometimes more than that). It would be great help if anyone could tell a workaround this problem.Currently we are having 1GB of Java memroy and we are using usres directly from AD.Quick respose is greatly appreciated.

Openfire is filling it’s memory? Or Spark?

Java will eat up a lot of memory, and typically the JVM (java’s magic box) doesn’t like to release memory after it’s been given it to use… I’d say, unless you are actually experiencing a problem such as hardlocking or crashing, then I wouldn’t worry too much.

There are ways to increase the JVM’s memory allocation… you may be interested in this thread: http://community.igniterealtime.org/thread/29618

and this guide: http://community.igniterealtime.org/docs/DOC-1033

Thanks for the reply. The server has actually crashed twice. Kindly help as we have already rolled out for 1000 users. Its only that people have not logged in.

try following this guide’s section called “Heap Settings” – http://community.igniterealtime.org/docs/DOC-1033

instead of the 128MB of max heap memory, try 256, or 512, etc. your environment will differ than others, so experimenting with your settings is the only way to “nail in” a number that you should be at… I think Openfire default is 64MB of heap.

Now… if this is Spark we are talking about… then it’s a different issue. Are you using spark? which version? did you compile it from the SVN Trunk, or download it from the main website?

Thanks for the reply again…

  1. I have made the Java Memroy as 1 GB . But there is no openfire file i can find in bin directory where i can make those changes.
  2. Yes i am using Spark as client and the version is 2.6.3. I have downloaded it from main website
  3. Also i am connecting to the AD of my domain server.

Thanks is advance

See this post (3rd post from the top – by Sixthring) : http://community.igniterealtime.org/thread/29618

You basically need to create a new file in the bin/ directory and this will be read by Openfire when it starts up. Simply setting the system’s JVM heap to 1GB will not allow Openfire to use 1GB… you are setting the max for any java program on the system… not specific applications. By setting the VM opeions for Openfire, it will allow Openfire to use more memory.

once you do that, restart openfire server… then log into the admin page and you should see the Server Information page show the memory increase.

Hi jason,

i did all the settings and now the admin page shows 1 GB. But still the users are 235 and usage goes to 98% many times. once it stopped sending messages. I restarted the server and all stored messages were released later.


hmm… perhaps see what happens if you increase to 1.5GB’s, or 2GB’s. I don’t have an installation that large, but others on the forums do. Perhaps one of them may chime in if they see this thread and advise us on what their memory usage looks like and what settings they use… but, I have a feeling it will be a “per-case issue” meaning only trial-and-error will tell you what the best setting is for your environment…