ORA-12505 connection refuse solution and summary

Source: Internet
Author: User

ORA-12505 connection refuse solution and summary
Oracle
Problem description:
The following error occurs when you connect to the Oracle 10.2.0.1.0 database using JDBC today:
Connection refused (description = (TMP =) (vsnnum = 153093120) (ERR = 12505) (error_stack = (error = (code = 12505) (emfi = 4 ))))

You can directly connect to the database through PLSQL, or connect to the database through sqlplus.

After debugging and searching for relevant information, the cause of the problem is as follows:
When connecting to the database through JDBC, you must use the database's sid_name instead of the database's services_name.
When using PLSQL to connect to the database, you only need the services_name of the database. Therefore, modify the services_name in the connection string to sid_name.

Appendix:
View the current Sid in the database:

SQL> select instance_name from V $ instance;

Instance_name
----------------
HASL

 

 

I have encountered this problem before and found a solution, but today I have been suffering for a long time, finally, we found that we have made a record in the local device .................

 

The same problem happened twice and was also entangled for several hours ...............

 

Avoid similar errors in the future .............

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.