Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have found several articles by academics on how to setup JBoss clustering but I would like some opinions from people how have REALLY done it.

First off in every serious article I've come across I have read that you should NEVER use the farm directory in production! As a result we have setup a series of scripts that will copy over a fresh ear to each of the 5 to 10 servers in a cluster via SCP. While this works it does have some time / scaling issues as deployments get bigger. As a result we have started to test setting up NFS mounts. So far in initial testing this seems to work quite well. Has anyone deployed like this before?

The next issue is web session clustering. Currently we deploy a hardware load balancer with sticky session enabled. However we are not replicating session and if a server goes down or is rebooted all users will get a session time out. What is the best way to work around that issue. If possible I would prefer to persist the session data down to the database or to an out of process JVM instance. I have seen rumblings of a technique to save session down to the DB layer but have never been able to get it working. Anyone have this working?

Finally if possible I would like to replace the need for a hardware load balancer at least for smaller deployments with a simple apache server. We have been using the AJP/mod_proxy to work through this but it would appear that mod_cluster may be the way to go in 5.x version of JBoss. Has anyone worked with this in a production setting and can you speak to its stability / performance (

thanks in advance

share|improve this question
Not an answer, but you may be interested to know that we deploy by creating symlinks from our deploy folder to a NAS - it works fine, and allows for quick changing of versions: just change where a symlink points (obviously make sure that JBoss has enough time to realise that an undeploy has happened otherwise it can get confused and not actually do anything) – Rich Feb 21 '11 at 10:27

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.