Fernando Karnagi’s Weblog

IBM WebSphere Portal – Oracle Database Failover – working

Posted in Portal by fernandokarnagi on December 8, 2008

During the SIT in our Portal project, we encountered the case where the Portal is not able to handle the Oracle Portal DB failover. It means that after the Portal DB down, then up again, Portal is not able to recover the functions properly.

Actually these are the tricks:

1. Configure the datasource minimum connections to 0 and the Unused timeout value well below whatever is timing out the connections in the network. This causes Websphere to drop connections BEFORE the external source, so WebSphere will not have invalid connections to retry. Active connections which are closed will still be returned to the free pool and available for re-use as long as they are used before the Unused timer expires. This allows you to still realize the benefit of a connection pool but minimize the SCE exposure. This option will not eliminate all SCE’s, but is a good alternative for situations where you are aware of the cause of the SCE such as firewalls or database server maintenance. In this case, set the wpsDBDS, jcrDB, and other DS minumum connections to 0.

2. Configure a preTestSQLString to test every connection obtained from the free pool before use. In this case, use “SELECT 1 FROM DUAL” for all Portal JDBC

3. Add custom properties to the JDBC

a. dbFailOverEnabled, type Boolean, value true

b. connRetriesDuringDBFailover, type Integer, value 100. dbFailOverEnabled must be true

c. connRetryIntervalDuringDBFailover, type Long, value 3000. dbFailOverEnabled must be true

Leave a Reply

You must be logged in to post a comment.