Skip Headers
Oracle® Fusion Middleware Using Web Server 1.1 Plug-Ins with Oracle WebLogic Server
11g Release 1 (10.3.6)

Part Number E16435-05
Go to Documentation Home
Home
Go to Book List
Book List
Go to Table of Contents
Contents
Go to Master Index
Master Index
Go to Feedback page
Contact Us

Go to previous page
Previous
Go to next page
Next
PDF · Mobi · ePub

2 Configuring the mod_wl_ohs Plug-In for Oracle HTTP Server

This chapter describes how to configure mod_wl_ohs, which is the plug-in for proxying requests from Oracle HTTP Server to Oracle WebLogic server. The mod_wl_ohs module is included in the Oracle HTTP Server installation. You need not download and install it separately.

Note:

mod_wl_ohs provides features that are identical to those of the plug-in for Apache HTTP Server.

You can configure mod_wl_ohs either by using Fusion Middleware Control or by editing the mod_wl_ohs.conf configuration file manually.

This chapter contains the following topics:

2.1 Prerequisites for Configuring mod_wl_ohs

Before you begin configuring mod_wl_ohs, do the following:

2.2 Configuring mod_wl_ohs Using Fusion Middleware Control

To configure the mod_wl_ohs module using Fusion Middleware Control, do the following:

  1. Make sure that you have fulfilled the prerequisites listed in Section 2.1.

  2. Select Administration from the Oracle HTTP Server menu.

  3. Select mod_wl_ohs Configuration from the Administration menu. The mod_wl_ohs Configuration page is displayed.

    Server properties screen
    Description of the illustration mod_wl_ohs.gif

  4. Specify the configuration settings as described in the online help, which you can invoke by clicking the help icon on the page.

  5. Review the settings.

    If the settings are correct, click Apply to apply the changes. If the settings are incorrect, or you decide to not apply the changes, click Revert to return to the original settings.

  6. Restart Oracle HTTP Server by selecting Control from the Oracle HTTP Server menu, and then selecting Start Up.

The mod_wl_ohs module configuration is saved and shown on the mod_wl_ohs Configuration page.

2.3 Configuring mod_wl_ohs Manually

You can configure mod_wl_ohs manually by specifying directives in the mod_wl_ohs.conf file.

  1. Make sure that you have fulfilled the prerequisites listed in Section 2.1.

  2. Open the mod_wl_ohs.conf file, which is located in the following directory, in a text editor:

    ORACLE_INSTANCE/config/OHS/component_name
    
  3. Look for the <IfModule weblogic_module> element.

  4. Add directives within the <IfModule weblogic_module> element in the configuration file, as follows:

    Note:

    Oracle recommends that you specify directives within the predefined <IfModule weblogic_module> element.

    If you specify directives outside the predefined <IfModule weblogic_module> element, or in additional <IfModule weblogic_module> elements, or in configuration files other than mod_wl_ohs.conf, the mod_wl_ohs module might work, but the configuration state of the module, as displayed in Fusion Middleware Control, could be inconsistent with the directives specified in the mod_wl_ohs.conf configuration file.

    • To forward requests to an application running on a single Oracle WebLogic Server instance, specify the details of that destination server within a <location> element.

      Syntax:

      <IfModule weblogic_module>
      <Location path>
      SetHandler weblogic-handler
      WebLogicHost host
      WeblogicPort port
      </Location>
      </IfModule>
      

      Example:

      With the following configuration, requests for the /myapplication URI received at the Oracle HTTP Server listen port will be forwarded to /myapplication on the Oracle WebLogic Server with the listen port localhost:7001

      <IfModule weblogic_module>
      <Location /myapp1>
      SetHandler weblogic-handler
      WebLogicHost localhost
      WeblogicPort 7001
      </Location>
      </IfModule>
      
    • To forward requests to an application running on a cluster of Oracle WebLogic Server instances, specify the details of that destination cluster within a new <location> element.

      Syntax:

      <IfModule weblogic_module>
      <Location path>
      SetHandler weblogic-handler
      WebLogicCluster host:port,host:port,...
      </Location>
      </IfModule>
      

      Example:

      With the following configuration, requests for the /myapplication URI received at the Oracle HTTP Server listen port will be forwarded to /myapplication the Oracle WebLogic Server cluster containing the managed servers with the listen ports localhost:8002 and localhost:8003.

      <IfModule weblogic_module>
      <Location /myapp2>
      SetHandler weblogic-handler
      WebLogicCluster localhost:8002,localhost:8003
      </Location>
      </IfModule>
      
    • To configure multiple destinations—say, an application running on a single Oracle WebLogic Server instance and another application running on a cluster—you must specify each destination in a distinct <location> child element. Note that all the <location> child elements should be at the same level within the <IfModule weblogic_module> element, as shown in the following syntax:

      <IfModule weblogic_module>
      
      #For an application running on a single server instance
      <Location path1>
      SetHandler weblogic-handler
      WebLogicHost host
      WeblogicPort port
      </Location>
      
      #For an application running on a cluster
      <Location path1>
      SetHandler weblogic-handler
      WebLogicCluster host:port,host:port,...
      </Location>
      
      </IfModule>
      

    For information about the other directives that you can specify in the mod_wl_ohs.conf file, see Chapter 7, "Parameters for Web Server Plug-Ins.".

  5. Restart Oracle HTTP Server by using the following command:

    > $ORACLE_INSTANCE/bin/opmnctl startproc ias-component=component_name
    

2.4 Configuring SSL for mod_wl_ohs

For information about configuring mod_wl_ohs to support one-way and two-way SSL between Oracle HTTP Server and Oracle WebLogic Server, see "Enable SSL for Outbound Requests from Oracle HTTP Server" in the Oracle Fusion Middleware Administrator's Guide.