Situation: Two servers: DB and DG -> The database is active on DB, no problem to connect -> Switchover, DG becomes...
By submitting your personal information, you agree that TechTarget and its partners may contact you regarding relevant content, products and special offers.
active -> unable to connect to the database. The client still wants to connect to DB, because the database on DB hasn't really shut down, but is in standby.
Is there a way to automatically connect to the database that is not in standby?
Our TNSNAMES looks like this:
PROD= (DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = TCP)(HOST = DB)(PORT = 1521)) (ADDRESS = (PROTOCOL = TCP)(HOST = DG)(PORT = 1521)) ) (CONNECT_DATA = (SERVICE_NAME = PROD) ) )If we switch the lines in ADDRESS_LIST, we can connect.
Hope you can help us.
PROD= (DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = TCP)(HOST = DB)(PORT = 1521)) (ADDRESS = (PROTOCOL = TCP)(HOST = DG)(PORT = 1521)) ) (CONNECT_DATA = (SERVICE_NAME = PROD) (FAILOVER_MODE = (TYPE=SESSION)(METHOD=BASIC)) ) )The new entry in bold will tell your Oracle client software to failover to the second server if the first server does not have the Oracle listener running.
Dig Deeper on Oracle database administration
Related Q&A from Brian Peasland
Oracle expert Brian Peasland answers one reader's question about common pitfalls when connecting Oracle to outside programs.continue reading
One reader asks expert Brian Peasland a question about datafile sizes with the Oracle RMAN duplicate 10g command.continue reading
Managing parent table-child table relations in Oracle SQL environments is key to efficient programming.continue reading
Have a question for an expert?
Please add a title for your question
Get answers from a TechTarget expert on whatever's puzzling you.