Sizing

Hello,

I am looking at deploying an Openfire server cluster with a clustered MySQL server as a backend. I am looking at hosting this in on virtual Linux servers.

Are there sizing tools to help estimate the resources that would be required to support a specific configuration?

Question 1

If all of the servers had the 1GB of RAM, and one CPU. How many users could I service?

Question 2

What would the specs be for the Openfire servers if I wanted to have 10,000, 100,000 and 1,000,000 users?

Cheers,

Cameron

while i’ve never deployed that large (several members on the forums have and we’ll have to wait for one of them to chime in) –

I’d think the most used resource will end up being RAM – like with most enterprise applications. That many users concurrently will be a lot of memory overhead for the system to keep track of everything. I’d think CPU would play a role too, but then again, there are web servers running out there with single core’s and still serve up to thousands of visitors – just may take a little longer to respond to requests and such. take this as a grain of salt though until someone with large deployment experience chimes in

Hi Jason,

I assumed so I work with large Symantec solutions. Normally they have good sizing tools to help plan a deployment. That is kind of what I am looking at trying to get here.

Basically, I want to run a “free” service that people can use instead of Skype. I would like to be able to continue to scale larger and larger. I have to find out if it is even doable.

Cheers

Cameron

There is no “sizing” tools for Openfire and i doubt users with such large deployments will chime in, they probably don’t have time to dig through the forums, unless they have a problem As me and Jason don’t have such a big userbase, we can only predict you will need lots of RAM. But not just throw all the RAM onto your server. You have to make Java Virtual Machine tovmake use of it. But there are some limits and i don’t know how to go beyond them. Read about VM heap size here http://www.igniterealtime.org/builds/openfire/docs/latest/documentation/install- guide.html

Default value most probably won’t be enough for you.

On a related note. For some time, since Openfire 3.7.x version i’ve had problem with memory, i think there were and probably still are some memory leaks in the server. So after some time JVM was running out of memory and i had to reboot the server. I have upped heap size to 380 MB and then i had to restart the server only once per month. Last few weeks we’ve been migrating our users to Spark (were using Exodus) and maybe because of new client and how Spark behaves, or because we had more sessions as Exodus was still running along with Spark on PCs, we had a few Openfire freezes. And JVM usage was growing very fast closing to 380 limit. So i have upped heap limit to 780 and… now it runs fine for a week or so, but JVM is only using 110-250 MB and doesn’t go higher Weird. Not sure what was happening before. Now it looks it could run ok longer than a month.

I’m not sure what your timetable is on this project, but you may wish to experiment a little. You’ll likely need some tools to help you guage what’s going on inside the “black box” JVM.

Here’s a good crash course on how java handles memory usage: http://www.juhonkoti.net/2010/10/19/crash-course-to-java-jvm-memory-issues-to-sy sadmins

Also, instead of doing the console messages like in that link, i’d suggest checking into JVisualVM that comes packaged with oracle’s jdk. It’s a free profiler, it’s not as full featured as something like JProfiler, but for being free, there’s some good info to be had. From a profiler you can watch your memory usage, etc, and figure out if you have a bottleneck and should increase memory available to the jvm, etc.

There’s also specialized JVM’s besided oracle’s offering that are designed for massive java programs - may be way overkill – Azule Systems makes bare-metal jvm’s that can scale to terabytes of ram and hundreds of cpu cores, IBM makes a JVM that can run at scale but isn’t bare metal (install on regular linux box), etc. I’m not saying you need something like these to do what you’re doing – just pointing out that there are solutions to scale java softawre to the moon and back if needed.

so basically the point is, you can make this work – it may just take some experimenting and time to understand how java works at scale. good luck! … actually sounds like a fun adventure

I highly recommend do not use a “virtual” server even if you have “dedicated” ressources like ram, cpu etc.

In the past i used to run everythin on several virtual/root servers and tried also different isp. Most of them will limit some ressources needed by openfire to handle a large ammount of users or connections like tcp.buffer, tcp.connenctions.max, km_sizes etc.

If you running a fully dedicated server you do not have this kind of limitation by your isp. Only because of the “physical” hardware you are using.