views:

513

answers:

1

Hi,

I have openfire installed on my debian server.

I want to know that whether openfire java memory should be less than server memory?

For e.g. i have a server with 256 MB RAM now can i have openfire java memory more than 256 MB RAM or it should be less than 256.

Please help

Thanks, Pankaj

+2  A: 

"Java memory" should definitely be lower, preferably quite a bit lower than available RAM, otherwise your server will start swapping and server performance go down a lot.

A number of things to consider to determine the "right" settings for Java heap space:

  1. what's running on the server? If OpenFire is the only thing running, it can obviously be allowed to reserve more RAM
  2. how much RAM does OpenFire really need? If you give a Java process lots of heap memory, it'll fill it before initiating a garbage collection. If you decrease heap size, it'll just have to collect garbage more often.

It may take some time to find the "ideal" settings, but often it's not useful to just allow the server to take up more memory.

fvu
Hi,Thanks for your reply. I am using this server for bot development so i cannot determine the right settings for java heap space.May be i should increase my server ram or reduce the number of bots as each bot have roster lists which may increase over time.
Pankaj Khurana
At current prices, more RAM is definitely the way to go.
Aaron Digulla
Following the Openfire process's memory consumption over time with a tool like jconsole will allow you to see how it uses memory, and that should quickly give you a rough idea about how much memory it really needs. Just have a look at the graphics jconsole produces, that will make it obvious what I mean.
fvu