Apache-WebLogic Plub-in plugin installation

xiaoxiao2021-03-06  46

When making a large business website, consider the reason for the system burden and improve system security (after all, Apache is a very mature web server), you need to separate WebLogic's HTTP Server, and use Apache Http Server; this requires Apache- WebLogic plugin is implemented. When the client requests a static page, use Apache Server, and when the client requests a dynamic page, the Apache Server uses WebLogic Server through the plugin; for the client, WebLogic Server is invisible, but can be used by plug-ins. All services for WebLogic Server.

At present, WebLogic supports AIX, HPUX11, Solaris, Linux and other operating systems. Under WebLogic / Lib / Linux Directory (Different Operating Systems corresponding to different directories), there is a shared target file mod_wl.so, this file needs to be installed into Apache, So ask Apache to support DSO (Dynamic Shared Object); you can detect your Apache by the following command:

Apache_home / bin / httpd -l

If there is mod_so.c in the module name listed, then your Apache has supported the SO module, otherwise you need to recompile Apache. When compiling Apache, you need to add two parameters:

./configure--enable-module=so--enable-ru =Shared_core

Next is to install the mod_wl.so module, first enter WebLogic / LIB / Linux (assuming your operating system is Linux), install mod_wl.so with the following command:

Perl apache_home / bin / apxs -i -a -n weblogic mod_wl.so

After the above command is executed, you will copy the mod_wl.so file to the Apache_home / libexec directory and automatically add a line in the httpd.conf file:

LoadModule WebLogic_Module Libexec / Mod_wl.so

You can also set the parameters of Apache-WebLogic Plug-in in an apache's httpd.conf file, which are included in

# Parameter

In the middle, the parameters and values ​​cannot be equal sign; the commonly used parameters are:

1, WebLogichost domain name: Set the name of the WebLogic host

2, WebLogicPort port number: Set the port number of the WebLogic host

3, ConnectTimeoutSecs Second number: Set the server connection timeout seconds

4, ErrorPage URL: If the Apache server does not request a WebLogic server, go to the error page you set

If the above parameters are not set, you can also be implemented by a virtual host, and the specific examples are as follows: # loading modules

LoadModule WebLogic_Module Libexec / Mod_wl.so

Positioning directory, this directory must be consistent with the list of placed .jsp files in WebLogic Server

Clearly specify the operator of the WebLogic module

SetHandler WebLogic-Handler If the request page does not exist the returned error page

ErrorPage http://www.weblogic-server.com/error.html

Dynamic file requested by the customer segment can increase

Matchexpression * .jspression * .jsp

Set virtual host

NamevirtualHost 10.1.1.6 #WebLogic Server hostname and port WebLogichost www.weblogic-server.comWebLogicPort 7001 # Connection timeout seconds CONNECTTIMEOMEOUTSECS 30

Now you can start the WebLogic Server and start Apache Server, you can test your JSP:

http://www.weblogic-server.com

转载请注明原文地址:https://www.9cbs.com/read-73478.html

New Post(0)