BusinessObjects: Apache Reverse Proxy with MS Clustering
This is my first blog so please be kind 🙂
We recently did a Business Objects 4.2 upgrade from 4.1. This included an OS migration to 2012 and Database upgrade to Oracle 12c.
As part of the upgrade we wanted to introduce reverse proxies for HA in Business Objects. Ideally we also wanted to use a loadbalancer but budget did not allow for this. To get around the load balancer issue and still maximise the HA of the Web tier in Business Objects we used MS Clustering. Before I continue I would like to acknowledge everyone else that has put up blogs on reverse proxies and business objects. Without this I don’t think I would have got this completed.
Diagram of how architecture:
The key to this config is the apache reverse proxy is installed on both nodes. We then create a windows service for each apache reverse proxy. Once this is completed, the apache windows service is put under the control of MS Clustering Service. Included in this service is a client access point. A client access point is a virtual IP address for the host. From an end user perspective, it allows them to use the same URL even if the service is running off a different host.
An example might make this clearer: If Node 1 is accidentally shutdown, the client access point fails over to Node 2, the apache reverse proxy service is also started on Node 2. This means the End users requests are automatically sent to Node2. Obviously anyone that was logged onto node 1 when it was shutdown will be kicked out of the system.
Instructions on how I set this up:
Install Reverse Proxy
Download path https://www.apachelounge.com/download/win64/
Version: Apache 2.4.25 Win64
The link above provides detailed instructions on how to install and configure the apache reverse proxy. I will add the details here on how to configure it for two nodes and then cluster it using Microsoft clustering.
- Extract Apache reverse proxy on both nodes
- Set the server root, document path. script alias and any other directoy paths in httpd.conf for both nodes (Use the same paths on each node for the installation).
- Check syntax is ok with the command: <drive letter>:\Apache24\bin\httpd.exe -t
- Install service on both nodes: <drive letter>:\Apache24\bin\httpd.exe -k install
- Change the service to run under a domain account rather than the local admin account:
- Test that apache works with the urls http://servername
You now have apache running and installed on both servers in the cluster.
The next step is to update the httpd.conf file in \Apache24\conf to forward requests to your Business Objects tomcat servers. Once again the blog https://wiki.scn.sap.com/wiki/display/BOBJ/Installing+Apache+2.4+as+a+service provide full details on how to do this. I will provide you with the config I used and point out the pieces specific the MS clustering.
#Define Reverse Proxy Load Balancer
BalancerMember http://node1.world.net:8080/ max=64 connectiontimeout=1200 keepalive=on route=<client_access_point>
BalancerMember http://node2.world.net:8080/ max=64 connectiontimeout=1200 keepalive=on route=<client_access_point>
#Note for <client_access_point>, this is created down below but the most important thing is ti use the same name for the route on each node and map it to the config in the tomcat servers. More details below
Require host node1.world.net
#You can check the load balancer with the url http://node1.world.net/balancer-manager . The above lines state the hosts it can be run from.
#Define ProxyPass Rules for Reverse Proxy
#AdminTools for Query Builder
ProxyPass balancer://BI4Pattern/AdminTools stickysession=JSESSIONID
ProxyPassReverseCookiePath balancer://BI4Pattern/AdminTools /AdminTools
#BOE access to BI Launch Pad and CMC
ProxyPass balancer://BI4Pattern/BOE stickysession=JSESSIONID
ProxyPassReverseCookiePath balancer://BI4Pattern/BOE /BOE
ProxyPass balancer://BI4Pattern/BusinessProcessBI stickysession=JSESSIONID
ProxyPassReverseCookiePath balancer://BI4Pattern/BusinessProcessBI /BusinessProcessBI
ProxyPass balancer://BI4Pattern/clientapi stickysession=JSESSIONID
ProxyPassReverseCookiePath balancer://BI4Pattern/clientapi /clientapi
#Web Service access
ProxyPass balancer://BI4Pattern/dswsbobje stickysession=JSESSIONID
ProxyPassReverseCookiePath balancer://BI4Pattern/dswsbobje /dswsbobje
ProxyPass balancer://BI4Pattern/MobileBIService stickysession=JSESSIONID
ProxyPassReverseCookiePath balancer://BI4Pattern/MobileBIService /MobileBIService
ProxyPass balancer://BI4Pattern/MOBIServer stickysession=JSESSIONID
ProxyPassReverseCookiePath balancer://BI4Pattern/MOBIServer /MOBIServer
#If you have another URLS add them here.
You now need to Make each of your Business Objects tomcats aware of the apache reverse proxies:
Edit \SAP BusinessObjects\tomcat\conf\server.xml
Edit the line below for you servername:
#Note the client access point server name is the name you use in the config below.
<Engine name=”Catalina” defaultHost=”localhost” jvmRoute=”<route name defined in the httpd.conf file above>”
<Engine name=”Catalina” defaultHost=”localhost” jvmRoute=”wdfbopa”
where wdfbopa is the server name end users use to access Business Objects e.g.:
Repeat the same for each Business Objects tomcat you have installed.
The final Step is to configure the MS Clustering:
Go Start >> Failover Cluster Manager
Right Click on Roles and go to configure Role
Select Generic Service
Select the Apache 2.4 Service
Enter the name for the client access point e.g. wdfbopa and the associated IP address
No storage required so leave all cluster Filesystems un-ticked.
Review details and click next
At this point you need to make further corrections due to a bug:
- Open the role you just created and click on the resources tab
- Select the Apace2.4 Resource , right click and go to properties
- Go to the General tab
- Remove the startup parameters and put a space in.
You are now finished at can test failing over the resources and checking if you can access your application from the reverse proxy.
I hope this blog proves helpful to you but please note I have not gone into detail on the reverse proxy config. You can do a lot more work in regards to security and splitting the static and dynamic content for performance gains. SAP support is limited for the reverse proxy, on a very basic level you need to be able to replicate any issue you get in the Business Objects tomcat before logging a call.