Configuring weblogic with Apache 2.x - WebLogic Server - Clustering

Hi All,
We have the following configuration:
Apache Server 2.0.63 with "BEA plug-in build date/time: Dec 11 2006 11:20:55. Change Number: 871803" and Weblogic 10.0.
We have configured the clusters of Apache and Weblogic servers. The Apache works as the failover/load balancer. Our requirement is when none of the Weblogic servers are available, the request should be processed by a standby Tomcat server.
I tried to achieve this using the "ErrorPage" but I'm loosing the actual request sent by the client. In other words I'm not able to get the actual request in Tomcat when I use the "ErrorPage" directive.
So how can I get the actual request from the client in the stand by Tomcat Server?
My weblogic.conf for Apache contains the following entry:
     
<Location /WLTestApp>
SetHandler weblogic-handler
WebLogicCluster server1:7001,server2:7001
ErrorPage /TomcatTestApp/index.jsp
</Location>
     
Thanks in advance,
Regards,
Geo 

I think, the ErrorPage configuration should contain something like this->
ErrorPage http://tomcatserver-ip/index.jsp
Hope this helps
Regards
Ushas Symon

Related

Apache not loading images of Webapp deployed on WLX 10

Hi,
I have deployed a Webapp on Weblogic Express 10 on Linux.
When I call the webapp application by giving Weblogic hostname URL its works perfect.
I have configured Apache Webserver to forward the requests to webapp deployed on WLX 10. When I try to access the application through Webserver communication is happening to Weblogic and it loads the page, but images & gifs are not getting.
Is there anything else I have to set on Apache or Weblogic for this problem.
Please Advice
- - Weblogic Consultant. 
Please post configuration details of plug-in on Apache WebServer. Please state the URL of image as well when you try to access it directly (without plug-in in picture). 
Even I am facing the same problem,
I have a Web application deployed on Weblogic Express 10. When I access the application through App server URL it works fine.
I have configured Apache Webserver to proxy requests to Weblogic, WHen I access the application through Webserver it opens the application but it doesnt load images gif, jpg files. Below is my Apache Webserver Plugin configuration for Weblogic.
<Location />
SetHandler weblogic-handler
WeblogicCluster AppServerHostname:7003
PathPrepend /MyApplication/en/US/enterprise/Mycompany
MaxPostSize -1
WLIOTimeoutSecs 1800
MatchExpression *.jsp
MatchExpression *.html
MatchExpression *.jpeg
MatchExpression *.gif
Debug ON
WLLogFile /tmp/wl.log
DebugConfigInfo ON
KeepAliveEnabled ON
KeepAliveSecs 15
</Location>
Please advice.
- -
Weblogic Consultant 
I did not get any responses to this post.
Any pointers on this issue please.
- -
Weblogic Consultant

How do I disable some requests from going through the apache plugin based on the Location tag

Hi,
I have a non-clustered WebLogic 7.0 setup served by a front-end Apache WebServer with the Apache plugin configured.
I have encountered the problem wherein the Apache plugin does not support requests from WebDAV clients (over HTTP).
The WebDAV server within the cluster is not loadbalanced and hence I can route requests directly to it. But my requirement is that the plugin should not process this request and that Apache directly foward this request across to the Weblogic app server, after a PathTrim.
Is this possible and if so how can I acheive it.
We have a 'VirtualHost' section in the httpd2.conf and the section that is to be bypassed without the plugin looks like the following.
<Location /psp/slide >
SetHandler weblogic-handler
WebLogicCluster 10.1.1.21:7041
Idempotent On
Debug ON
DebugConfigInfo ON
PathTrim "/psp"
WLLogFile "/tmp/log.log"
</Location>
Hi,
You can use apache's mod_rewrite proxy request instead of the plugin, do
something like this:
<Location /psp/slide >
RewriteEngine ON
RewriteRule ^/psp(/slide.*)$ http://10.1.1.21:7041/$1 [P,L]
</Location>
Try this,
"Deepak Andrade" <deepaka#india.hp.com> wrote in message
news:3fd6174a$1#newsgroups.bea.com...
Hi,
I have a non-clustered WebLogic 7.0 setup served by a front-end ApacheWebServer with the Apache plugin configured.
I have encountered the problem wherein the Apache plugin does not supportrequests from WebDAV clients (over HTTP).
The WebDAV server within the cluster is not loadbalanced and hence I canroute requests directly to it. But my requirement is that the plugin should
not process this request and that Apache directly foward this request across
to the Weblogic app server, after a PathTrim.
Is this possible and if so how can I acheive it.
We have a 'VirtualHost' section in the httpd2.conf and the section that isto be bypassed without the plugin looks like the following.
>
<Location /psp/slide >
SetHandler weblogic-handler
WebLogicCluster 10.1.1.21:7041
Idempotent On
Debug ON
DebugConfigInfo ON
PathTrim "/psp"
WLLogFile "/tmp/log.log"
</Location>

