Oracle 10g release 2 load balancing
Oracle Tips by Burleson Consulting
Oracle 10g release 2 has some exciting
new features for
the shared pool and load balancing.
As a review, Oracle provides a least-highly-loaded algorithm to load
balance incoming transactions among the various components of an Oracle
application server environment with the Oracle Web cache, and this is
being expanded. We now see these load balancing features within Oracle
10g release 2:
Web server load balancing - The web cache component includes
Apache extension to load-balance transactions to the
least-highly-loaded Oracle HTTP server (OHS).
RAC instance load balancing - Staring in Oracle 10g
release 2, Oracle JDBC and ODP.NET provide connection pool load
balancing facilities through integration with the new “load
balancing advisory” tool. This replaces the more-cumbersome
listener-based load balancing technique.
Automated Storage Load balancing - Oracle’s Automatic Storage
Management (SAM) now enables a single storage pool to be shared by
multiple databases for optimal load balancing. Shared disk storage
resources can alternatively be assigned to individual databases and
easily moved from one database to another as processing requirements
Data Guard Load Balancing – Oracle Dataguard allows for load
balancing between standby databases.
Listener Load Balancing - If advanced features such as load
balancing and automatic failover are desired, there are optional
sections of the listener.ora file that must be present
Like the Oracle advisories for
the shared pool and data buffer caches (an extension of the
v$db_cache_advice view), the 10g load balancing advisory monitors
each instance in a RAC environment and post “feedback events” (using
FAN, the fast Application Notification facility). These feedback events
are used by the connection pool (in Oracle HTTP server, via JDBC and
OPP.NET to route new transactions to the least highly-loaded of the RAC
In the Oracle whitepaper “Oracle
Database 10g Release 2: A Revolution in Database Technology”
whitepaper we see that Oracle monitors the relative “workload” (using a
round-robin technique) on each Grid instance and posts the data to the
Automatic Workload Repository, where it is picked-up by the application
change over time as well as the cluster configuration can change. It is
important to create and allocate database connections based on the most
up to date information.
Oracle Database 10g
Release2 Real Application Clusters provides
a load balancing advisory. RAC constantly monitors the workload being
executed for each service by each instance providing the service.
This information is
published to the Automatic Workload Repository and published to the
application using FAN events. The FAN event includes the current
service level provided and a recommendation of what percentage of
connections to be directed to each instance.
The integrated Oracle
Clients use these events to provide intelligent load balancing of
application requests. Most connection pools use a random or round-robin
algorithm to select an idle connection from the pool when the
application does a get connection. Using FAN events from the load
balancing advisory, the connection pool will select the connection
currently providing the best service.
With the increasing interesting Oracle 10g Grid
computing these tools are increasingly important to relieve the inherent
complexity of Oracle 10g RAC and Grid. For more information on Oracle
10g RAC and Grid load balancing, see the book “Oracle
10g Grid & RAC” by Mike Ault and Madhu Tumma: