JBoss Enterprise Application Platform 5HTTP Connectors Load Balancing GuideHT T P load-balancing for JBoss Enterprise Application PlatformEdition 5.2.
Part I. Apache Tomcat Connector (mod_jk)10 Part I. Apache Tomcat Connector (mod_jk)
Chapter 1. OverviewApache HTT P server ("Apache") is a well-known web server which can be extended using plug-ins. T heApache Tomcat Connect
Chapter 2. Download and installApache httpd is included in the JBoss Enterprise Web Server binary you download fromhttps://access.redhat.com.mod_jk is
Chapter 3. Configure load balancing using Apache and mod_jkFollow the tasks in this chapter to correctly configure load balancing using Apache and the
# Simple worker configuration file# Mount the Servlet context to the ajp13 worker/jmx-console=loadbalancer/jmx-console/*=loadbalancer/web-console=load
3. Specify the node name by appending the jvmRoute attribute to the <Engine> element in server.xml. T he jvmRoute attribute value is the node
Chapter 4. Troubleshooting and optimizing mod_jkWhile optimizing the configuration in Apache, mod_jk, mod_proxy, mod_cluster and JBoss typicallyresolv
Common Errors"cping/cpong" ErrorsPresents with errors like the following:[info] ajp_handle_cping_cpong::jk_ajp_common.c (865): timeout in re
If this does not resolve the issue, proceed to St ep 2b. Confirm that there is no firewall blocking or dropping the AJP connections.General Performan
b. For Windows, the options need to be added to run.bat, as it does not read run.conf.c. Check boot.log to see the value of the user.dir environment
Legal NoticeCopyright © 2012 Red Hat, Inc.The text of and illustrations in this document are licensed by Red Hat under a Creative CommonsAttribution–
https://access.redhat.com/knowledge/node/19932.5. If Garbage collection is not responsible for the high CPU, use the thread dumpinformation gathered
Part II. JBoss HTTP Connector (mod_cluster)JBoss Enterprise Application Platform 5 HTTP Connectors Load Balancing Guide 21
Chapter 5. OverviewThe JBoss HT TP Connector mod_clust er is a reduced-configuration, intelligent load-balancing solutionfor JBoss Enterprise Applicat
The Proxy Advertisement module, mod_advertise.so, broadcasts the existence of the proxyserver via UDP multicast messages. T he server advertisement me
Chapter 6. Install proxy server componentsRead this chapter to install the JBoss HTT P Connector, mod_cluster, on a JBoss Enterprise WebServer proxy s
<Location $LOCATION> SetHandler mod_cluster-manager Order deny,allow Deny from all Allow from 127.0.0.1</Location>When accessing the $
1Verify that the defined alias corresponds to a worker node's server name.LBstat usRe calT imeDefines the interval in seconds between the proxy c
Advert iseManagerUrlDefines the URL that the worker node should use to send information to the proxy server. Bydefault this directive is not set and n
Chapter 7. Configure basic proxy serverFollow the instructions in this chapter to configure JBoss Enterprise Web Server to use the JBoss HT TPConnecto
<VirtualHost IP_ADDRESS:PORT_NUMBER> <Location /> Order deny,allow Deny from all Allow from PARTIAL_IP_ADDRESS </Loc
AbstractRead this guide to install and configure the supported HTT P connectors for use with JBoss EnterpriseApplication Platform and JBoss Enterprise
Chapter 8. Install node with basic configurationRead this chapter to install the JBoss HTT P Connector on a worker node, and implement basicconfigurat
4. Give the worker a unique ident ityEdit JBOSS_EAP_DIST/jboss-as/server/PROFILE/deploy/jbossweb.sar/server.xml andadd a jvmRoute attribute and val
A proxy server using the JBoss HTT P Connector can advertise itself via UDP multicast. T oreceive these multicast messages, open port 23364 for UDP co
Chapter 9. Advanced configurationRead this chapter to configure advanced features of the JBoss HT TP Connector.9.1. Static proxy configurationServer a
configuration for directions.Understand the Proxy Configuration parameters discussed in Appendix B, Reference: Javaproperties1. Disable dynamic proxy
Chapter 10. Java Properties10.1. Configuration PropertiesThe tables below enumerate the configuration properties available to an application server no
Table 10.2. Proxy Configurat ionAttribut e De fault De script ionstickySession true Indicates whether subsequentrequests for a given sessionshould, if
among jvmRoutes with thesame domain. This is primarilyused in conjunction withpartitioned session replication(e.g. buddy replication).Note: When nodeT
Table 10.3. SSL Configurat ionAttribut e De fault De script ionssl false Shouldconnectionto proxy usea securesocket layer.sslCiphers T he default JSSE
store type.sslTrustStoreProvider System.getProperty("javax.net.ssl.trustStoreProvider") The truststoreprovider.10.1.4. HA Configurat ionAddi
Table of ContentsPreface1. File Name Conventions2. Document Conventions2.1. Typographic Conventions2.2. Pull-quote Conventions2.3. Notes and Warnings3
Chapter 11. Load Metrics11.1. Server-Side Load MetricsA major feature of mod_cluster is the ability to use server-side load metrics to determine how b
<bean name="ActiveSessionsLoadMetric" class="org.jboss.modcluster.load.metric.impl.ActiveSessionsLoadMetric" mode="On Dema
<bean name="SendTrafficLoadMetric" class="org.jboss.modcluster.load.metric.impl.SendTrafficLoadMetric" mode="On Demand&quo
<bean name="HeapMemoryUsageLoadMetric" class="org.jboss.modcluster.load.metric.impl.HeapMemoryUsageLoadMetric" mode="On De
Chapter 12. Load balancing demonstrationThe JBoss HT TP Connector includes a load balancing demonstration to show how different server-sidescenarios a
<context-param> <param-name>service-name</param-name> <param-value>Catalina</param-value> </context-param>4.
Session LifeNumber of seconds a client thread should use a session before invalidating or abandoning it.This should be a small value, or session stick
in something other than a HT TP 200 response.This section shows you how to configure and start using the demo.Task: Interact with t he Demonstrat ionC
per second for a set time.Server Send TrafficGenerates server traffic send load by making a request once per second, to which theserver responds with
Part III. Internet Server API (ISAPI)JBoss Enterprise Application Platform 5 HTTP Connectors Load Balancing Guide 49
14.1. Prerequisites and configuration assumptions14.2. Configure server instance as a worker node14.3. Microsoft IIS 6 initial clustering configuratio
Chapter 13. OverviewRead this chapter for a brief introduction about the Internet Server Application Programming Interface(ISAPI).13.1. What is Intern
Chapter 14. Configuring the ISAPI connector on WindowsRead this chapter to learn how to configure the ISAPI connector to use JBoss Enterprise Applicat
Start → Run , then type inetmgr .Start → Control Panel → Administ rat ive T ools → Int erne t Information Services (IIS)Ma nagerThe IIS 6 Manager w
4. Confirm the jboss Web Service Extension displays in the list.14.4. Microsoft IIS 7 initial clustering configurationMicrosoft IIS 7 can be managed
2. Double-click ISAPI Filters.The ISAPI Filters Features View opens.3. In the Actions pane, click Add.The Add ISAPI Filter window opens.4. Specify
# Configuration file for the ISAPI Redirector# Extension uri definitionextension_uri=/jboss/isapi_redirect.dll# Full path to the log file for the ISAP
C:\> net stop iisadmin /YC:\> net start w3svcIIS 7C:\> net stop was /YC:\> net start w3svc6. Verify the LogsEnsure you check the ISAPI lo
3. Creat e uriworkermap.propertie s fileThe uriworkermap.properties file contains deployed application mapping configurationinformation. Append the f
6. Verify the LogsEnsure you check the ISAPI logs once IIS has restarted. T he logs are saved to the file locationspecified in the log_file property
Part IV. Netscape Server API (NSAPI)JBoss Enterprise Application Platform 5 HTTP Connectors Load Balancing Guide 59
Preface1. File Name ConventionsThe following naming conventions are used in file paths for readability. Each convention is styled so thatit stands out
Chapter 15. What is Netscape Server API?Read this chapter to gain a basic understanding of the Netscape Server API (NSAPI).NSAPI is a programming inte
Chapter 16. Configuring the NSAPI connector on SolarisThe following tasks describe how to configure the NSAPI connector to use a JBoss Enterprise Plat
a different IP address with the -b switch.[user@workstation jboss-eap-5.1]$ ./jboss-as/bin/run.sh -b 127.0.0.1 -c default-01[user@workstation jboss-ea
16.4. Configure a basic cluster with NSAPITask: Configure a Basic Cluster wit h NSAPIComplete this task to configure a basic cluster, where requests
16.5. Configure a load-balanced cluster with NSAPITask: Configure a Load-balanced Cluste r with NSAPIComplete this task to configure a load-balanced
# The advanced router LB workerworker.list=router,status#First EAP server definition, port 8009 is standard port for AJP in EAP##lbfactor defines how
Part V. Common load balancing tasks66 Part V. Common load balancing tasks
Chapter 17. HTTP session state replicationHTT P session state replication is a means of distributing clients' state across multiple servers. T he
<!DOCTYPE jboss-web PUBLIC "-//JBoss//DTD Web Application 5.0//EN" "http://www.jboss.org/j2ee/dtd/jboss-web_5_0.dtd">&
example,. mod_jk, mod_proxy, mod_cluster) is being used for load balancing for this webapplication. If set to true, the container will examine the ses
all distinguishable thanks to context.Key combinations can be distinguished from keycaps by the plus sign that connects each part of a keycombination.
from clustered web applications where the web.xml file includes the distributable directive.Passivation occurs at three points during the life cycle o
GuideThe name of the JBoss Cache configuration to use is controlled by the cacheName element in theapplication's jboss-web.xml (see Section 17.1,
Chapter 18. High-Availability Web SessionsJBoss Enterprise Application Server allows you to make web sessions highly available by storing themin a dat
<Context cookies="true" crossContext="true"> <Manager className="org.jboss.web.tomcat.service.session.persistent.D
connectionPa sswordpassword to pass to DataSource.getConnectionsessionT ablename of the database session table in which sessions are stored (by defaul
replicationT riggerStringactivity executed during a request that makes the session database persistent (the activity withthe replication-trigger prope
Chapter 19. Using clustered Single Sign-on (SSO)JBoss supports clustered single sign-on (SSO), allowing a user to authenticate to one web applicationa
applications will be invalidated.A session timeout does not invalidate the SSO if other sessions are still valid.19.3. LimitationsThere are a number o
Chapter 20. Complete working exampleFollowing are a set of example configuration files for a complete working example.Proxy ServerA proxy server liste
JBoss Enterprise Application Platform 5 HTTP Connectors Load Balancing Guide 79
package org.jboss.book.jca.ex1;import javax.naming.InitialContext;public class ExClient{ public static void main(String args[]) throws Except
Reference: workers.propertiesApache httpd Server worker nodes are Servlet containers that are mapped to the mod_jk load balancer.The worker nodes are
You can specify the port directive as part of the host directive by appending the port numberafter the hostname or IP address. For example: worker.nod
Specifies whether requests for workers with SESSION IDs are routed back to the same worker.The default is 0 (false). When set to 1 (true), load balanc
Reference: Java propertiesRead this appendix to learn about the JBoss HT TP Connector (mod_cluster) configuration propertiesthat apply to either a JBo
returning an error.mod_cluster always uses a CPing/CPong before forwarding a request. T he connectiontimeout value used by mod_cluster is the ping v
Revision historyRevision 5.2.0- 15 18 Sep 2012 Russell DickensonBump to have book re-BrewedRevision 5.2.0- 14 Mon Jul 9 2012 Scot t MumfordJBPAPP-9297
Document URL:Section Number and Name:Describe the issue:Suggestions for improvement:Additional information:Be sure to give us your name so that you ca
Komentáře k této Příručce