how can I solve ora 12560 TNS protocol adaptor error

ali yousef picture ali yousef · Dec 5, 2018 · Viewed 22.1k times · Source

I'm running ORACLE 11gR2 through Windows server 2008 R2. Because of some reason shutdown database with "shutdown immediate" command, but when I need to startup again database, this error message is appear: "ORA-12560: TNS:protocol adapter error" about ORA 12560 I consumed many time through internet for finding soloution but all of the is very basic guide that could not solve my problem. please consider to my problem with following below image: 1. when I want to startup database: enter image description here

  1. set oracle_sid in command prompt and check in windows environment variables: enter image description here

  2. check lsnrctl status:enter image description here

  3. tnsping: enter image description here

  4. check windows oracle service: enter image description here

so, according those images everything looks fine but my database wont to start again I will be thankful if I have your clear, correct and tested solution for my problem

Answer

Brian Leach picture Brian Leach · Dec 6, 2018

There are a multitude of things that might be happening here.

I continue to have issues with databases registering properly with the listener. Make a backup of the listener.ora file %ORACLE_HOME%\network\admin\listener.ora and add an entry similar to the following to the SID_LIST. Your ORACLE_HOME path will most likely be different than mine:

  (SID_DESC =
  (GLOBAL_DBNAME = RDEV.world)
  (ORACLE_HOME = D:\Oracle\product\12.2.0\dbhome_1)
  (SID_NAME = RDEV)
)

Restart the listener and see if you can connect:

lsnrctl stop
lsnrctl start

The following entry added to the sqlnet.ora file also helps. Again, backup before editing

NAMES.DEFAULT_DOMAIN = WORLD

This allows you to reference the database as ORCL or ORCL.WORLD

These fixes have worked on Oracle 11 and 12 databases.