原因是多方面的,需要根据你的具体情况分析。
参考:
ORA-12560: TNS:protocol adapter error
Additional key words
TNS-12560
Cause and prerequisites
ORA-12560 is a collective error caused by different problems related to the connect log that is used. Other, more specific error messages may have occurred in connection with ORA-12560 that narrow down the actual cause more more precisely. The following may result in an ORA-12560 being generated within the framework of the R/3 application and administration:
1. NT: Start client tools (svrmgrl, sqlplus, sapdba, ...) using a terminal server
2. NT: Service oracleservice does not run
3. Incorrect / missing entry for ORACLE_SID in environment / registry
4. Non-alphanumeric characters in the SID
5. NT: Missing directory authorizations
6. Error in creating the database for new installation
7. Resource problems
8. RELIANT: s-bit not set for some Oracle tools
9. TRU64, AIX: Destroyed sockets due to an Oracle bug
Solution
1. The terminal server does not support any connections with the BEQUEATH log (BEQ). This log is used as a default when calling svrmgrl or sqlplus. As a result, calling svrmgrl or another tool that uses BEQ causes an ORA-12560. sapdba or the BR tools can also be affected, as svrmgrl is called internally. The problem can be avoided as follows:
a) Do not use a terminal server if you use svrmgrl or sqlplus.
b) Set the environment variable LOCAL= before starting the tool used. This prevents a connect being implemented via BEQ.
2. Start the service oracleservice if it has not already been sarted. Make sure no error message appears (regarding DLLs, for example).
If the service oracleservice does not exist (for example, during a database upgrade), you can create this with "oradim[73|80] -new -SID ". Note that the relevant command is called "oradim73" in Oracle 7.3, "oradim80" in Oracle 8.0 and "oradim" in Oracle 8.1.
3. "ORACLE_SID = " must be set in the environment. On NT, a corresponding entry must be available in the registry under HKEY_LOCAL_MACHINE -> SOFTWARE -> ORACLE and the subdirectory HOME-.
4. Oracle allows a SID with non-alphanumeric characters (for example, underscores "_") to be created. However, this terminates the connect with ORA-12560. This can only be solved by deleting the instance and creating it again under a new name.
5. Check whether the user SYSTEM has all authorizations on the Oracle home directory and its subdirectories.
6. If the error occurs within the framework of a new installation of the database, the scripts for creating the database ("CREATE DATABASE") may not have run correctly
参考:
ORA-12560: TNS:protocol adapter error
Additional key words
TNS-12560
Cause and prerequisites
ORA-12560 is a collective error caused by different problems related to the connect log that is used. Other, more specific error messages may have occurred in connection with ORA-12560 that narrow down the actual cause more more precisely. The following may result in an ORA-12560 being generated within the framework of the R/3 application and administration:
1. NT: Start client tools (svrmgrl, sqlplus, sapdba, ...) using a terminal server
2. NT: Service oracleservice does not run
3. Incorrect / missing entry for ORACLE_SID in environment / registry
4. Non-alphanumeric characters in the SID
5. NT: Missing directory authorizations
6. Error in creating the database for new installation
7. Resource problems
8. RELIANT: s-bit not set for some Oracle tools
9. TRU64, AIX: Destroyed sockets due to an Oracle bug
Solution
1. The terminal server does not support any connections with the BEQUEATH log (BEQ). This log is used as a default when calling svrmgrl or sqlplus. As a result, calling svrmgrl or another tool that uses BEQ causes an ORA-12560. sapdba or the BR tools can also be affected, as svrmgrl is called internally. The problem can be avoided as follows:
a) Do not use a terminal server if you use svrmgrl or sqlplus.
b) Set the environment variable LOCAL= before starting the tool used. This prevents a connect being implemented via BEQ.
2. Start the service oracleservice if it has not already been sarted. Make sure no error message appears (regarding DLLs, for example).
If the service oracleservice does not exist (for example, during a database upgrade), you can create this with "oradim[73|80] -new -SID ". Note that the relevant command is called "oradim73" in Oracle 7.3, "oradim80" in Oracle 8.0 and "oradim" in Oracle 8.1.
3. "ORACLE_SID = " must be set in the environment. On NT, a corresponding entry must be available in the registry under HKEY_LOCAL_MACHINE -> SOFTWARE -> ORACLE and the subdirectory HOME-.
4. Oracle allows a SID with non-alphanumeric characters (for example, underscores "_") to be created. However, this terminates the connect with ORA-12560. This can only be solved by deleting the instance and creating it again under a new name.
5. Check whether the user SYSTEM has all authorizations on the Oracle home directory and its subdirectories.
6. If the error occurs within the framework of a new installation of the database, the scripts for creating the database ("CREATE DATABASE") may not have run correctly
Oracle启动时,监听器不启动或打开出错?
软件环境:
1、Windows NT4.0+ORACLE 8.0.4
2、ORACLE安装路径为:C:\ORANT错误现象:
1、ORACLE启动时,监听器不启动或打开出错
2、服务器端:用username/password登录正常,但用username/password@alias登录不成功
3、客户端:用username/password@alias登录不成功解决方法:
1、如果是因为修改了NT的机器名,则把listener.ora文件中的host参数全部改为新的NT机器名,
重新启动OracleTNSListenr80服务即可。
例如:
LISTENER =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(Host = NT_Name)(Port = 1521))
(ADDRESS = (PROTOCOL = TCP)(Host = NT_Name)(Port = 1526))
)
2。使用监听器实用程序:LSNRCTL80.exe
3。检查监听器参数文件:c:\orant\NET80\admin\listener.ora
4。检查监听器日志文件:c:\orant\NET80\log\listener.log
5。Tnsnames.ora文件配置错误,重新配置。
6。检查client 端 Tnsnames.ora
在控制面板里重新启动:监听器服务一起一次,!!!