12c: ORA-1017 or other connection problems using the DEFAULT_SERVICE_LISTENER parameter in 12c Multi-tenant environment
Last updated on JULY 05, 2017
Applies to:Oracle Net Services - Version 188.8.131.52 to 12.2 BETA1 [Release 12.1 to 12.2]
Information in this document applies to any platform.
The following pertains to the EZCONNECT or Easy Connect (or HOSTNAME) method of connecting to a 12.1 and higher Database.
1. When using EZCONNECT and specifying the SERVICE_NAME in the string, the connection is successful:
2. When using EZCONNECT and NOT specifying the SERVICE_NAME value, the connection fails:
ORA-12504: TNS:listener was not given the SERVICE_NAME in CONNECT_DATA
* This is expected as there needs to be a DEFAULT_SERVICE_<listener_name> = x value included in the listener.ora file to reflect a DEFAULT Service.
ORA-12504 When Using (HOSTNAME) Method For 11G Client/Database (Doc ID 556996.1)
Database Net Services Reference
3. When setting the parameter "DEFAULT_SERVICE_LISTENER=*service_name*" in the listener.ora as per Oracle docs, and then connect as in #2 above, this results in an error:
ORA-01017: invalid username/password; logon denied
* This is happening despite the username and password being the same as all of the above attempts.
You may have recently upgraded to 12c and using Multi tenant PDBs.
Sign In with your My Oracle Support account
Don't have a My Oracle Support account? Click to get started
My Oracle Support provides customers with access to over a
Million Knowledge Articles and hundreds of Community platforms