TNS_ADMIN

  • From: "Rusnak, George A. (SEC-Lee) CTR" <george.rusnak@xxxxxxxx>
  • To: <oracle-l@xxxxxxxxxxxxx>
  • Date: Thu, 4 Nov 2004 10:59:11 -0500

Group,

HOST MACHINE: HP-UX  B.11.11 U 9000/800 
ORACLE :  Oracle9i Enterprise Edition Rel. 9.2.0.5.0 - 64 bit
LISTENER: Version 10.1.0.2.0
TNSNAMES.ORA: ls -lai $ORACLE_HOME/network/admin/tnsnames.ora
                      -rw-r--r--   1 oracle     dba      6546 Nov  3 13:11 
/opt/oracle/product/9.2.0/network/admin/tnsnames.ora
PROBLEM:
  rusnakga>unset TNS_ADMIN
  SQL>    select count(*) 
              from ses_army@csucmis;
              from ses_army@csucmis
                                       *
        ERROR at line 2:
        ORA-12154: TNS:could not resolve service name

   rusnakga>export TNS_ADMIN=$ORACLE_HOME/network/admin
   SQL> select count(*)
             from ses_army@csucmis;

              COUNT(*)
              ----------
                 3

QUESTION:
 The tnsnames.ora is in the default location and it is not found until 
TNS_ADMIN is set. How do I find out where TNS_ADMIN is pointing at the system 
level, if there is such a thing ? Why do I have to set TNS_ADMIN at the session 
level ?????

TIA,

Al Rusnak
Oracle Certified Professional
DBA - CISIS, Computer Operations

* 804-734-8210
* george.rusnak@xxxxxxxx


--
//www.freelists.org/webpage/oracle-l

Other related posts: