Ask the Expert

ORA-12560 error with Oracle 10g Instant Client

Hi there. I installed Oracle 10g Enterprise Edition (10.2.0.1.0 for Win32) on one computer, and the 10g Instant Client on another. When I try to connect from the other computer with
sqlplus user/pass
I get an ORA-12560 (TNS protocol adaptor error), even though my tnsnames.ora, sqlnet.ora are correct and my ORACLE_SID is set. If I use the fully qualified user/pass@sid, then it connects OK. If I connect from the other computer as "sys/pass@sid as sysdba" it's good. From there if I "shutdown immediate" it's still good -- I can shut the database down. But, when I then "startup" from the other computer, or exit SQL*Plus and try to reconnect, I get the ORA-12514. Why would that be, and why do I need to give the SID in the connect string? The listener is configured correctly (otherwise I would always get the 12514).

    Requires Free Membership to View

When connecting to a remote database, the ORACLE_SID environment variable has no meaning. This environment variable is used for local databases only. Instead, you will have to use a TNS alias as defined in your TNSNAMES.ORA config file. This why you can connect with user/pass@tns_alias. And you have shown this in being able to shut down your instance remotely. The reason you cannot connect to start it back up is that the instance uses "dynamic registration" to register the instance with the Oracle Listener. When the instance is shut down, the Listener does not know anything about it, hence the ORA-12514 error. If you want to be able to start the instance remotely, you will need to configure Static Registration. Please refer to your Net Administrator's Guide for details.

This was first published in August 2007

There are Comments. Add yours.

 
TIP: Want to include a code block in your comment? Use <pre> or <code> tags around the desired text. Ex: <code>insert code</code>

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy
Sort by: OldestNewest

Forgot Password?

No problem! Submit your e-mail address below. We'll send you an email containing your password.

Your password has been sent to: