I am trying to set up a JBoss Cluster with Apache Load Balancing. Basically I have followed the guide from here. No problem faced. The only issue I have would be, how do I access my own application? From the guide, it didnt mention how do I mount my own application.

Here's my environment setup:

  • Windows XP
  • JBoss AS 5.0
  • Apache 2.2.16
  • mod_jk 1.2.30

Here's my properties setting:


Include conf/mod_jk.conf


LoadModule jk_module modules/mod_jk.so

JkWorkersFile conf/workers.properties

JkLogFile logs/mod_jk.log

JkLogLevel info

JkLogStampFormat "[%a %b %d %H:%M:%S %Y]"

JkOptions +ForwardKeySize +ForwardURICompatUnparsed -ForwardDirectories

JkRequestLogFormat "%w %V %T"

JkMount /application/* loadbalancer

JkUnMount /application/images/* loadbalancer

JkMountFile conf/uriworkermap.properties

JkShmFile run/jk.shm

<Location /jkstatus> JkMount status Order deny,allow Deny from all Allow from </Location>







worker.node1.prepost_timeout=10000 #Not required if using ping_mode=A

worker.node1.connect_timeout=10000 #Not required if using ping_mode=A

worker.node1.ping_mode=A #As of mod_jk 1.2.27





worker.node2.prepost_timeout=10000 #Not required if using ping_mode=A

worker.node2.connect_timeout=10000 #Not required if using ping_mode=A

worker.node2.ping_mode=A #As of mod_jk 1.2.27













server.xml in JBoss

<Engine name="jboss.web" defaultHost="localhost" jvmRoute="node1">
<!-- A AJP 1.3 Connector on port 8009 -->
<Connector port="8009" address="${jboss.bind.address}"
  emptySessionPath="true" enableLookups="false" redirectPort="8443" 
  protocol="AJP/1.3" connectionTimeout="600000" maxThreads="200"/>

This is how I start the JBoss


run.bat -c all -g DefaultPartition -u -b -Djboss.messaging.ServerPeerID=1 -Djboss.service.binding.set=ports-default


run.bat -c all -g DefaultPartition -u -b -Djboss.messaging.ServerPeerID=2 -Djboss.service.binding.set=ports-01

My application name is called JBossDB. When i tired to access I am able to launch my application. But if I tried to launch localhost/JBossDB it doesnt load. Note, I am able to launch localhost/admin-console.

I hope I have provided all the necessary info. Please help me out. Thanks

  • In your config, did you actually get jkstatus to work? In mine, I am unable to get the jk status app to work unless it is not load balanced by apache and its a static proxy instead. – djangofan May 10 '11 at 16:14

In your uriworkermap.properties file, it does not appear you have a mapping for /JBossDB

  • Hi, thanks for the reply.. I do the changes.. not too sure if i change it correctly.. i change the /myapp/*=loadbalancer !/myapp/images/*=loadbalancer to /JBossDB/*=loadbalancer !/JBossDB/images/*=loadbalancer But i am still unable to access it. Did i change correctly?? By the way.. under the Apache error log [Thu Sep 23 10:21:21 2010] [error] [client] File does not exist: C:/Program Files/Apache Software Foundation/Apache2.2/htdocs/JBossDB Must i put my application in that folder?? – Nivek Sep 23 '10 at 2:27
  • Hi, I managed to get it working.. Basically if i access by localhost/JBossDB it doesnt work. But if i try localhost/JBossDB/, with an extra back slash at end, it works... No idea y... – Nivek Sep 24 '10 at 0:31

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.