Multiple applications: weblogic 6.0 sp1 and apache 1.3.12 proxy

Hi,
We are testing the following setup:
Weblogic 6.0 SP1 running on Solaris 8 (SUN, ip: 192.168.0.1)
Apache 1.3.12 running on Linux (ip: 192.168.0.2)
We have two applications setup on weblogic in the following
directories:
$WL_HOME/config/mydomain/applications/app1 and
$WL_HOME/config/mydomain/applications/app2
The idea is to set up virtual hosts on the apache server and
depending on the url, redirect the client to a specific
application. So for the application app1 we have the following
setup in httpd.conf:
<Files ~ "*.jsp>
SetHandler weblogic-handler
PathPrepend /app1
</Files>
<IfModule mod_weblogic.c>
WebLogicHost 192.168.0.1
WebLogicPort 7001
DebugConfigInfo ON
Debug ALL
</IfModule>
This seems to work fine, e.g. if the client requests a page
http://app1.url.com/index.jsp this gets correctly passed to
weblogic as http://192.168.0.1:7001/app1/index.jsp.
BUT when a jsp page does a response.sendRedirect
(redirectpage.jsp), weblogic tells the client to redirect to
http://app1.url.com/app1/redirectpage.jsp. *Apache* immediately
comes back with an error 404. Is there a way of stripping
the /app1 path from the redirect page that gets sent
to the client?
OR is there a better way of hosting multiple applications on a
server?
This is only a problem when we use sendRedirect.
Any ideas
Thanks
Richard

Weblogic Apache Server Plug-in

Thanks for the one who read that ! I prefer to prevent you, I'm a
novice in Apache and WLS. And I want to make a Weblogic Cluster with
Apache.
I've read the document "Installing the Apache-WebLogic Server Plug-in"
on weblogic.com, but I'm not a gougou.Apache and WLS server are on the
same machine.
I use Weblogic 6.0 SP2 on AIX:
* install directory : /opt/local/bis/wlserver6.0/
* instance 1 : /opt/local/bis/wlserver6.0/config/V32
* ListenPort: 3897
* instance 2 : /opt/local/bis/wlserver6.0/config/V33
* ListenPort: 3899
Apache 1.3.22
* install directory : /usr/local/apache/
* Port: 80
* httpd -l : mod_so.c include and enable-rule=SHARED_CORE
* file /usr/local/apache/libexec/mod_wl.so create with apxs
* The http request for the 2 instances must be http://IPSERVER:80/
I try various and various things in the httpd.conf, but nothing goes
wrong but nothing goes write...did I have to configure the Document
Root,the Directory Directive or/and Aliases, and How to ? Most of the
time, I have a 404 error send by Apache.
Here is what I try in httpd.conf :
ServerRoot "/usr/local/apache"
DocumentRoot "/opt/local/bis/wlserver6.0"
## ALL <Directory> Directives are comment
<IfModule mod_weblogic.c>
WebLogicCluster IPSERVER:3897,IPSERVER:3899
<Location />
SetHandler weblogic-handler
PathTrim /
</Location>
</IfModule>
LoadModule weblogic_module
AddModule mod_weblogic.c
Could you help me to the set the good parametres for httpd.conf ?
Gregory,
A couple of basic questions
1)Can you 'serve up' static content from Apache directly?
2)Can you 'serve up' static content from WLS directly?
3)Can you 'serve up' a JSP from WLS directly?
Once the above is working you probably want to start with a basic proxy by mime
type example (in other words, try to request a JSP page from Apache which in turn
'proxies' the request to the WLS instance) - - once you get that working I would
work on the more complex cluster configuration
See the following link on proxy by mime type for WLS 6.1
http://edocs.bea.com/wls/docs61/adminguide/apache.html#102739
Chuck Nelson
DRE
BEA Technical Support
"Chuck Nelson" <reply#ToNewsgroup.only> wrote in message news:<3d7539c2$1#newsgroups.bea.com>...
Gregory,
A couple of basic questions
1)Can you 'serve up' static content from Apache directly?
2)Can you 'serve up' static content from WLS directly?
3)Can you 'serve up' a JSP from WLS directly?
Once the above is working you probably want to start with a basic proxy by mime
type example (in other words, try to request a JSP page from Apache which in turn
'proxies' the request to the WLS instance) - - once you get that working I would
work on the more complex cluster configuration
See the following link on proxy by mime type for WLS 6.1
http://edocs.bea.com/wls/docs61/adminguide/apache.html#102739
Chuck Nelson
DRE
BEA Technical Support1) test of Apache:
http://IPserver:80/
My Browser list the DocumentRoot, that is to say the
/opt/local/bis/wlserver6.0/ directory
2)3) test of WLS
http://IPserver:3899/
I can see traces of the connexions in
/opt/local/bis/wlserver6.0/config/V33/logs/ and everythings is good.
The index.html page uses is in
/opt/local/bis/wlserver6.0/config/V33/applications/DefaultWebApp_myserver/
The *.jsp pages are in
/opt/local/bis/wlserver6.0/config/V33/applications/frontal/
??)Is my httpd.conf is OK ? DocumentRoot ?
Thanks for your help
Gregory,
The ServerRoot and DocumentRoot entries really shouldn't impact the proper configuration
of the BEA proxy plugin. I would again start with a very simple configuration
and add more complexity given your current familiarity.
Here are the relevant httpd.conf entries that work in our lab environment - -
please ensure that you can access a JSP page directly and then try to access this
via a proxy by mime type entry before moving to the more complex cluster configuration
(Again this is only a httpd.conf fragment that would need to be modified for your
custom environment)
LoadModule weblogic_module /export/home/cnelson/apache/apache/myapache/1.3.
/lib/mod_wl.so
<IfModule mod_weblogic.c>
WebLogicHost 10.62.1.105
MatchExpression /myjsp WebLogicPort=7001|PathTrim=/myjsp
</IfModule>
Chuck Nelson
DRE
BEA Technical Support

