ora error code ORA-12162: TNS:net service name is incorrectly specified
FranklinFaces.com
FranklinFaces.com - Oracle & SQL Server Database Forums for all IT Professionals
 Home          Members     Calendar     Who's On

Welcome Guest ( Login | Register )
        



ora error code ORA-12162: TNS:net service... Expand / Collapse
Message
Posted 6/14/2010 4:41:13 PM Post #339
 

Supreme BeingSupreme BeingSupreme BeingSupreme BeingSupreme BeingSupreme BeingSupreme BeingSupreme Being
ora error

ORA-12162:

TNS:net service name is incorrectly specified

ORA-12162:

TNS:net service name is incorrectly specified
Cause:The connect descriptor corresponding to the net service name in TNSNAMES.ORA or in the directory server (Oracle Internet Directory) is incorrectly specified.
Action:If using local naming make sure there are no syntax errors in the corresponding connect descriptor in the TNSNAMES.ORA file. If using directory naming check the information provided through the administration used for directory naming.

Posted 6/14/2010 4:41:47 PM Post #340
 

Supreme BeingSupreme BeingSupreme BeingSupreme BeingSupreme BeingSupreme BeingSupreme BeingSupreme Being
I installed oracle 10g but the oracle user is an ldap user and its home directory is on a nfs server.

The installation went ok. the inventory was created locally.

the profile exists on the nfs server.

When I do sqlplus "/as sysdba", I get

*************************
ERROR:
ORA-12162: TNS:net service name is incorrectly specified
*************************

the tnsping returns a reponse and the ORACLE_SID, ORACLE_HOME and LD_LIBRARY_PATH and PATH are all set in the profile and they are correctly set (when doing echo).

What am I missing?

Usually all the installations went ok but I was using a local user. This time I am using a remote user.

Posted 6/14/2010 4:41:59 PM Post #341
 

Supreme BeingSupreme BeingSupreme BeingSupreme BeingSupreme BeingSupreme BeingSupreme BeingSupreme Being
Although not explicitly forbidden,such an environment is not recommended. The error says Oracle cannot interpret ORACLE_SID,the OS itself (echo $ORACLE_SID) may have another point of view.
Posted 6/14/2010 4:42:12 PM Post #342
 

Supreme BeingSupreme BeingSupreme BeingSupreme BeingSupreme BeingSupreme BeingSupreme BeingSupreme Being
I added export before each environment variable.

the error changed:

sqlplus "/as sysdba"

ERROR:
ORA-01031: insufficient privileges
Posted 6/14/2010 4:42:23 PM Post #343
 

Supreme BeingSupreme BeingSupreme BeingSupreme BeingSupreme BeingSupreme BeingSupreme BeingSupreme Being
"Please run $ORACLE_HOME/install/changePerm.sh. This is if you want to invoke sqlplus from other than oracle unix account"
Posted 6/14/2010 4:42:57 PM Post #344
 

Supreme BeingSupreme BeingSupreme BeingSupreme BeingSupreme BeingSupreme BeingSupreme BeingSupreme Being
 manually started my listener by going to $ORACLE_HOME/bin $ lsnrctl and then LSNRCTL>start and then started my DB

Step1.
If you have multiple listeners, then go to .$ORACLE_HOME/network/admin/tnsnames.ora, if your listener name are LNSRXXX and LSNRYYY, and the DB uses LSNRYYY then,
LSNRCTL>start LSNRYYY
LSNRCTL> set current_listener LSNRYYY

If you have only the default listener then LSNRCTL>start would suffice

Step 2.
Next step set env variables , $ORACLE_HOME and $ORACLE_SID and finally start the db by

ORACLE_HOME/bin$./sqlplus /nolog
SQL>conn / as sysdba
Posted 6/14/2010 4:44:01 PM Post #345
 

Supreme BeingSupreme BeingSupreme BeingSupreme BeingSupreme BeingSupreme BeingSupreme BeingSupreme Being
I am executing the below command as Oracle owner user, on the same host. But getting the following error.


SQL> connect / as sysdba
ERROR:
ORA-12162: TNS:net service name is incorrectly specified
Posted 6/14/2010 4:44:11 PM Post #346
 

Supreme BeingSupreme BeingSupreme BeingSupreme BeingSupreme BeingSupreme BeingSupreme BeingSupreme Being
12162, 00000, "TNS:service name is incorrectly specified"
// *Cause: The connect descriptor corresponding to the service name in
// TNSNAMES.ORA is incorrectly specified.
// *Action: Make sure there are no syntax errors in the connect descriptor.
// Particularly look for unmatched parentheses or stray characters.
// Any error in a TNSNAMES.ORA file makes it unusable. See Chapter 4
// in the SQL*Net V2 Administrator's Guide.
Posted 6/14/2010 4:44:33 PM Post #347
 

Supreme BeingSupreme BeingSupreme BeingSupreme BeingSupreme BeingSupreme BeingSupreme BeingSupreme Being
Look into your environment. You may have set default tns string ( I remember that can be done)
If not, trace the client and see what happens

TNS_ADMIN would be that parameter

« Prev Topic | Next Topic »


Reading This Topic Expand / Collapse
Active Users: 0 (0 guests, 0 members, 0 anonymous members)
No members currently viewing this topic.
Forum Moderators: silencer

Permissions Expand / Collapse

All times are GMT -5:00, Time now is 10:21am

Powered By InstantForum.NET v4.1.4 © 2012
Execution: 0.112. 13 queries. Compression Disabled.
Contextual Links