TNS-12564: TNS:connection refused while reinstating a failed database

One of the reasons for getting this error might be that the sqlnet.ora does not contain the proper settings like in this particular case:

[oracle@server admin]$ cat sqlnet.ora 
[oracle@server admin]$ 

As you can see there is nothing set in sqlnet.ora. Therefor when I was trying to reinstate a former PRIMARY as STANDBY, I was seeing in alert log of the reinstated database this:

Fatal NI connect error 12514, connecting to:

	TNS for Linux: Version - Production
	TCP/IP NT Protocol Adapter for Linux: Version - Production
  Time: 12-APR-2020 06:49:28
  Tracing not turned on.
  Tns error struct:
    ns main err code: 12564
TNS-12564: TNS:connection refused
    ns secondary err code: 0
    nt main err code: 0
    nt secondary err code: 0
    nt OS err code: 0

In order to fix this, I have set this in SQLNET.ORA the following:


And the reinstate worked like a charm.

Leave Comment

Your email address will not be published. Required fields are marked *