This content has been marked as final. Show 6 replies
How can I know an app supports FAN or doesn't?
The only way I know is to test it. It is the only way you can be sure.
This may also be of issue :
However Transparent Application Failover might also issue you.
First an entry need to be added to the client tnsnames.ora that uses a SERVICE_NAME instead of a SID.
Next the service 'ernie' needs to be created manually on the primary database.
ernie = (DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = TCP)(HOST = primary.server)(PORT = 1521)) (ADDRESS = (PROTOCOL = TCP)(HOST = Standby.sever)(PORT = 1521)) ) (CONNECT_DATA = (SERVICE_NAME = ernie) ) )
After creating the service needs to be manually started.
BEGIN DBMS_SERVICE.CREATE_SERVICE('ernie','ernie'); END; /
Finally a database STARTUP trigger should be created to ensures that this service is only offered if the database is primary.
BEGIN DBMS_SERVICE.START_SERVICE('ernie'); END;
The event after startup is fired, if an instance changes from status MOUNT to OPEN.
CREATE TRIGGER CHECK_ERNIE_START AFTER STARTUP ON DATABASE DECLARE V_ROLE VARCHAR(30); BEGIN SELECT DATABASE_ROLE INTO V_ROLE FROM V$DATABASE; IF V_ROLE = 'PRIMARY' THEN DBMS_SERVICE.START_SERVICE('ernie'); ELSE DBMS_SERVICE.STOP_SERVICE('ernie'); END IF; END; /
So if you do a switchover user can connect without ever knowing you did it.
For additional information google " DBMS_SERVICE"
But I think I can't test it, 'cause it's a big production enviroment. I was asking about client version, 'cause there are some applications that use old oracle clients.
In the white paper appears that we have to configure database service to OCI clients taht support FAN events as follow:
exec DBMS_SERVICE.CREATE_SERVICE (
service_name => 'salesOCI',
network_name => 'salesOCI', aq_ha_notifications => true,
failover_method => 'BASIC',
failover_type => 'SELECT',
failover_retries => 180,
failover_delay => 1);
An for OCI clients that don't support FAN events as follow:
service_name => 'salesOCI', failover_method => 'BASIC',
failover_type => 'SELECT',
failover_retries => 180, failover_delay => 1);
As I was explaining, I can't test apps one by one to check if they support FAN. So, configuring only the SERVICE to apps that support FAN and the rest of the work (TNSNAMES entry at client side, Trigger at database, etc...), do I have all work done?? everything is gona be ok??
Not sure which application you are using.
FAN is available through the following Oracle components: CMAN session pools; Oracle
Call Interface (OCI) and a number of drivers or adapters that use OCI libraries (including
OCCI, PHP, Python); Universal Connection Pool for Java; JDBC SimpleFAN API; and
ODP.NET connection pools.
Check below link in detail.
OCI and JDBC
This looks correct to me.
When in doubt check the expert.
Connect Time Failover & Transparent Application Failover for Data Guard :
Its worth a search around Uwe's site too. He has a ton of information there.
Edited by: mseberg on Apr 16, 2012 12:55 PM
Thanks again mseberg.
That's for OCI and TAF. It can't help to JDBC and FCF?