Resolution of EasyConnect error with ORA-12154 (failed to parse the specified connection identifier)

Source: Internet
Author: User
When a person asks his Windows client to connect to the oracle server via easyconnect, the following error is reported: ORA-12154: TNS: Unable to parse the specified connection identifier

When a person asks his Windows client to connect to the oracle server using the easy connect method, the following error is reported: ORA-12154: TNS: Unable to parse the specified connection identifier

Today, I met a ORA-12154 problem in the group. Here I will record the solution process.
The reason is that when a person in the group asks his Windows client to connect to the Oracle server using the easy connect method, the following error is returned:
ORA-12154: TNS: failed to parse the specified connection identifier
The original idea was that there was no related service_name In the listener on the server side to receive the request, but he later showed that there was indeed a related service_name to receive the request.
The same easy connect statement can be used to connect to another server. This is a problem with the windows client.
After finding the relevant information, lock the problem to a parameter in the sqlnet. ora file:
NAMES. DIRECTORY_PATH
Find the file and find out the function description of this document as follows (For details, refer to: # sthref370 ):
Use the parameter NAMES. DIRECTORY_PATH to specify the order of the naming methods used for client name resolution lookups.
DEFAULT:
NAMES. DIRECTORY_PATH = (tnsnames, onames, hostname)
VALUES:
Tnsnames local naming method
Ldap directory naming method
Ezconnect or hostname easy connect naming or host naming method
CDS external naming method
Nis Network information service (NIS) external naming method
In the preceding description, we can see that this parameter is the name of the specified client.
To solve the above problem, we have done the following experiment:
Now, the NAMES. DIRECTORY_PATH parameter is changed to the following values when tnsnames and Easy Connect can be used to Connect to the client normally:
NAMES. DIRECTORY_PATH = (TNSNAMES)
Then, when we Connect using the Easy Connect connection method, we will find that:
D: \> sqlplus mai/mai@192.168.0.123: 1521/test
SQL * Plus: Release 10.2.0.3.0-Production on Friday August 2 17:42:12 2013
Copyright (c) 1982,200 6, Oracle. All Rights Reserved.
ERROR:
ORA-12154: TNS: Unable to parse the specified connection identifier
Enter the User Name:
Okay, that's it. At this time, if tnsnames is used for connection, it can still be connected normally.
If we change the parameter:
NAMES. DIRECTORY_PATH = (TNSNAMES, EZCONNECT)
The Easy Connect connection method can be normally connected.


In summary, by default, even if we do not configure NAMES. if the DIRECOTRY_PATH parameter is set, we can still connect to the Server using the easy connect connection method. However, if a configuration error or a similar client exception occurs, this is a solution.

Related reading:

SPFILE error causing database startup failure (ORA-01565)

ORA-01172, ORA-01151 error handling

ORA-00600 [2662] troubleshooting

Troubleshooting for ORA-01078 and LRM-00109

Notes on ORA-00471 Processing Methods

ORA-00314, redolog corruption, or missing Handling Methods

Solution to ORA-00257 archive logs being too large to store

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.