Apache-Weblogic plug-in

Hi,
I am using Weblogic server 5.1 and apache 1.3.9.
I am trying to have weblogic JUST act as an application
server and have all HTML be returned by Apache.
So I am trying to use the Apache-Weblogic plug-in and
When I open up a browser window and just simply type:
http://myenterprise.server.com:7001
I get the appropriate page served.
But when I try
http://myenterprise.server.com/weblogic/
Which according to the Apache-Weblogic plug-in
document should also to be translated into the above,
I am getting a 404 error.
I have followed what the documentation is asking.
So, has anyone done that successfully on Solaris2.7?
I would really appreciate any support I can get. I tried
BEA support and am still waiting.
THanks
One of the earlier message posted here helped me with configuration
identical to yours (Solaris 2.7 + WL5.1)
(see Subject: Re: wl5.1 - Apache bridge problem
Date: Wed, 26 Apr 2000 14:34:55 -0500
From: "Christopher Weirup" <cerevis#weirup.com> )
I added this to my httpd.conf and it worked !
Good luck!
Lsh
######################## Paramaters #####################
<IfModule mod_weblogic.c>
WebLogicHost <Your HOST NAME>
WebLogicPort 7001
PathTrim weblogic
<Location /weblogic>
SetHandler weblogic-handler
PathTrim /weblogic
</Location>
</IfModule>
<Location /servletimages>
SetHandler weblogic-handler
PathTrim /weblogic
</Location>
</IfModule>
################## End of Weblogic specific declarations ########
AddModule mod_weblogic.c
samir wrote:
Hi,
I am using Weblogic server 5.1 and apache 1.3.9.
I am trying to have weblogic JUST act as an application
server and have all HTML be returned by Apache.
So I am trying to use the Apache-Weblogic plug-in and
When I open up a browser window and just simply type:
http://myenterprise.server.com:7001
I get the appropriate page served.
But when I try
http://myenterprise.server.com/weblogic/
Which according to the Apache-Weblogic plug-in
document should also to be translated into the above,
I am getting a 404 error.
I have followed what the documentation is asking.
So, has anyone done that successfully on Solaris2.7?
I would really appreciate any support I can get. I tried
BEA support and am still waiting.
THanks

Categories

Resources