Installation guide

4. Give the worker a unique ident ity
Edit JBOSS_EAP_DIST/jboss-as/server/PROFILE/deploy/jbossweb.sar/server.xml and
add a jvmRoute attribute and value to the Engine element, as shown:
<Engine name="jboss.web" defaultHost="localhost" jvmRoute="worker01">
Use a unique jvmRoute value for each node.
5. Opt ional: Configure firewall t o re ceive multicast Proxy Server advertisements
A proxy server using the JBoss HTT P Connector can advertise itself via UDP multicast. T o enable
the worker node to dynamically discover proxy servers, open port 23364 for UDP connections on
the worker node's firewall.
Use the following command on Red Hat Enterprise Linux to achieve this:
/sbin/iptables -A INPUT -m state --state NEW -m udp -p udp --dport 23364 -j
ACCEPT
-m comment --comment "receive mod_cluster proxy server advertisements"
/sbin/iptables save
If you are not using Automatic Proxy Discovery (see Automatic Proxy Discovery), configure worker
nodes with a static list of proxies. Refer to Section 9.1,Static proxy configuration” for directions. In
this case you can safely ignore the following warning message:
[warning] mod_advertise: ServerAdvertise Address or Port not defined,
Advertise disabled!!!
Important
If your nodes are on different machines that run Red Hat Enterprise Linux, they may not
acknowledge each other automatically. JBoss Clustering relies on the UDP (User Datagram
Protocol) multicasting provided by jGroups. Red Hat Enterprise Linux blocks these packets
by default.
To allow the packets, modify the iptables rules (as root). T he following commands apply to
an IP address that matches 192.168.1.x:
/sbin/iptables -I RH-Firewall-1-INPUT 5 -p udp -d 224.0.1.0/24 -j
ACCEPT
/sbin/iptables -I RH-Firewall-1-INPUT 5 -p udp -d 224.0.0.0/4 -j
ACCEPT
/sbin/iptables -I RH-Firewall-1-INPUT 9 -p udp -s 192.168.1.0/24 -j
ACCEPT
/sbin/iptables -I RH-Firewall-1-INPUT 10 -p tcp -s 192.168.1.0/24 -j
ACCEPT
/etc/init.d/iptables save
Task: Insta ll and Configure a JBoss Enterprise Web Server Worker Node
Follow this procedure to install the JBoss HTT P Connector on a JBoss Enterprise Web Server node and
configure it for non-clustered operation.
Prerequisit es
Install a supported JBoss Enterprise Web Server.
Understand the Proxy Configuration parameters discussed in Appendix B, Reference: Java
properties
1. Deploy worker node service
Copy all of the library files in the JBOSS_EAP_DIST/mod_cluster/JBossWeb-Tomcat/lib
directory. Move these files to JBOSS_EWS_DIST/tomcat6/lib/
2. Add a Listener t o T omcat
Add the following Listener element beneath the other Listener elements in
JBOSS_EWS_DIST/tomcat6/conf/server.xml.
<Listener className="org.jboss.modcluster.ModClusterListener"
advertise="true" stickySession="true" stickySessionForce="false"
stickySessionRemove="true"/>
3. Give this worker a unique ident ity
Edit JBOSS_EWS_DIST/tomcat6/conf/server.xml and add a jvmRoute attribute and value to
the <Engine> element, as shown:
<Engine name="Catalina" defaultHost="localhost" jvmRoute="worker01">
4. Opt ional: Configure firewall t o re ceive Proxy Server a dve rtise ments
JBoss Enterprise Application Platform 5 HTTP Connectors Load Balancing Guide 31