Increase memory for Openfire 3.5.2 Java, on Ubuntu Server 8.04 LTS

Hi all, im a little new to Linux and i seem to have come across a problem with Openfire 3.5.2 running on Ubuntu Server 8.04 LTS.

It seems it has run out of memory and requires a higher amount to be set in the variables someplace.

I do not know the location of Openfire but i do know that the executable is located @ /etc/init.d/openfire Im still getting used to the directory structures that Linux uses, what a pain it has become. The actual Openfire System says : Server Directory- /opt/openfire

Can someone tell me what file to edit so that i can change the default value for Java from 64MB to say 4GB which would leave me about 16GB left which should be sufficent.

One last thing, could you also include the variable name.

Many thanks to anyone who can help.


sudo vi /etc/default/openfire

Inside the file, you change this line:

DAEMON_OPTS="-Xms256m -Xmx734m"

In this example, your server increase its java memory to 734 mb.

Save the file.

Stop/Start openfire

sudo /etc/init.d/openfire stop

sudo /etc/init.d/openfire start


I do not have a directory in /etc called default or /openfire

The only locations i can find for it are:



The server says the directory is:

Server Directory:

Ive looked at the file openfire and have not found the variable called : DAEMON_OPTS

Can you tell me what the command is in vi to search for text ? All i know is ctrl+c and shift+i and shift zz lol


In “vi” you have to look up with esc + / + searched string.

I have Ubuntu Desktop 8.04 LTS.


So no solution? I don’t think openfire creates a folder/file /etc/default/openfire when installed from source. I used to run openfire on Fedora from RPM and I think it had /etc/default/openfire. How would we increase the memory in Ubuntu?



Nevermind, I found the answer buried in another thread…

Thank you to Coolcat for posting in this thread:

Open file ‘/opt/openfire/bin/openfire’ and ad the following line. This will extends your memory from 64 to 128 MB.

INSTALL4J_ADD_VM_PARAMS="-Xms128m -Xmx128m"

Save the file then issue /etc/init.d/openfire restart

Your memory should now show 128MB



How about in Openfire 3.6.0?

The file scheme as changed a little, now it runs from a .sh.

Does anyone already tried?

On our Fedora System we use the file “/etc/sysconfig/openfire”. On line 23 is Variable where you can add your JVM options, dont forget to uncomment the Line. Running OF 3.5.2, dont think it has changed on 3.6.0 though.