Switchover tnsnames client
I have created primary and standby database, and both are working perfectly fine, when I performed switchover, I am having one issue.
The client users can not access the database The reason they have only one primary database entry in tnsnames.ora file, when I added one entry for standby in one users tnsnames file, the user can access the database sucessfully.
primary------ machine: test9 sid: primary
standby------machine: standby sid: standby
What should we do ? Do i need to modify/add new entry in all users/clients TNSNAMES.ora file ? or there is anyother parameter what we need to set ?
Waiting for reply.
SQL> select * from v$version;
BANNER
Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Prod
PL/SQL Release 10.2.0.1.0 - Production
CORE 10.2.0.1.0 Production
TNS for 32-bit Windows: Version 10.2.0.1.0 - Production
NLSRTL Version 10.2.0.1.0 - Production
Primary database init file :
*.control_files='D:\oracle\product\10.2.0/oradata/primary/\control01.ctl','D:\oracle\product\10.2.0/oradata/primary/\control02.ctl','D:\oracle\product\10.2.0/oradata/primary/\control03.ctl'
*.db_name='primary'
*.db_unique_name='PRIMARY'
*.dispatchers='(PROTOCOL=TCP) (SERVICE=primaryXDB)'
*.log_archive_dest_1='location=D:\oracle\product\10.2.0\oradata\archive'
*.log_archive_dest_state_1=ENABLE
*.log_archive_dest_state_2=ENABLE
*.log_archive_dest_2='SERVICE=standby LGWR ASYNC'
*.log_archive_format='arc_%s_%t_%r.arc'
*.fal_client='PRIMARY'
*.fal_server='STANDBY'
standby database init file :
*.control_files='D:\oracle\product\10.2.0/oradata/primary/STANDBY_CONTROL.CTL'
*.db_name='primary'
*.db_unique_name='STANDBY'
*.dispatchers='(PROTOCOL=TCP) (SERVICE=primaryXDB)'
*.log_archive_dest_1='location=D:\oracle\product\10.2.0\oradata\archive'
*.log_archive_format='arc_%s_%t_%r.arc'
*.log_archive_dest_state_2=ENABLE
*.fal_server='PRIMARY'
*.fal_client='STANDBY'
*.standby_file_management=auto
--------------------------------------------------------------------------------
Similar Messages
-
Hi All,
We have installed Oracle DG physical standby in 2 servers and we have configured the replication between the 2 DBs, In order to configure the automatic switchover, do we need a seperate server for observer?, as well if I am going to use another server which is used for a different application, I am wondering if it will have any impact on that application, in another word is this observer is light or not?.
Best Regards,Hello, thank you for the link.
As in Our goal is to have a Runtime Failover completely transparent to the client, we define our service in the primary database as shown in the article.
Our TNS entry is similar to UWE's, but because we are using RAC we group the nodes of a cluster in an address list.
We are 11gR1 and use srvctl to create our services. We see that the CRS brings up the services when the standby becomes the primary. UWE also noted in some of his comments that this is a feature in 11g and the startup triggers are no longer needed.
We are a physical standby, I forgot to mention that earlier.
It looks like we are doing everything that we should. When we first started this project, DG seemed hard. As with anything, now that we understand it, our implementation seems simple.
I'm hoping that someone, somewhere, has had a similar response and can provide some insight.
To reiterate:
We are running RAC with DG Broker (11.1.0.7), define services with srvctl on the primary. We also add those services on the standby but they don't get started until switchover. All client connections are through the service name, which is defined in a TNS entry.
When there is an active session on the primary and we switchover, the client gets an ora-3113 end of file communication error and it we must reconnect and reissue the statement. This is our problem.
Any insights? -
Help !! I can't connect to server using connection manager
Hello :
i hava three machine,i use connection manager on Oracle 8.1.7
i can't connect to server using connection manager
1.lsnrctl start (Server)
2.svmrgrl (Server)
start (Server)
3.cmctl start (Middle tier)
4.sqlplus scott/tiger@test (client)
ORA-12564
Please help my!
---- CLIENT (sqlnet.ora)
USE_CMAN = TRUE
NAMES.DIRECTORY_PATH= (TNSNAMES)
---- CLIENT (tnsname.ora)
(DESCRIPTION =
(SOURCE_ROUTE = YES)
(ADDRESS = (PROTOCOL = TCP)(HOST = orcl-middler)(PORT = 1610))
(ADDRESS = (PROTOCOL = TCP)(HOST = orcl-db)(PORT = 1521))
(CONNECT_DATA =
(SID = bigbear)
---- MIDDLE TIER(cman.ora)
CMAN = (ADDRESS_LIST =
(ADDRESS =
(PROTOCOL = TCP)
(HOST = orcl-middler)
(PORT = 1610)
---- SERVER (listener.ora)
LISTENER =
(DESCRIPTION_LIST =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = orcl-db)(PORT = 1521))
SID_LIST_LISTENER =
(SID_LIST =
(SID_DESC =
(ORACLE_HOME = /u01/app/oracle/product/8.1.7)
(SID_NAME = bigbear)
---- SERVER (init.ora)
MTS_DISPATCHERS = "(PROTOCOL = TCP)(DISPATCHERS=10)(MULTIPLE=ON)"
MTS_MAX_DISPATCHERS=20
MTS_MAX_SERVERS = 30
MTS_SERVERS = 10
MTS_SERVICE = bigbear
db_name = "bigbear"
db_domain = intumit.com
instance_name = bigbear
service_names = bigbear.intumit.commidder tier must config hosts
because dispatcher have listener information
midder tier must know ipaddress
Ex. on midder tier
/etc/hosts
192.168.10.1 orcl-middler
from client to server it's ok -
Hi, Expert
we are implementing BW project at the beginning of the project. Now we decide one server for two clients namly client 400 and 500. Client 400 is for configuration environment, in this client the consultant can only do configuration and don't allowed to load any application data. The client 500 is for both configuration testing and develpoment environment. This client allow to enter testing data, don't allowed to configuration changing; its configuration comes from client 400.
And another one server is for BW pro.
Question:
1) In this case, should we create Defining Client Administration, Defining a Logical System, Assigning Logical System to Client and Creating an RFC User for both client 400 and 500?
2) Now when we use RSA1, system display message 'You can only use it in client 400. So, is this case how could we use this client? Could anyone explain about this kind of BW landscape setting for both client 400 and 500 and give more detailed information.
Thanks!
Edited by: hi ni on Apr 14, 2008 7:44 AMHi NI,
In BW you can use only one active client....In R/3 we can use more than one client.
if you want use client 500 you cannot use client 400.
if you want, you can switchover to client 500
You can find the details in Table : 'RSADMINA'
find the field value "BWMANDT"
Hope thyis will help you.
Regards,
Vijay. -
11g dataguard client tnsname.ora entry format for switchover and failover
I need format for the tnsnames.ora to use for the enduser when failover or switchover occurs in 11g dataguard.
http://download.oracle.com/docs/cd/B19306_01/network.102/b14213/tnsnames.htm#sthref722
-
Best Practice to configure tnsnames.ora on client of MAA environment in 10g
Hi,
I have a MAA environment, 1 RAC Primary of 2 nodes and 1 RAC standby of 2 nodes too. I want to configure the tnsnames.ora on clients (we have many clients on each PC) and I need to configure the tnsnames.
I have read some papers but the information is not clear regarding to configure the tnsnames on clients. I just want to have only one entrie on tnsnames that I can use on clients to connect to RAC Primary and/or Standby depending on what site is primary in that moment, I was thinking in something like this:
SALES.WORLD =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = site1a)(PORT = 1521))
(ADDRESS = (PROTOCOL = TCP)(HOST = site1b)(PORT = 1521))
(ADDRESS = (PROTOCOL = TCP)(HOST = site2a)(PORT = 1521))
(ADDRESS = (PROTOCOL = TCP)(HOST = site2b)(PORT = 1521))
(LOAD_BALANCE = yes)
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = sales.world)
(FAILOVER_MODE =
(TYPE = SELECT)
(METHOD = BASIC)
(RETRIES = 180)
(DELAY = 5)
Where site1 is RAC Primary now, and site2 is standby. But in case of switchover, I want that clients recognize automatically to which site connect.
I was thinking to stop listeners on site that is not primary on that moment.
The question is if this is the best practice on this scenario?.
Thanks for your advice.
LuisHi Louis,
you need to setup a service with clusterware. On both sides: primary and standby.
On primary you start them. On standby the services are also configured but stopped.
In case of switchover or failover, data guard will notice clusterware to bring them up.
You need to use this service name in your clients tnsnames.
Another issue are TCP timeouts, to protect against them you use
outbount_connect_timeout in your sqlnet.ora
Also have a look at
http://www.oracle.com/technology/deploy/availability/pdf/MAA_WP_10gR2_SwitchoverFailoverBestPractices.pdf
HTH Mathias -
Client failure failover/switchover standby configuration...
I have created standby database, the standby database is synch with primary... After switchover the primary is now standby and standby is now primary, the clients are unable to connect to new primary database.
TNSNAMES.ora file at client side...
prim.world=
(DESCRIPTION_LIST=
(FAILOVER=true)
(LOAD_BALANCE=no)
(DESCRIPTION=
(ADDRESS=
(PROTOCOL=TCP)
(HOST= test9)
(PORT=1521)
(CONNECT_DATA=
(SERVER=dedicated)
(SERVICE_NAME=primary)
(DESCRIPTION=
(ADDRESS=
(PROTOCOL=TCP)
(HOST=standby)
(PORT=1521)
(CONNECT_DATA=
(SERVER=dedicated)
(SERVICE_NAME=standby )
SQL> conn iq/[email protected]
ERROR:
ORA-01033: ORACLE initialization or shutdown in progress
SQL> conn sys/[email protected] as sysdba
Connected.
SQL> select open_mode from v$database;
OPEN_MODE
MOUNTED
SQL> select database_role from v$database;
DATABASE_ROLE
PHYSICAL STANDBY
SQL>
It's Oracle 10.2.0.1.0 version....oracleRaj
Handle: oracleRaj
Status Level: Newbie
Registered: Mar 26, 2010
Total Posts: 370
Total Questions: 64 (36 unresolved)
Name Raj
Location Karachi
Occupation DBA -
Solution for tnsnames at client side
Hi,
My database is in oracle 10.2.0. I have configured 2 standby servers for my primary database. I want to know that are there any parameter in tnsnames.ora at the client side so that If switchover or failover occurs,the client or user should not be aware of the switch process i.e., without down time.
Because there will be different service names and host, how can this be addressed at the client tnsnames.ora.
Thanks in advance for your suggestions,
satyanagHi Satyanag,
It's possible to specify more than one address location. For example:
SCR9 =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = bloo)(PORT = 1521))
(ADDRESS = (PROTOCOL = TCP)(HOST = fermat)(PORT = 1521))
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = scr9)
If the first address can't be contacted Oracle will try the second address.
Cheers,
Andy Barry
http://www.shutdownabort.com -
No client access on DAG switchover - Single site
Let’s summarize my environment:
I have 3 Exchange 2013 SP1 (cu4) server in one site. CAS01, only have cas role and MBX01&MBX02 have only mailbox. Both mailbox are in a DAG (DAG01).
The server mounting my database is MBX02. Whenever a switchover to MBX01 occur (or when I force it whith Move-ActiveMailboxDatabase –server MBX02 -ActivateOnServer MBX01), all my client get disconnected so no more outlook, active sync
and even owa. As soon as I roll them back on MBX02, everything returns to normal. However, every single email delivered while the DAG was mounted on MBX01 are getting delivered to the mailbox server so dag is working properly for the mail flow, minus the client
access HA.
Now I know that on Exchange 2010 and the issue could have been with the value of –rpcclientaccessserver on my database, but this value is not used anymore on 2013.
Any ideas?
ThanksHi S.Nithyanandham
1. No my servers are working pretty fine is I create a non dag DB on MBX01, Client access and mail flow is fine. Turning off both Windows firewall didn’t
change anything
2.
Server Check Result Error
MBX01 ClusterService Passed
MBX01 ReplayService Passed
MBX01 ActiveManager Passed
MBX01 TasksRpcListener Passed
MBX01 TcpListener Passed
MBX01 ServerLocatorService Passed
MBX01 DagMembersUp Passed
MBX01 ClusterNetwork Passed
MBX01 QuorumGroup Passed
MBX01 FileShareQuorum Passed
MBX01 DatabaseRedundancy Passed
MBX01 DatabaseAvailability Passed
Server Check Result Error
MBX02 ClusterService Passed
MBX02 ReplayService Passed
MBX02 ActiveManager Passed
MBX02 TasksRpcListener Passed
MBX02 TcpListener Passed
MBX02 ServerLocatorService Passed
MBX02 DagMembersUp Passed
MBX02 ClusterNetwork Passed
MBX02 QuorumGroup Passed
MBX02 FileShareQuorum Passed
MBX02 DatabaseRedundancy Passed
MBX02 DatabaseAvailability Passed
MBX02 DBCopySuspended Passed
MBX02 DBCopyFailed Passed
MBX02 DBInitializing Passed
MBX02 DBDisconnected Passed
MBX02 DBLogCopyKeepingUp Passed
MBX02 DBLogReplayKeepingUp Passed
3. I’ve double check that and recreated the dag binding multiple time with no luck.
4. yes they are
[PS] C:\Windows\system32>get-mailboxdatabasecopystatus | ft -au
Name Status CopyQueueLength ReplayQueueLength LastInspectedLogTime ContentIndexState
DB1\MBX01 Mounted 0 0
Healthy
DB2\MBX01 Mounted 0 0
Healthy
DB3\MBX01 Mounted 0 0
Healthy
DB4\MBX01 Mounted 0 0
Healthy
[PS] C:\Windows\system32>get-mailboxdatabasecopystatus -server mbx02 | ft -au
Name Status CopyQueueLength ReplayQueueLength LastInspectedLogTime ContentIndexState
DB1\MBX02 Healthy 0 0 2015-01-12 19:57:58 Healthy
DB2\MBX02 Healthy 0 0 2015-01-12 19:58:10 Healthy
DB3\MBX02 Healthy 0 0 2015-01-12 19:58:07 Healthy
DB4\MBX02 Healthy 0 0 2015-01-12 20:00:23 Healthy
5. None except those related to the failover if I bring MBX02 down
6. File share is fine and acessible.
Then please explain me what you are trying to say on the below mentioned line?
When I have a failover and database are mounted and healthy I can’t connect trougth any devices but email sent to my organization are devilered in databases correctly. I can see them with Get-MessageTrackingLog. In addition, my Wtachguard
in front of my cas is not reporting any bounce or error, everything is delivred and queue is empty inside it.
A big Thank you for your help
Alex
Alexandre Contant -
Location of tnsnames.ora for Tora and Oracle XE Client
I Googled far and wide and did not see a CLEAR answer to my question, hopefully this will help others.
I have installed the debian oracle-xe-client and tora packages (tora rebuilt for oracle) on Ubuntu 8.04.
However, I did not know where I was supposed to place the tnsnames.ora file for my databases. I have tried running Tora with the environment variable of TNS_ADMIN set to the file where I placed my tnsnames.ora, however that did not work as Tora did not 'see' the file or its entries apparently. I know this works because I copied it from a Debian Etch box with the client and server installed.
I had even added a 'network/admin' directory structure to the //usr/lib/oracle/xe/app/oracle/product/10.2.0/client (ORACLE_HOME) with the tnsnames.ora but also with no success.
Now for the solution:
Simply remember that TNS_ADMIN points to the directory where the tnsnames.ora is and it will work. :)
I do have a suggestion that both Tora and sqlplus use a config file to set these directory(s) in addition to the overriding ability of the environment variable, TNS_ADMIN as is usually the case with UNIX apps (and thus expected).
Thank you,
JasonThe ODBC Instant Client Readme that is included in the install also indicates that %ORACLE_HOME%/network/admin/tnsnames.ora is the correct default location. What about OCI?
-
Oracle 8i clients, inconsistent handling of tnsnames.ora (ORA-06401 gotcha)
This is more of a bug report / oddity declaration than a real problem, though it was a pain in the butt to nail down. I post it here for the benefit of anyone else who may run into it down the road.
Using the linux sqlplus client, I kept getting consistent failures connecting to one of a dozen db's, but tests with the (java) netasst client worked fine. After various debugging of other potential causes, it came down to strace'ing the sqlplus client, and noting that it was attempting to connect to the wrong host, despite what was specified on the command line.
What we identified as the most probable cause:
The routines that load and parse the tnsnames.ora file differ between the linux and java clients, with the java client being more tolerant/robust. The tnsnames.ora file I'd been supplied with had come from a fellow user's Win32 machine, and had been edited there, which probably included a couple ^M's or other non-visible characters within the file.
The solution (at least, what I did):
Load the tnsnames.ora file with netasst, and save it again with netasst. Netasst wrote the file in a manner that sqlplus could read accurately, and I got to go have a beer.
- billnHi Fredrik,
You r right. But I have its entry in tnsnames.ora file. The entry looks like this -
My_Service_Name.world =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS =
(COMMUNITY = tcp.world)
(PROTOCOL = TCP)
(Server = Computer_Name_of_Server_having_Ora8i)
(Host = IP_Add_of_Server_having_Ora8i)
(Port = 1521)
(Pipe = ORAPIPE)
(CONNECT_DATA = (SID = ORCL)
The same entry exists in the tnsnames.ora file on the local PCs (same office where the Oracle 8i Server is present) at Site 1 and these PCs connect the server without any problem.
Thanks
Lokesh -
TNS_ADMIN (path to tnsnames.ora) using Instant Client IGNORED
Hi,
I developed a simple utility which uses OCCI LIB from 10g release. I'm deploying it with Oracle Instant Client lite libraries.
Everything works fine when tnsnames.ora is present in the same dir. When I move it somewhere else and set TNS_ADMIN to that directory, it doesn't work anymore:
C:\uplob>set TNS_ADMIN=c:\tns;
C:\uplob>echo %tns_admin%
c:\tns;
C:\uplob>uplob u/p@xe 15 input.dat
Exception:12154 ORA-12154: TNS:could not resolve the connect identifier specif
ied
This seems very simple, but I still cannot determine why TNS_ADMIN is not being taken into account.
Thank you for any help with this issue,
davidI think for Windows ,
You may have to set this in MY-COMPUTER-->Advanced-Env-Variables
and reboot to take effect.
rgds -
DBD::Oracle & Instant client - don't find tnsnames.ora
Hello,
I'm trying to use tns names in Perl scripts to connect with Instant client. I always get the ORA-12154 error when connecting with Perl :
ORA-12154: TNS:could not resolve the connect identifier specified (DBD ERROR: OCIServerAttach).
The perl command that raise the error is :
+$dbh = DBI->connect("dbi:Oracle:MYDB","user","password") or die $DBI::errstr."\n";+
I checked my Oracle installation and everything seems fine. Connection with sqlplus work without problem using the same connection string (sqlplus user/passowrd@MYDB).
I stat'ed my tnsnames.ora file to check if it's accessed : it is with sqlplus, but not with my perl script.
Instant Client has been installed with the zip files made available by Oracle (not RPM). ORACLE_HOME points to the installation directory and tnsnames.ora is located in $ORACLE_HOME//network/admin/. Server is a Red Hat Entreprise 5.
In my knowledge DBD::Oracle use OCI so there should not have difference between sqlplus and DBD::Oracle. Am I wrong ? Anyone have had this problem before ?
Thanks for your help
FlorentHi,
Environment variables was correctly defined, but your comment put me on the right track.
I printed the %ENV content to check ORACLE_HOME which was OK.
I check the directory and remind I put a sqlnet.ora file in the same directory than tnsnames.ora with the followin content :
AUTOMATIC_IPC = OFF
TRACE_LEVEL_CLIENT = OFF
names.directory_path = (TNSNAMES)
names.default_domain = world
name.default_zone = world
I removed this file and everything is ok now. I don't really know what this file is used for, but if I keep it online and change MYDB in the connection name to MYDB.world, it worked. I think I have to learn more about names...
Thanks for your help anyway !
Regards,
Florent -
Oracle client in linux problem with tnsnames.ora
hi all
i installed oracle-xe-cleint10.2 on linux machine i did not get any tnsnames.ora in my machine i am unable to connect to database. it shows tns connectiont identifier unfound. . is it come all with oracle client or some where else it .
or further any proceeding i should follow steps. if found solution regard this pls forward solution to me
Regard
syamhi all
i did not get any tnsnames.ora after installing oracle client in linux machine
i installed oracle-xe-cleint10.2 on linux machine i did not get any tnsnames.ora in my machine i am unable to connect to database. it shows tns connectiont identifier unfound. . is it come all with oracle client or some where else it .
or further any proceeding i should follow steps. if found solution regard this pls forward solution to me
Regard
syam
Regards syam -
How to define a DSN without using a tnsnames.ora on the PC client machine
Hi,
Client : Windows XP with Oracle9i ODBC driver
Server : Oracle 10 on Solaris
I need to define a DSN which does not rely on tnsnames.ora on the client machine.
I tried to use a file dsn, but without success, because I don't know the parameters to use.
I used these params in the file.dsn :
[ODBC]
DRIVER=Oracle9i ODBC Driver
UID=testuser
PWD=testpw
SERVER=(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=myhost)(PORT=9999))(CONNECT_DATA=(SERVICE_NAME=testSID)))
It does not work ....Hrm, interesting. It always used to be DBQ but it seems it might have changed to SERVER at some point.
Anyway, I tried this and it worked fine for me (using 10204)
TESTFILE.DSN
================
[ODBC]
DRIVER=Oracle in OraDb10g_home1
server=(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=gdarling-pc2)(PORT=1521)))(CONNECT_DATA=(SERVER=DEDICATED)(SERVICE_NAME=orcl)))
TEST.VBS
==========
set con = createobject("adodb.connection")
con.open "filedsn=testfile;uid=scott;pwd=tiger;"
set rs = createobject("adodb.recordset")
rs.open "select user from dual",con
msgbox rs.fields(0).value
Note also that unless you really want to create a file dsn, you could also just use a dsnless connection string and pass that directly too:
set con = createobject("adodb.connection")
con.open "driver={Oracle in OraDb10g_home1};uid=scott;pwd=tiger;server=(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=gdarling-pc2)(PORT=1521)))(CONNECT_DATA=(SERVER=DEDICATED)(SERVICE_NAME=orcl)))"
set rs = createobject("adodb.recordset")
rs.open "select user from dual",con
msgbox rs.fields(0).value
Hope it helps,
Greg
Maybe you are looking for
-
XML file in the form of .config file how to convert it to class and store it in single object
Hi, I have a config file in which i have to convert it to class and get an object. example: <?xml version="1.0" encoding="utf-8" ?> <xyz xmlns=""> <Container name ="Basic"> <Connectivity user="" server="" protocol="udp"/> <Connectivity user
-
How to Format Toshiba Hard-Drive for Mac with Parallels?
Hello, I recently bought a Toshiba Hard-Drive with the following features: 500GB It is a Canivo Basics 3.0 It is USB 3.0 and 2.0 portable hard drive It has already been formatted NTFS for Windows XP, Vista, 7, and 8 The box says that it can be reform
-
Hi! We have a report with ALV Grid. When we press "Microsoft Excel" button to activate it, the following error appears: "Template not found in BDS - Layout: Templat Guid:". Do we have to apply a note to correct this problem? Or do we have to create
-
To define summer holiday period in factory calendar
Dear All, I have to define summer and midterm holidays to factory calendar. I defined them by using "special rules" in transaction SCAL. I saw the days as holiday in factory calendar. On the other hand, when I use function HR_RO_WORKDAYS_IN_INTERVAL
-
How do I install Flash 10 so that it will work in all user accounts?
I have added an account for an 8-year old boy to access DisneyXD, Nick, etc. The problem is that I can only get Flash to work from my account. I am running Windows XP and IE Explorer 8.0. I've tried the following: * Giving administrator privilege to