1. Documentation in Tahiti -> Masters Book List -> Net Services Administrator’s Guide -> 8 Configuring Naming Methods
2. The objective references to connect to a DB without using the configuration file “tnsnames.ora”.
This functionality Oracle has given the name of “Easy Connect”. Do a test connections against OCM DB.
# “Easy Connect” (EZConnect) is enabled by default NAMES.DIRECTORY_PATH parameter. Default = (TNSNAMES, LDAP, EZConnect)
# You can disable if we remove the “EZConnect” value of this parameter
# Validate that we have activated the file at $ ORACLE_HOME / network / admin / sqlnet.ora
cat $ ORACLE_HOME / network / admin / sqlnet.ora
# If the NAMES.DIRECTORY_PATH parameter was not defined, “Easy Connect” would be active
# We went with SQL * Plus in NOLOG mode for testing
sqlplus / nolog
– The format of the connection with EZCONNET is “CONNECT username @ [//] host [: port] [/ [service_name] [: server]] [/ instance_name]]”
– We make several test connections (we need double quotes when not introduce the password)
- Easier Chain CONNECT system @ "ocm.dbajunior.com/OCM" - Including the password CONNECT firstname.lastname@example.org/OCM - We can specify the type of connection (DEDICATED / SHARED / POOLED) CONNECT system @ "ocm.dbajunior.com:1521/OCM:DEDICATED" - We can specify the instance you want to connect CONNECT system @ "ocm.dbajunior.com:1521/OCM:DEDICATED/OCM"
# We can specify the default SERVICE in the listener.ora file
# Add the following line to the file $ ORACLE_HOME / network / admin / listener.ora DEFAULT_SERVICE_LISTENER = OCM # Recargamos LISTENER settings lsnrctl reload LISTENER # Now let's make a connection from outside of SQL * Plus (OCM will attack the service) sqlplus email@example.com # Pay attention to these examples (with and without password) # In the second example we have to escape double quotation marks to avoid the error (ORA-1017) sqlplus system / ********** @ ocm.dbajunior.com:1521/OCM sqlplus system @ "ocm.dbajunior.com: 1521 / OCM " # To undo changes erase this line of file $ ORACLE_HOME / network / admin / listener.ora DEFAULT_SERVICE_LISTENER = OCM # Recargamos LISTENER parameters lsnrctl reload