Configuring an Apache web server for load balancing and proxying
A system administrator can configure an Apache web server to perform both load balancing and general proxying against a BIRT iHub cluster. Following are the minimum steps necessary to perform this task.
1 Create a cluster using System Console—Clusters.
2 Set up an Apache HTTP server with mod_headers, mod_proxy, mod_proxy_balancer, and mod_proxy_http enabled.
3 Use the following example XML to create an Apache VirtualHost.
<VirtualHost _default_:*>
# required
ProxyRequests Off
ProxyPreserveHost On
 
# add cookie for sticky session
Header add Set-Cookie "IHUB_ROUTE=.%{BALANCER_WORKER_ROUTE}e; path=/" env=BALANCER_ROUTE_CHANGED
# load balancing on 2 internal nodes ("node-01" and "node-02")
<Proxy balancer://ihub/>
BalancerMember http://node-01:8700 route=1
BalancerMember http://node-02:8700 route=2
ProxySet stickysession=IHUB_ROUTE
</Proxy>
 
# do not forward balancer-manager requests
ProxyPass /balancer-manager !
 
# forward all requests to load balancer
ProxyPass / balancer://ihub/
</VirtualHost>
4 Set the cluster URL to the Apache website address by performing the following tasks:
1 On System Console—Clusters, edit the cluster created in step 1 by left‑clicking the icon next to the cluster name.
2 On Cluster Configuration, left-click the icon next to the Cluster Status indicator and choose Edit Cluster Properties, as shown in Figure 7‑69.
Figure 7‑69 Choosing to edit cluster properties
3 On Edit Cluster Properties, type the Apache website address in Cluster URL, for example, http://mywebsite.com, as shown in Figure 7‑70.
Choose OK.
5 Restart the Apache Web server to apply changes, if necessary.
Figure 7‑70 Specifying the Apache website address
6 Restart the cluster by performing the following tasks:
1 On Cluster Configuration, left-click the icon next to the Cluster Status indicator and choose Stop Cluster, as shown in Figure 7‑71.
Figure 7‑71 Stopping the cluster
2 On Cluster Configuration, left-click the icon next to the Cluster Status indicator and choose Refresh. When all the services appear in red, the cluster is stopped. Wait until the cluster is stopped before going to the next step.
3 On Cluster Configuration, left-click the icon next to the Cluster Status indicator and choose Start Cluster, as shown in Figure 7‑72.
Figure 7‑72 Starting the cluster
As an alternative to restarting the cluster from Clusters—Cluster Configuration, you can restart the Actuate PostgreSQL for iHub 3.1 Service on every cluster node in the cluster.
Users can now access BIRT iHub from a web browser using the following URL:
http://mywebsite.com/iportal