Oracle® Identity Manager Installation and Configuration Guide for JBoss Application Server Release 9.1.0.1 Part Number E14046-03 |
|
|
View PDF |
To set up the Apache Web Server for JBoss Application Server, perform one of the following procedures:
Note:
These instructions are given for reference purpose only. For detailed information about setting up the Apache Web Server for JBoss Application Server, see Apache or JBOSS documentation.Setting Up the Apache Web Server for JBoss Application Server on Microsoft Windows
Setting Up the Apache Web Server for JBoss Application Server on UNIX
To set up the Apache Web server on Microsoft Windows:
See Also:
The Apache Web site for detailed instructionsDownload the latest distribution package for the Apache2 Web server, and then install the Apache server in a directory that this document henceforth refers to as APACHE_HOME.
Download the latest distribution package mod_jk 1.2.x from the Tomcat connector section page on the Tomcat Web site.
Copy the library named mod_jk.so to the APACHE_HOME\modules directory.
Set up Apache to use modjk by adding the following line (and the accompanying comment line) as the last line of the APACHE_HOME
\conf\httpd.conf
file:
# Include mod_jk configuration file
Include conf/mod_jk.conf
In the APACHE_HOME\conf directory, create a configuration file to forward requests to JBoss Application Server instances.
Name this file mod_jk.conf
and copy the following lines into it:
# Load mod_jk module # Specify the filename of the mod_jk lib LoadModule jk_module modules/mod_jk.so # Where to find workers.properties JkWorkersFile conf/workers.properties # Where to put jk logs JkLogFile logs/mod_jk.log # Set the jk log level [debug/error/info] JkLogLevel info # Select the log format JkLogStampFormat "[%a %b %d %H:%M:%S %Y]" # JkOptions indicates to send SSK KEY SIZE JkOptions +ForwardKeySize +ForwardURICompat -ForwardDirectories # JkRequestLogFormat JkRequestLogFormat "%w %V %T" # Mount your applications JkMount /application/* loadbalancer # You can use external file for mount points. # It will be checked for updates each 60 seconds. # The format of the file is: /url=worker # /examples/*=loadbalancer JkMountFile conf/uriworkermap.properties # Add shared memory. # This directive is present with 1.2.10 and # later versions of mod_jk, and is needed for # for load balancing to work properly JkShmFile logs/jk.shm # Add jkstatus for managing runtime data <Location /jkstatus/> JkMount status Order deny,allow Deny from all Allow from all </Location>
Review the directive descriptions given in the following directory on the Apache Tomcat Connector Documentation Index Web site.
Apply the guidelines related to the Apache cache size.
In the APACHE_HOME\conf directory, create a file named workers.properties
and populate it with the following lines:
# Define list of workers that will be used # for mapping requests worker.list=loadbalancer,status # Define Node1 # modify the host as your host IP or DNS name. worker.node1.port=8009 worker.node1.host=IP of node1 worker.node1.type=ajp13 worker.node1.lbfactor=1 # worker.node1.local_worker=1 (1) worker.node1.cachesize=10 # Define Node2 # modify the host as your host IP or DNS name. worker.node2.port=8009 worker.node2.host= IP of node2 worker.node2.type=ajp13 worker.node2.lbfactor=1 # worker.node2.local_worker=1 (1) worker.node2.cachesize=10 # Load-balancing behavior worker.loadbalancer.type=lb worker.loadbalancer.balance_workers=node1,node2 worker.loadbalancer.sticky_session=0 # worker.loadbalancer.local_worker_only=1 # worker.list=loadbalancer
If your JBoss Application Server cluster contains more than two nodes, then you must add extra lines to the workers.properties file in the APACHE_HOME\conf directory.
For example, if you have three nodes, you must add the following lines:
# modify the host as your host IP or DNS name.
worker.node3.port=8009
worker.node3.host= IP of node3
worker.node3.type=ajp13
worker.node3.lbfactor=1
# worker.node3.local_worker=1 (1)
worker.node3.cachesize=10
For each subsequent node, you must add the preceding group of lines again and change all references to node3, node4, node5, and so on.
In the APACHE_HOME\conf directory, create the uriworkermap.properties
file, which will hold the URL mappings Apache forwards to Tomcat.
This file enables mod_jk to forward to Tomcat requests from /mx-console, /web-console, /xlWebApp, /xlScheduler as well as /Nexaweb. The syntax for each line is /url=
worker_name
. Copy the following example into the file you create:
# Simple worker configuration file # Mount the Servlet context to the ajp13 worker /jmx-console=loadbalancer /jmx-console/*=loadbalancer /web-console=loadbalancer /web-console/*=loadbalancer /xlWebApp=loadbalancer /xlWebApp/*=loadbalancer /xlScheduler=loadbalancer /xlScheduler/*=loadbalancer /Nexaweb=loadbalancer /Nexaweb/*=loadbalancer
To start Apache, navigate to the APACHE_HOME\bin directory and then run the Apache.exe file.
To set up the Apache Web server on UNIX:
See Also:
The Apache Web site for detailed instructionsDownload the binary file for Apache 2.0 for UNIX from the Apache Web site.
Run the following commands to install Apache:
tar xvfz httpd-2.0.54.tar.gz
cd httpd-2.0.54
./configure --prefix=/opt/apache2 --enable-module=so
make
make install
Download the jakarta-tomcat-connectors-1.2.14-src.tar.gz
file from the Apache Software Foundation Web site.
Run the following commands to install the connector:
tar xzvf jakarta-tomcat-connectors-1.2.14-src.tar.gz
cd jakarta-tomcat-connectors-1.2.14-src/jk/native
chmod 755 buildconf.sh
./buildconf.sh
./configure --with-apxs=/opt/apache2/bin/apxs
make
make install
cd / jakarta-tomcat-connectors-jk1.2.14-src/jk/native/apache-2.0
/
cp mod_jk.so /opt/apache2/modules/
Perform Steps 4 through 8 in the procedure described in "Setting Up the Apache Web Server for JBoss Application Server on Microsoft Windows".
Navigate to the APACHE_HOME
/bin/
directory, and then run the following command:
./apachectl start