Script to Stress Openfire


Many people asked for a script to stress openfire when clustering is enabled. The document How to load test Openfire with Clustering? contains a load generation script and explains how to use it. It’s good for stress testing openfire in general and in particular when using clustering.

Any improvement or suggestion is always welcome.


I used 3 different machine to run 3 copies of stress test with 2200 users.

as I put more users I get higher and higher packets/minutes. I see a high of 61290 packers/min.

what is the expected cap?

what is the max. number of users that people run into problem with? (atleast with 3.3.3)

what is the max. people are testing (or expecting) with 3.4.0?


We are still trying to reach the Openfire limit. During the stress test we are running out of clients, so far we could simulate 170,000 users.

Our partial results are the following:

  • Openfire opensource in 1 machine supported 170k connected users that were changing their presence, sending messages and requesting for their VCards. CPU usage was around 30-50% and it consumed 1GB of memory.

  • With 3 cluster nodes, CPU and memory consumptions decreased considerably.

Soon we will post more information about the stress test. We are trying to reach much more users.



Do you generate the users using the usercreation.jar plugin?

How many user do you create each time by the plugin? I been doing 5000 users with 249 in contacts in roster.

I could not come up with a roster number that the plugin is happy with when I try to create 100k users.


I create everything together. Notice that it may take more than 10 hours. For example:

User prefix: user

From index: 1

Total users: 100000

Contacts in roster: 49

Why 49?

Number of users per roster plus one should also be a multiple of total number of users.

That is 100000 mod 50 = 0



I guess I read the error from the usercreatio.jar incorrectly.

it says:

“Number of users per roster should be greater than total numbers of users…”

so I keep trying to get more contacts in roster than the Total users field in the Creation Form!

Anyway, is 49 good enough for testing? most of the users I created have 249 contacts.

Hey blueconsole,

You should try to simulate your requirements or reality. If your users are persons then I doubt that having a roster of 250 contacts is something that people will be able to easily handle. I think that a roster bigger than 100 is already too big for a person to handle unless the client is giving you easy access to the person you want to talk to. Probably a roster of 50 users has a “reasonable” size so that you can easily find the person you want to talk to.

Having said that, if in your installation people will commonly have 250 contacts in their rosters then you should go with that number.


– Gato

I can’t get the link to that script to work - it just says “unauthorized”.

Right. The script is unreachable. Is there a way to get this script? Does it even work if OF doesn’t run in clustering?

can we get this script still…it also says unauthorized for me

can we get this script???

To everyone who can’t access the script, it’s very likely a permissions issue for some reaons. So if a board admin can adjust the file permission to registered users or anonymous that should take care of it.

However it sounds like it’s just a Tsung cluster setup. Which you can get Tsung at Then there is a script available at the tigase site However I am interested also in seeing what this test script is too.

I have moved that doc to a visible space, so it (and all the attachments) should be available for everyone.

Excellent! Thank wroot! Also I was wrong and it’s not a Tsung test. I’m excited to try this one out!

Need some help in resolving following issue while running stress test program(Version 3.6.4)

C:\Program Files\Java\jre6\LoadTestScripts>startup.bat

C:\Program Files\Java\jre6\LoadTestScripts>java -classpath xpp.jar;. OpenfireClu
sterStressTest Software caused connection abort: socket write error
at Method)
at Source)
at Source)
at OpenfireClusterStressTest.send(
at OpenfireClusterStressTest.testMultipleLogin(OpenfireClusterStressTest
at OpenfireClusterStressTest.main(