SqlPlus on mac osx 10.6 doesn't work
Posted
by lesce
on Stack Overflow
See other posts from Stack Overflow
or by lesce
Published on 2010-04-19T23:33:07Z
Indexed on
2010/04/20
9:13 UTC
Read the original article
Hit count: 456
When i try to run this
#sqlplus system@orcl
it gives me this error
SQL*Plus: Release 10.1.0.3.0 - Production on Tue Apr 20 02:24:41 2010
Copyright (c) 1982, 2004, Oracle. All rights reserved.
Enter password:
ERROR:
ORA-12154: TNS:could not resolve the connect identifier specified
the oracle server is working , I can connect through SQLDeveloper
My .profile looks like this
export PATH=/opt/local/bin:/opt/local/sbin:$PATH
# Setting PATH for Python 3.1
# The orginal version is saved in .profile.pysave
PATH="/Library/Frameworks/Python.framework/Versions/3.1/bin:${PATH}"
DYLD_LIBRARY_PATH=/Users/lesce/instantclient
export TNS_ADMIN=/Users/lesce/instantclient
export ORACLE_SID="orcl"
export DYLD_LIBRARY_PATH
export PATH=$PATH:/Users/lesce/instantclient
tnsnames.ora
ORCL =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521))
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = orcl)
)
)
listener.ora
SID_LIST_LISTENER =
(SID_LIST =
(SID_DESC =
(SID_NAME = PLSExtProc)
(ORACLE_HOME = /Users/oracle/oracle/product/10.2.0/db_1)
(PROGRAM = extproc)
)
(SID_DESC =
(SID_NAME = orcl)
(ORACLE_HOME = /Users/oracle/oracle/product/10.2.0/db_1)
)
)
LISTENER =
(DESCRIPTION_LIST =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521))
(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC0))
)
)
My SqlDeveloper configuration
username : sys
role : sysdba
connection type : basic
hostname : localhost
port : 1521
sid : orcl
© Stack Overflow or respective owner