Sqlplus not find tnsnames.ora

Hey guys,.

I have a question about oracle client and the tnsnames.ora file. Basically, I have the customer put in place and it seems to work on the use of sqldeveloper such that she can see the tnsnames.ora file in the drop-down list but I don't seem to be able to connect using sql, which makes me think that it cannot find the file ora. I set the env as:
DON@donkeyhome:/usr/lib/oracle$ echo $PATH
.:/usr/lib/oracle/oracle_client/bin:.:/usr/lib/jvm/jdk/bin:/usr/lib/jvm/jdk/jre/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games
DON@donkeyhome:/usr/lib/oracle$ echo $ORACLE_HOME
/usr/lib/oracle/oracle_client
DON@donkeyhome:/usr/lib/oracle$ echo $TNS_ADMIN
/usr/lib/oracle/network/admin
DON@donkeyhome:/usr/lib/oracle$
Sql developer seems to work with the tns ok but not sqlplus:

DON@donkeyhome:/usr/lib/oracle$ sqlplus SYSADM@STUDA1

SQL*Plus: Release 10.2.0.1.0 - Production on Tue Jan 6 16:26:50 2009

Copyright (c) 1982, 2005, Oracle.  All rights reserved.

Enter password:
ERROR:
ORA-12154: TNS:could not resolve the connect identifier specified
Any help with this would be greatly appreciated that I had this problem and commented on many forums for about 1 month now :(

Dave was soon

Published by: wheelie on January 5, 2009 22:28

Published by: wheelie on January 7, 2009 22:32

Wheelie,

I understand that you have tried many options to solve and in general, this mistake is easy to correct. Bad especially as a tnsnames.ora entry, you can also try dos2unix tnsnames.ora see if it removes all special characters and it changes size.

Concerns

Tags: Database

Similar Questions

  • DBD::Oracle and instant client - can't find tnsnames.ora

    Hi all! :-)

    Guys, please, help!

    My OS: CentOS 6.6, i386

    Installed:

    Oracle - instantclient12.1 - basic - 12.1.0.2.0 - 1.i386

    Oracle - instantclient12.1 - devel - 12.1.0.2.0 - 1.i386

    Oracle - instantclient12.1 - sqlplus - 12.1.0.2.0 - 1.i386

    Perl-DBI-1, 609 - 4.el6.i686

    and last perl-DBD-Oracle-1, 74-CPAN.

    Apache 2.2.15, mod_perl 2.0.4

    SELinux disabled.

    ORACLE_HOME = usr/lib/oracle/12.1/client, LD_LIBRARY_PATH = /usr/lib/oracle/12.1/client/lib

    tnsnames.ora exist in /usr/lib/oracle/12.1/client/network/admin

    I wrote a simple perl script to test the connection:

    use strict;
    use DBI;
    
    my $dbh = DBI ->connect("dbi:Oracle:crm", 'login', 'password',{RaiseError => 1} );
    $dbh->disconnect();
    
    

    When I try to run script command line - everything isn't ok, no errors (Yes, I can run queries, etc... )

    But!

    With apache, I get an error:

    DBI connect('crm','login',...) failed: ORA-12154: TNS: could not resolve the connect identifier specified (DBD ERROR: OCIServerAttach) in /opt/otrs/bin/cgi-bin/oratest.pl on line 9

    I am trying to add ORACLE_HOME with PerlSetEnv and script see (I checked through % ENV), but no luck.

    Probably easier to use EZconnect instead of tnsnames.ora:

    $machine = 'my.oracle.database.com';
     $port = 1521;
     $sid = 'my_sid';
     $dbh = DBI->connect("dbi:Oracle://$machine:$port/$sid", $user, $pass) ||
      die "Failed to connect: $DBI::errstr\n";
    
  • Could not find the ORA error behind this failed task

    Hi friends,

    In the part of the load, I got a task that failed following two as
    SDE_ORA_Stage_Reverse_GLRevenueFact_DiffManDerive
    SDE_ORA_Stage_Reverse_ARTransactionFact_DiffManDerive
    I found the log file for the task that has failed two above to the location (D > orahome > 10gR3_1 > bifoundation > dac > Journal)

    For, SDE_ORA_Stage_Reverse_GLRevenueFact_DiffManDerive I found the newspaper below
    All Task Batches
         Preceding Actions
              ------------------------------
              SDE_ORA_Stage_Reverse_GLRevenueFact_DiffManDerive:PRECEDING_ACTION:"Truncate Target Table" template
              ------------------------------
              
              
              2012-07-30 16:17:12.625 SDE_ORA_Stage_Reverse_GLRevenueFact_DiffManDerive:PRECEDING_ACTION:"Truncate Target Table" template has started.
              
              
              Running Custom Sql list SDE_ORA_Stage_Reverse_GLRevenueFact_DiffManDerive:PRECEDING_ACTION:"Truncate Target Table" template
              
    
    Source: "BIAPPS"
              Tables:
                   W_GL_ACCOUNT_D
                   W_ORA_GLREVAGGR_F_TMP
                   W_ORA_GROUP_ACCOUNT_NUM_D_TMP
                   W_ORA_GL_REVN_GL_F_TMP
    
    Target: "BIAPPS"
              Tables:
                   W_GL_REVN_FS
    
    Default retries for this custom SQL is 1.
    
    executing sql (Truncate:W_GL_REVN_FS:BIAPPS)
    TRUNCATE TABLE W_GL_REVN_FS
    
    "Truncate" for W_GL_REVN_FS succeeded on "BIAPPS"
    
    Succeeded
    
    
              
              Successfully executed : SDE_ORA_Stage_Reverse_GLRevenueFact_DiffManDerive:PRECEDING_ACTION:"Truncate Target Table" template
              
              (Number of retries : 1)
              
              Commands executed : 
              SDE_ORA_Stage_Reverse_GLRevenueFact_DiffManDerive:PRECEDING_ACTION:"Truncate Target Table" template
              
              2012-07-30 16:17:12.75 SDE_ORA_Stage_Reverse_GLRevenueFact_DiffManDerive:PRECEDING_ACTION:"Truncate Target Table" template has finished execution with Completed status.
              ------------------------------
    
         Truncate Batch
              ------------------------------
              TRUNCATE TABLE:W_GL_REVN_FS
              ------------------------------
              
              
              2012-07-30 16:17:12.828 TRUNCATE TABLE:W_GL_REVN_FS has started.
              
              
              Successfully executed : TRUNCATE TABLE:W_GL_REVN_FS
              
              (Number of retries : 1)
              
              Commands executed : 
              TRUNCATE TABLE W_GL_REVN_FS
              
              2012-07-30 16:17:12.828 TRUNCATE TABLE:W_GL_REVN_FS has finished execution with Completed status.
              ------------------------------
    
         Informatica Session Batch
              Upon Failure Restart Actions
                   ------------------------------
                   TRUNCATE TABLE:W_GL_REVN_FS
                   ------------------------------
                   
                   
                   2012-07-30 16:17:12.828 TRUNCATE TABLE:W_GL_REVN_FS has started.
                   
                   
                   Successfully executed : TRUNCATE TABLE:W_GL_REVN_FS
                   
                   (Number of retries : 1)
                   
                   Commands executed : 
                   TRUNCATE TABLE W_GL_REVN_FS
                   
                   2012-07-30 16:17:12.828 TRUNCATE TABLE:W_GL_REVN_FS has finished execution with Completed status.
                   ------------------------------
              ------------------------------
              INFORMATICA TASK:SDE_ORA11510_Adaptor:SDE_ORA_Stage_GLRevenueFact_DiffManDerive:(Source : FULL Target : FULL)
              ------------------------------
              
              
              2012-07-30 16:17:12.843 INFORMATICA TASK:SDE_ORA11510_Adaptor:SDE_ORA_Stage_GLRevenueFact_DiffManDerive:(Source : FULL Target : FULL) has started.
              
              
              
              ANOMALY INFO::: Error while executing : INFORMATICA TASK:SDE_ORA11510_Adaptor:SDE_ORA_Stage_GLRevenueFact_DiffManDerive:(Source : FULL Target : FULL)
              MESSAGE:::
              Irrecoverable Error
              pmcmd startworkflow -sv Oracle_BI_DW_Base_Integration_Service -d Domain_BIAPPS -u Administrator -p **** -f SDE_ORA11510_Adaptor  -lpf D:\Informatica\PowerCenter8.6.1\server\infa_shared\SrcFiles\\BIAPPS.BIAPPS.SDE_ORA11510_Adaptor.SDE_ORA_Stage_GLRevenueFact_DiffManDerive.txt SDE_ORA_Stage_GLRevenueFact_DiffManDerive
              Status Desc : Failed
              WorkFlowMessage : 
              =====================================
              STD OUTPUT
              =====================================
              
              Informatica(r) PMCMD, version [8.6.1 HotFix6], build [319.0622], Windows 32-bit
              Copyright (c) Informatica Corporation 1994 - 2009
              All Rights Reserved.
              
              Invoked at Mon Jul 30 16:17:39 2012
              
              Connected to Integration Service: [Oracle_BI_DW_Base_Integration_Service].
              Integration Service status: [Running]
              Integration Service startup time: [Sun Jul 29 10:41:49 2012]
              Integration Service current time: [Mon Jul 30 16:17:39 2012]
              Folder: [SDE_ORA11510_Adaptor]
              Workflow: [SDE_ORA_Stage_GLRevenueFact_DiffManDerive] version [1].
              Workflow run status: [Failed]
              Workflow run error code: [36331]
              Workflow run error message: [WARNING: Session task instance [SDE_ORA_Stage_GLRevenueFact_DiffManDerive] failed and its "fail parent if this task fails" setting is turned on.  So, Workflow [SDE_ORA_Stage_GLRevenueFact_DiffManDerive] will be failed.]
              Workflow run id [2233].
              Start time: [Mon Jul 30 16:17:18 2012]
              End time: [Mon Jul 30 16:17:24 2012]
              Workflow log file: [D:\Informatica\PowerCenter8.6.1\server\infa_shared\WorkflowLogs\SDE_ORA_Stage_GLRevenueFact_DiffManDerive.log]
              Workflow run type: [User request]
              Run workflow as user: [Administrator]
              Run workflow with Impersonated OSProfile in domain: []
              Integration Service: [Oracle_BI_DW_Base_Integration_Service]
              Disconnecting from Integration Service
              
              Completed at Mon Jul 30 16:17:39 2012
              
              =====================================
              ERROR OUTPUT
              =====================================
              
              Error Message : Unknown reason for error code 36331
              ErrorCode : 36331
              EXCEPTION CLASS::: com.siebel.analytics.etl.etltask.IrrecoverableException
              
              com.siebel.analytics.etl.etltask.InformaticaTask.doExecute(InformaticaTask.java:183)
              com.siebel.analytics.etl.etltask.GenericTaskImpl.doExecuteWithRetries(GenericTaskImpl.java:411)
              com.siebel.analytics.etl.etltask.GenericTaskImpl.execute(GenericTaskImpl.java:307)
              com.siebel.analytics.etl.etltask.GenericTaskImpl.execute(GenericTaskImpl.java:214)
              com.siebel.analytics.etl.etltask.GenericTaskImpl.run(GenericTaskImpl.java:586)
              com.siebel.analytics.etl.taskmanager.XCallable.call(XCallable.java:63)
              java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
              java.util.concurrent.FutureTask.run(FutureTask.java:138)
              java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
              java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
              java.util.concurrent.FutureTask.run(FutureTask.java:138)
              java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:885)
              java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:907)
              java.lang.Thread.run(Thread.java:619)
              
              (Number of retries : 1)
              
              pmcmd startworkflow -sv Oracle_BI_DW_Base_Integration_Service -d Domain_BIAPPS -u Administrator -p **** -f SDE_ORA11510_Adaptor  -lpf D:\Informatica\PowerCenter8.6.1\server\infa_shared\SrcFiles\\BIAPPS.BIAPPS.SDE_ORA11510_Adaptor.SDE_ORA_Stage_GLRevenueFact_DiffManDerive.txt SDE_ORA_Stage_GLRevenueFact_DiffManDerive
              
              2012-07-30 16:17:40.109 INFORMATICA TASK:SDE_ORA11510_Adaptor:SDE_ORA_Stage_GLRevenueFact_DiffManDerive:(Source : FULL Target : FULL) has finished execution with Failed status.
              ------------------------------
    
         Analyze Table Batch
              ------------------------------
              ANALYZE TABLE:W_GL_REVN_FS
              ------------------------------
              Not Executed
              ------------------------------
    For SDE_ORA_Stage_Reverse_ARTransactionFact_DiffManDerive I found the newspaper below
    All Task Batches
         Preceding Actions
              ------------------------------
              SDE_ORA_Stage_Reverse_ARTransactionFact_DiffManDerive:PRECEDING_ACTION:"Truncate Target Table" template
              ------------------------------
              
              
              2012-07-30 16:17:12.703 SDE_ORA_Stage_Reverse_ARTransactionFact_DiffManDerive:PRECEDING_ACTION:"Truncate Target Table" template has started.
              
              
              Running Custom Sql list SDE_ORA_Stage_Reverse_ARTransactionFact_DiffManDerive:PRECEDING_ACTION:"Truncate Target Table" template
              
    
    Source: "BIAPPS"
              Tables:
                   W_ORA_AR_XACTS_GL_F_TMP
                   W_ORA_ARAGGR_F_TMP
    
    Target: "BIAPPS"
              Tables:
                   W_AR_XACT_FS
    
    Default retries for this custom SQL is 1.
    
    executing sql (Truncate:W_AR_XACT_FS:BIAPPS)
    TRUNCATE TABLE W_AR_XACT_FS
    
    "Truncate" for W_AR_XACT_FS succeeded on "BIAPPS"
    
    Succeeded
    
    
              
              Successfully executed : SDE_ORA_Stage_Reverse_ARTransactionFact_DiffManDerive:PRECEDING_ACTION:"Truncate Target Table" template
              
              (Number of retries : 1)
              
              Commands executed : 
              SDE_ORA_Stage_Reverse_ARTransactionFact_DiffManDerive:PRECEDING_ACTION:"Truncate Target Table" template
              
              2012-07-30 16:17:12.968 SDE_ORA_Stage_Reverse_ARTransactionFact_DiffManDerive:PRECEDING_ACTION:"Truncate Target Table" template has finished execution with Completed status.
              ------------------------------
    
         Truncate Batch
              ------------------------------
              TRUNCATE TABLE:W_AR_XACT_FS
              ------------------------------
              
              
              2012-07-30 16:17:13.0 TRUNCATE TABLE:W_AR_XACT_FS has started.
              
              
              Successfully executed : TRUNCATE TABLE:W_AR_XACT_FS
              
              (Number of retries : 1)
              
              Commands executed : 
              TRUNCATE TABLE W_AR_XACT_FS
              
              2012-07-30 16:17:13.0 TRUNCATE TABLE:W_AR_XACT_FS has finished execution with Completed status.
              ------------------------------
    
         Informatica Session Batch
              Upon Failure Restart Actions
                   ------------------------------
                   TRUNCATE TABLE:W_AR_XACT_FS
                   ------------------------------
                   
                   
                   2012-07-30 16:17:13.0 TRUNCATE TABLE:W_AR_XACT_FS has started.
                   
                   
                   Successfully executed : TRUNCATE TABLE:W_AR_XACT_FS
                   
                   (Number of retries : 1)
                   
                   Commands executed : 
                   TRUNCATE TABLE W_AR_XACT_FS
                   
                   2012-07-30 16:17:13.0 TRUNCATE TABLE:W_AR_XACT_FS has finished execution with Completed status.
                   ------------------------------
              ------------------------------
              INFORMATICA TASK:SDE_ORA11510_Adaptor:SDE_ORA_Stage_ARTransactionFact_DiffManDerive:(Source : FULL Target : FULL)
              ------------------------------
              
              
              2012-07-30 16:17:13.0 INFORMATICA TASK:SDE_ORA11510_Adaptor:SDE_ORA_Stage_ARTransactionFact_DiffManDerive:(Source : FULL Target : FULL) has started.
              
              
              
              ANOMALY INFO::: Error while executing : INFORMATICA TASK:SDE_ORA11510_Adaptor:SDE_ORA_Stage_ARTransactionFact_DiffManDerive:(Source : FULL Target : FULL)
              MESSAGE:::
              Irrecoverable Error
              pmcmd startworkflow -sv Oracle_BI_DW_Base_Integration_Service -d Domain_BIAPPS -u Administrator -p **** -f SDE_ORA11510_Adaptor  -lpf D:\Informatica\PowerCenter8.6.1\server\infa_shared\SrcFiles\\BIAPPS.BIAPPS.SDE_ORA11510_Adaptor.SDE_ORA_Stage_ARTransactionFact_DiffManDerive.txt SDE_ORA_Stage_ARTransactionFact_DiffManDerive
              Status Desc : Failed
              WorkFlowMessage : 
              =====================================
              STD OUTPUT
              =====================================
              
              Informatica(r) PMCMD, version [8.6.1 HotFix6], build [319.0622], Windows 32-bit
              Copyright (c) Informatica Corporation 1994 - 2009
              All Rights Reserved.
              
              Invoked at Mon Jul 30 16:17:39 2012
              
              Connected to Integration Service: [Oracle_BI_DW_Base_Integration_Service].
              Integration Service status: [Running]
              Integration Service startup time: [Sun Jul 29 10:41:49 2012]
              Integration Service current time: [Mon Jul 30 16:17:39 2012]
              Folder: [SDE_ORA11510_Adaptor]
              Workflow: [SDE_ORA_Stage_ARTransactionFact_DiffManDerive] version [1].
              Workflow run status: [Failed]
              Workflow run error code: [36331]
              Workflow run error message: [WARNING: Session task instance [SDE_ORA_Stage_ARTransactionFact_DiffManDerive] failed and its "fail parent if this task fails" setting is turned on.  So, Workflow [SDE_ORA_Stage_ARTransactionFact_DiffManDerive] will be failed.]
              Workflow run id [2236].
              Start time: [Mon Jul 30 16:17:19 2012]
              End time: [Mon Jul 30 16:17:24 2012]
              Workflow log file: [D:\Informatica\PowerCenter8.6.1\server\infa_shared\WorkflowLogs\SDE_ORA_Stage_ARTransactionFact_DiffManDerive.log]
              Workflow run type: [User request]
              Run workflow as user: [Administrator]
              Run workflow with Impersonated OSProfile in domain: []
              Integration Service: [Oracle_BI_DW_Base_Integration_Service]
              Disconnecting from Integration Service
              
              Completed at Mon Jul 30 16:17:39 2012
              
              =====================================
              ERROR OUTPUT
              =====================================
              
              Error Message : Unknown reason for error code 36331
              ErrorCode : 36331
              EXCEPTION CLASS::: com.siebel.analytics.etl.etltask.IrrecoverableException
              
              com.siebel.analytics.etl.etltask.InformaticaTask.doExecute(InformaticaTask.java:183)
              com.siebel.analytics.etl.etltask.GenericTaskImpl.doExecuteWithRetries(GenericTaskImpl.java:411)
              com.siebel.analytics.etl.etltask.GenericTaskImpl.execute(GenericTaskImpl.java:307)
              com.siebel.analytics.etl.etltask.GenericTaskImpl.execute(GenericTaskImpl.java:214)
              com.siebel.analytics.etl.etltask.GenericTaskImpl.run(GenericTaskImpl.java:586)
              com.siebel.analytics.etl.taskmanager.XCallable.call(XCallable.java:63)
              java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
              java.util.concurrent.FutureTask.run(FutureTask.java:138)
              java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
              java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
              java.util.concurrent.FutureTask.run(FutureTask.java:138)
              java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:885)
              java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:907)
              java.lang.Thread.run(Thread.java:619)
              
              (Number of retries : 1)
              
              pmcmd startworkflow -sv Oracle_BI_DW_Base_Integration_Service -d Domain_BIAPPS -u Administrator -p **** -f SDE_ORA11510_Adaptor  -lpf D:\Informatica\PowerCenter8.6.1\server\infa_shared\SrcFiles\\BIAPPS.BIAPPS.SDE_ORA11510_Adaptor.SDE_ORA_Stage_ARTransactionFact_DiffManDerive.txt SDE_ORA_Stage_ARTransactionFact_DiffManDerive
              
              2012-07-30 16:17:40.453 INFORMATICA TASK:SDE_ORA11510_Adaptor:SDE_ORA_Stage_ARTransactionFact_DiffManDerive:(Source : FULL Target : FULL) has finished execution with Failed status.
              ------------------------------
    
         Analyze Table Batch
              ------------------------------
              ANALYZE TABLE:W_AR_XACT_FS
              ------------------------------
              Not Executed
              ------------------------------
    But the error, I couldn't analyze the exact ORA error of the foregoing two session that does not. Can you friends, help me with the cause of this error so that I can recitfy this inorder to errors for my task failed to run correctly.

    Thanks in advance.

    Kind regards
    Saro

    means that 'If this task fails that be parent' if the session fails, you're in the failure of the workflow state. DAC knows only the workflow state.
    If you run the workflow in WFM, mark the task as completed in DAC.

    Tasks of children (Drop, Create, Informatica) DAC-> current Run-> in the lower pane, select all tasks, and then click the Details button
    a pop window shows the list of tasks if exists elsewhere only a task will show you that is task Informatica.

    Right-click on the task-> update records-> (the State of the list Select)

    Hope this helps

  • TNSNAMES.ora in Linux OS

    I installed oracle using the database. / Linux dbca.

    When I connect to oracle...

    1 sys as sysdba
    ORA - service 12162:TNS name: net is incorrectly specified

    2 sys@soni as sysdba
    ORA-12154: TNS: could not resolve the connect identifier specified

    There is not any TNSNAMES.ora file in the NETWORK folder.

    Can someone tell me to solve this problem in Linux? (I am new to the Linux operating system)

    Hello
    You see that your PATH variable does not contain the path to the bin of the Oracle home directory.

    Oh, after changes in the .bash_profile, you disconnected and connected again, so that changes in .bash_profile may take effect?

    Disconnect then reconnect and then check sqlplus from the terminal.

    Also if the problem persists, then paste the above values again.

    concerning

  • Oracle RAC: not updated by srvctl tnsnames.ora

    Hello

    On both Oracle 10 g R2 RAC conditions 4.5 Linux nodes, I published with success the following commands to add a new service, but I don't see any changes on the tnsnames.ora file to add the created service connection descriptors. Is there anything missing? The tnsnames.ora file should not be updated by the srvctl?
    [oracle@rac2 admin]$ add service -d rac -s biserv -r rac1 -a rac2 -P PRECONNECT
    [oracle@rac2 admin]$ srvctl start service -d rac -s biserv
    
    [oracle@rac2 admin]$ crstat
    HA Resource                                   Target     State
    -----------                                   ------     -----
    ora.rac.biserv.cs                             ONLINE     ONLINE on rac1
    ora.rac.biserv.rac1.srv                       ONLINE     ONLINE on rac1
    ora.rac.db                                    ONLINE     ONLINE on rac1
    ora.rac.hrserv.cs                             ONLINE     ONLINE on rac1
    ora.rac.hrserv.rac1.srv                       ONLINE     ONLINE on rac1
    ora.rac.hrserv.rac2.srv                       ONLINE     ONLINE on rac2
    ora.rac.oeserv.cs                             ONLINE     ONLINE on rac1
    ora.rac.oeserv.rac1.srv                       ONLINE     ONLINE on rac1
    ora.rac.oeserv.rac2.srv                       ONLINE     ONLINE on rac2
    ora.rac.rac1.inst                             ONLINE     ONLINE on rac1
    ora.rac.rac2.inst                             ONLINE     ONLINE on rac2
    ora.rac1.ASM1.asm                             ONLINE     ONLINE on rac1
    ora.rac1.LISTENER_RAC1.lsnr                   ONLINE     ONLINE on rac1
    ora.rac1.gsd                                  ONLINE     ONLINE on rac1
    ora.rac1.ons                                  ONLINE     ONLINE on rac1
    ora.rac1.vip                                  ONLINE     ONLINE on rac1
    ora.rac2.ASM2.asm                             ONLINE     ONLINE on rac2
    ora.rac2.LISTENER_RAC2.lsnr                   ONLINE     ONLINE on rac2
    ora.rac2.gsd                                  ONLINE     ONLINE on rac2
    ora.rac2.ons                                  ONLINE     ONLINE on rac2
    ora.rac2.vip                                  ONLINE     ONLINE on rac2
    
    [oracle@rac2 admin]$ cat tnsnames.ora
    # tnsnames.ora.rac2 Network Configuration File: /u01/app/oracle/product/10.2.0/db_1/network/admin/tnsnames.ora.rac2
    # Generated by Oracle configuration tools.
    
    RAC =
      (DESCRIPTION =
        (ADDRESS = (PROTOCOL = TCP)(HOST = rac1-vip.mydomain.com)(PORT = 1521))
        (ADDRESS = (PROTOCOL = TCP)(HOST = rac2-vip.mydomain.com)(PORT = 1521))
        (LOAD_BALANCE = yes)
        (CONNECT_DATA =
          (SERVER = DEDICATED)
          (SERVICE_NAME = rac)
        )
      )
    
    OESERV =
      (DESCRIPTION =
        (ADDRESS = (PROTOCOL = TCP)(HOST = rac1-vip.mydomain.com)(PORT = 1521))
        (ADDRESS = (PROTOCOL = TCP)(HOST = rac2-vip.mydomain.com)(PORT = 1521))
        (LOAD_BALANCE = yes)
        (CONNECT_DATA =
          (SERVER = DEDICATED)
          (SERVICE_NAME = oeserv)
          (FAILOVER_MODE =
            (TYPE = SELECT)
            (METHOD = BASIC)
            (RETRIES = 180)
            (DELAY = 5)
          )
        )
      )
    
    LISTENERS_RAC =
      (ADDRESS_LIST =
        (ADDRESS = (PROTOCOL = TCP)(HOST = rac1-vip.mydomain.com)(PORT = 1521))
        (ADDRESS = (PROTOCOL = TCP)(HOST = rac2-vip.mydomain.com)(PORT = 1521))
      )
    
    RAC2 =
      (DESCRIPTION =
        (ADDRESS = (PROTOCOL = TCP)(HOST = rac2-vip.mydomain.com)(PORT = 1521))
        (CONNECT_DATA =
          (SERVER = DEDICATED)
          (SERVICE_NAME = rac)
          (INSTANCE_NAME = rac2)
        )
      )
    
    RAC1 =
      (DESCRIPTION =
        (ADDRESS = (PROTOCOL = TCP)(HOST = rac1-vip.mydomain.com)(PORT = 1521))
        (CONNECT_DATA =
          (SERVER = DEDICATED)
          (SERVICE_NAME = rac)
          (INSTANCE_NAME = rac1)
        )
      )
    
    HRSERV =
      (DESCRIPTION =
        (ADDRESS = (PROTOCOL = TCP)(HOST = rac1-vip.mydomain.com)(PORT = 1521))
        (ADDRESS = (PROTOCOL = TCP)(HOST = rac2-vip.mydomain.com)(PORT = 1521))
        (LOAD_BALANCE = yes)
        (CONNECT_DATA =
          (SERVER = DEDICATED)
          (SERVICE_NAME = hrserv)
          (FAILOVER_MODE =
            (TYPE = SESSION)
            (METHOD = BASIC)
            (RETRIES = 180)
            (DELAY = 5)
          )
        )
      )
    
    EXTPROC_CONNECTION_DATA =
      (DESCRIPTION =
        (ADDRESS_LIST =
          (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC0))
        )
        (CONNECT_DATA =
          (SID = PLSExtProc)
          (PRESENTATION = RO)
        )
      )

    Srvctl manages the CRS (OCR), but does not alter the tnsnames.ora.

    You can use netca to manage tnsnames.ora, but personally, I find it easier to manually edit the entries.

  • Net Oracle does not read the tnsnames.ora file.

    I am running 11.2.0.3 on Solaris 10 SPARC x 64. I'm trying to configure oracle net for a new database on hold in order to be able to use rman duplicate to create. LDAP is what we mainly use for all of our connections and, possibly, what I could use very well for my goal of rman duplication. But, I fear that I do nothing seems to allow me to read the tnsnames.ora file.

    My SQLNET. ORA file is as follows:

    NAMES. DIRECTORY_PATH = (LDAP, TNSNAMES)

    NAMES. DEFAULT_DOMAIN = mydomain.com

    My TNSNAMES file. ORA file is as follows on both servers:

    WLDB_HERE =
    (DESCRIPTION =
    (ADDRESS_LIST =
    (ADDRESS = (PROTOCOL = TCP)(HOST = primary_server) (PORT = 1521))
    )
    (CONNECT_DATA = (SERVICE_NAME = wldb_here.mydomain.com))
    )

    WLDB_THERE =
    (DESCRIPTION =
    (ADDRESS_LIST =
    (ADDRESS = (PROTOCOL = TCP)(HOST = standby_server) (PORT = 1521))
    )
    (CONNECT_DATA = (SERVICE_NAME = wldb_there.mydomain.com))
    )

    I have a static entry in the remote listener.ora file so I can connect to create the instance:

    SID_LIST_LISTENER =
    (SID_LIST =
    (SID_DESC =
    (GLOBAL_DBNAME = wldb_there.mydomain.com)
    (ORACLE_HOME = / u01/app/oracle/product/OraHome112)
    (SID_NAME = WJZI)
    )
    )

    LISTENER =
    (DESCRIPTION =
    (ADDRESS = (PROTOCOL = TCP)(HOST = standby_server) (PORT = 1521))
    )

    Permissions on my .ora files in $ORACLE_HOME/network/admin are

    -rw - r - r - 1 oracle dba

    The user that I am connected to who is oracle.

    I have set up several times before, but for some reason that I can't get this to work. I get

    AMT-03505: failed to resolve host

    Of

    tnsping wldb_there

    or

    tnsping wldb_here

    I have not tried to take the LDAP Protocol on my sqlnet.ora because I need, but I really want to know if anyone has had an experience like this before.

    Thank you-

    gregb wrote:

    I am running 11.2.0.3 on Solaris 10 SPARC x 64. I'm trying to configure oracle net for a new database on hold in order to be able to use rman duplicate to create. LDAP is what we mainly use for all of our connections and, possibly, what I could use very well for my goal of rman duplication. But, I fear that I do nothing seems to allow me to read the tnsnames.ora file.

    My SQLNET. ORA file is as follows:

    NAMES. DIRECTORY_PATH = (LDAP, TNSNAMES)

    NAMES. DEFAULT_DOMAIN = mydomain.com

    My TNSNAMES file. ORA file is as follows on both servers:

    WLDB_HERE =
    (DESCRIPTION =
    (ADDRESS_LIST =
    (ADDRESS = (PROTOCOL = TCP)(HOST = primary_server) (PORT = 1521))
    )
    (CONNECT_DATA = (SERVICE_NAME = wldb_here.mydomain.com))


    )

    Because you have NAMES. DEFAULT_DOMAIN = mydomain.com in your sqlnet.ora, when you try to connect to "WLDB_HERE", before tnsnames.ora is read, sqlnet will transform your application in "WLDB_HERE.mydomain.com".  And that's what he's going to get.

    You do not have an entry in your tnsnames.ora to 'WLDB_HERE.mydomain.com '.

    WLDB_THERE =
    (DESCRIPTION =
    (ADDRESS_LIST =
    (ADDRESS = (PROTOCOL = TCP)(HOST = standby_server) (PORT = 1521))
    )
    (CONNECT_DATA = (SERVICE_NAME = wldb_there.mydomain.com))
    )

    I have a static entry in the remote listener.ora file so I can connect to create the instance:

    SID_LIST_LISTENER =
    (SID_LIST =
    (SID_DESC =
    (GLOBAL_DBNAME = wldb_there.mydomain.com)
    (ORACLE_HOME = / u01/app/oracle/product/OraHome112)
    (SID_NAME = WJZI)
    )
    )

    LISTENER =
    (DESCRIPTION =
    (ADDRESS = (PROTOCOL = TCP)(HOST = standby_server) (PORT = 1521))
    )

    Permissions on my .ora files in $ORACLE_HOME/network/admin are

    -rw - r - r - 1 oracle dba

    The user that I am connected to who is oracle.

    I have set up several times before, but for some reason that I can't get this to work. I get

    AMT-03505: failed to resolve host

    Of

    tnsping wldb_there

    or

    tnsping wldb_here

    I have not tried to take the LDAP Protocol on my sqlnet.ora because I need, but I really want to know if anyone has had an experience like this before.

    Thank you-

  • connect sqlplus without tnsnames.ora

    Hello

    I have nothing in tnsnames.ora locally.
    I don't have a local instance of the DB, I always have to connect to an instance on a server. How can I connect using sqlplus?
    sqlplus [email protected]:1521/MYSID
    The result is ORA-12514!

    connect without tnsnames.ora. For example:

    sqlplus scott/tiger @(DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(Host=server_a) (Port = 1521)) (CONNECT_DATA = (SID = db_a)))

  • EM does not create entry tnsnames.ora with service name orcl11gr2

    Hi all

    I am trying to create a service network with EM Database Control, Net Services Administration link name. On the service name field, under the "Edit Net Service Name" screen, I type in orcl11gr2, and it throws the following error:

    Validation error
    Review and correct the following errors, and then try again:
    Service name - specify a valid service name.

    I wonder what is the additional validation that checks EM. I guess it's to check the number of characters to 8 characters or less.

    In addition, because of this additional validation that is in MS, all entry tnsnames.ora with service name = orcl11gr2, I won't be able to use 'EM to change, as I have the same error.

    But why Oracle implements this additional validation when the same validation is not implemented on other Oracle tools? For example:
    1 dbca allows me to create a database with instance_name greater than 8 characters, and the results of the initialization parameters will be as follows:
    db_name = orcl11gr - truncated to 8 characters
    instance_name = orcl11gr2
    db_unique_name = orcl11gr2
    noms_service = orcl11gr2

    2 oracle Net Manager supports the name of orcl11gr2. The name of the created Service Net, I have no problem connecting to the database.
    3. name of the service orcl11gr2 of listener support

    I am using Oracle 11 g R2 (11.2.0.1.0) for Microsoft Windows (x 64), running on Windows 7.

    Its a known issue fixed 12gc Ms.

    concerning
    Bennett

  • Need PMON use tnsnames.ora to find no-DEFAULT listener?

    Hello

    I just want to confirm that because it is said tnsnames.ora used only for the customer. So I'm a bit confused by this use.
    Please give some explanations about this.


    Thanks in advance.

    BR
    Martin

    I know from experience as well - when I put in place LOCAL_LISTENER and REMOTE_LISTENER in 9iRAC.

    It is quite simple in 11.2 documentation:

    http://download.Oracle.com/docs/CD/E11882_01/server.112/e17110/initparams116.htm#i1128493

    «+ LOCAL_LISTENER specifies a network name that resolves to an address or a list of addresses of Oracle Net local listeners (i.e. listeners who are running on the same computer as this instance).» The address or the address list is specified in the TNSNAMES file. ORA file or another trustee address configured for your system. » +

    http://download.Oracle.com/docs/CD/E11882_01/server.112/e17110/initparams206.htm#i1132970

    "+ REMOTE_LISTENER specifies a network name that resolves to an address or a list of addresses of listeners distance Oracle Net (i.e. the listeners that are not running on the same machine as this instance). The address or the address list is specified in the TNSNAMES file. "ORA file or another trustee address configured for your system.

    I believe that earlier versions of the document indicate clearly that the 'address or address list of Oracle Net remote listeners' carried out since the tnsnames.ora. There was a few messages from forums on this confusion over the years.

    Hemant K Collette

    Published by: Hemant K grapple on May 25, 2011 10:53

  • customer will not use the correct tnsnames.ora file

    Hello all, I installed oracle 10g client on my machine... but here's the thing... I tnsnames.ora several file on my machine (which I can't delete or play with)... and because of this oracle is not able to connect to the database I want it to connect to... I can't do tnsping to the database... is there a way where I can point my client to use a specific tnsnames.ora file? as a pointer? or something where it will look in this file specific tnsnsame.ora?

    You can specify what tnsnames.ora for use the TNS_ADMIN environment variable
    Switch to the directory that contains your tnsnames.ora to use.

    Kind regards
    Uwe

    http://uhesse.WordPress.com

  • Another Post on 'could not resolve identifier' ORA-12154

    Hi experts,

    A new installation of 11g and I CAN connect to the database via SQLPlus but I get ORA-12154 error when you try to connect through RMAN.

    I used the EZCONNECT parameter in netca

    SQLNET. ORA NAMES_DIRECTORY_PATH a = (EZCONNECT)


    Any ideas for what I can check, please?

    Thank you, John

    user629010 wrote:
    Hi experts,

    A new installation of 11g and I CAN connect to the database via SQLPlus but I get ORA-12154 error when you try to connect through RMAN.

    I used the EZCONNECT parameter in netca

    SQLNET. ORA NAMES_DIRECTORY_PATH a = (EZCONNECT)

    Any ideas for what I can check, please?

    Thank you, John

    The connection string, you really used to connect knowing would have been helpful...

    =================================
    ORA-12154: TNS: could not resolve the connect identifier specified

    This error means one thing and one thing only. The customer couldn't find the entry specified in the tnsnames.ora file being used.

    Following this statement, remember that when you use a dblink, the database that defines the link acts as a client to the database that is the target of the link. So in this case, the tnsnames.ora on the host of your source file must have an entry for your db target, as defined in the db_link.

    And for the umpteenth time... This error has NOTHING to do with the status of a listener. The connection request never got far enough to reach a listener. If someone tells you to check a listener in response to ora-12154, they do not pay attention, or do not understand how works the TNS. This error is equivalent to not be able to place a phone call because you do not know the number of the part you want to reach. You would not debug this situation by going to the home of the other guy and test his phone, or by accessing the phone company and the standard test. And you are debugging an ORA-12154 by checking the listener. If I had a list of ten albums of 'Incredibly Simple Concepts (tm)' which must be burned in the brain of anyone claiming to be an Oracle DBA, it would include "ORA-12154 has nothing to do with the listener.

    =================================

    Suppose you have the following in your tnsnames.ora:

    larry =
      (DESCRIPTION =
        (ADDRESS_LIST =
          (ADDRESS = (PROTOCOL = TCP)(HOST = myhost)(PORT = 1521))
        )
        (CONNECT_DATA =
          (SERVICE_NAME = curley)
        )
      )
    

    Now, when you issue a connect, say like this:

    $> sqlplus scott/tiger@larry
    

    TNS will appear in your tnsnames.ora for an entry called "larry". Then, tns sends a request to (PORT = 1521) on (HOST = myhost) to aid (PROTOCOL = TCP), requesting a connection to (SERVICE_NAME = curley).

    Where's (HOST = myhost) on the network? When the request is passed to tns to the next layer in the network stack, the name "myhost" resolves to an IP address, either via a file 'hosts' local, through DNS, or possibly other mechanisms being used less. Alternatively, you can hard-code the IP (HOST = 123.456.789.101) in the tnsnames.ora.

    Then, the request arrives at port 1521 myhost. If all goes well, there is a listener on myhost configured to listen on port 1521, and this listener knows SERVICE_NAME = curley. If so, you'll be connected.

    A few important points.

    First, the listener is a process only server-side . It's all in life seeks applications for reception for connections to the databases and set up these connections. Once the connection is established, the listener is out of the picture. It creates the connection. Is not maintain the connection. A listener, linking an oracle of the House, listening on a single port, use multiple instances of database in several versions of several houses. It is unnecessary complexity to try to have several headphones. It's like the telephone company, to build a separate table for each customer.

    Secondly, the tnsnames.ora file is a problem on the client side . Its purpose is to address resolution - the equivalent of the 'hosts' file tns further to the bottom of the network stack. The only reason it exists on a host computer is because this machine also can run client processes.

    What can go wrong?

    First, there may not be an entry for 'larry' in your tnsnames file. In this case, you get "ORA-12154: TNS: could not resolve the connect identifier specified" no need to go looking for a problem on the host, with the listener, etc.. If you cannot place a phone call because you do not know the number (cannot find your phonebook (tnsnames.ora) or can not find the party looking for listed in it (no entry for larry)) you don't look at problems at the switchboard.

    Perhaps the entry for larry was found, but myhost could not be resolved to an IP address (for example there is no entry for myhost in the local hosts file). This will mean by "ORA-12545: Connect failed because target host or object does not exist.

    Maybe there is an entry for MyServer in the local hosts file, but it specified a bad IP address. This will mean by "ORA-12545: Connect failed because target host or object does not exist.

    Maybe the INVESTIGATION period was good, but there is no listener running: "ORA-12541: TNS:no listener.

    Maybe the INVESTIGATION period was good, there is a listener to myhost, but he is listening on a different port. "ORA-12560: TNS:protocol adapter error.

    Maybe the INVESTIGATION period was good, there is a listener to myhost, listening on the specified port, it's unknown SERVICE_NAME = curley. "ORA-12514: TNS:listener is not currently of service requested in connect descriptor.

  • Earphone & tnsnames.ora

    I'm confused verymuch is a client/server configuration.
    I need help you popular.
    I posted the two clients/server listener & tnsnames.ora,.
    that I set up.

    Server listener.ora (test1)

    SID_LIST_LISTENER =
    *(SID_LIST =*)
    *(SID_DESC =*)
    * (SID_NAME = PLSExtProc) *.
    * (ORACLE_HOME = D:\oracle\product\10.2.0\db_1)*
    * (= Extproc program) *.
    *)*
    *(SID_DESC =*)
    * (GLOBAL_DBNAME = TEST1) *.
    * (ORACLE_HOME = D:\oracle\product\10.2.0\db_1)*
    * (SID_NAME = TEST1) *.
    *)*
    *)*

    TEST1 =
    *(DESCRIPTION =*)
    * (ADDRESS = (PROTOCOL = TCP) (HOST = Desktop029.tvsil.com)(PORT = 1521)) *.
    *)*

    SID_LIST_ORCL =
    *(SID_LIST =*)
    *(SID_DESC =*)
    * (GLOBAL_DBNAME = TEST1) *.
    * (ORACLE_HOME = D:\oracle\product\10.2.0\db_1)*
    * (SID_NAME = TEST1) *.
    *)*
    *)*

    LISTENER =
    *(DESCRIPTION =*)
    * (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC)) *.
    *)*

    ORCL =
    *(DESCRIPTION =*)
    * (ADDRESS = (PROTOCOL = TCP) (HOST = Desktop041.tvsil.com)(PORT = 1522)) *.
    *)*

    Server tnsnames.ora

    TEST1 =
    *(DESCRIPTION =*)
    * (ADDRESS = (PROTOCOL = TCP) (HOST = Desktop029.tvsil.com)(PORT = 1521)) *.
    *(CONNECT_DATA =*)
    * (SERVER = DEDICATED) *.
    * (SERVICE_NAME = TEST1) *.
    *)*
    *)*

    ORCL =
    *(DESCRIPTION =*)
    * (ADDRESS = (PROTOCOL = TCP) (HOST = Desktop041.tvsil.com)(PORT = 1522)) *.
    *(CONNECT_DATA =*)
    * (Service_name = ORCL). *
    *)*
    *)*

    EXTPROC_CONNECTION_DATA =
    *(DESCRIPTION =*)
    *(ADDRESS_LIST =*)
    * (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1)) *.
    *)*
    *(CONNECT_DATA =*)
    * (SID = PLSExtProc) *.
    * (PRESENTATION = RO) *.
    *)*
    *)*

    customer listener.ora (orcl)

    SID_LIST_LISTENER =
    *(SID_LIST =*)
    *(SID_DESC =*)
    * (SID_NAME = PLSExtProc) *.
    * (ORACLE_HOME = E:\Sample1oracle\product\10.2.0\db_2)*
    * (= Extproc program) *.
    *)*

    *)*

    LISTENER =
    *(DESCRIPTION_LIST =*)
    *(DESCRIPTION =*)
    * (ADDRESS = (PROTOCOL = TCP) (HOST = Desktop041.tvsil.com)(PORT = 1523)) *.
    * (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC)) *.
    *)*
    *)*

    ORCL =
    *(DESCRIPTION =*)
    * (ADDRESS = (PROTOCOL = TCP) (HOST = Desktop041.tvsil.com)(PORT = 1522)) *.
    *)*

    TEST1 =
    *(DESCRIPTION =*)
    * (ADDRESS = (PROTOCOL = TCP) (HOST = Desktop029.tvsil.com)(PORT = 1521)) *.
    *)*

    Customer tnsnames.ora

    LISTENER_TEST1 =
    * (ADDRESS = (PROTOCOL = TCP) (HOST = Desktop029.tvsil.com)(PORT = 1521)) *.


    TEST1 =
    *(DESCRIPTION =*)
    * (ADDRESS = (PROTOCOL = TCP) (HOST = Desktop029.tvsil.com)(PORT = 1521)) *.
    *(CONNECT_DATA =*)
    * (SERVER = DEDICATED) *.
    * (SERVICE_NAME = TEST1) *.
    *)*
    *)*

    ORCL =
    *(DESCRIPTION =*)
    *(ADDRESS_LIST =*)
    (* (ADDRESS = (PROTOCOL = TCP)(HOST = desktop041.tvsil.com) (PORT = 1522))) *.
    *(CONNECT_DATA =*)
    * (Service_name = ORCL). *
    *)*
    *)*

    EXTPROC_CONNECTION_DATA =
    *(DESCRIPTION =*)
    *(ADDRESS_LIST =*)
    * (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC2)) *.
    *)*
    *(CONNECT_DATA =*)
    * (SID = PLSExtProc) *.
    * (PRESENTATION = RO) *.
    *)*
    *)*

    user11345217 wrote:
    I'm confused verymuch is a client/server configuration.
    I need help you popular.
    I posted the two clients/Server Listener and tnsnames .ora,
    that I set up.

    Server listener.ora (test1)

    SID_LIST_LISTENER =
    *(SID_LIST =*)
    *(SID_DESC =*)
    * (SID_NAME = PLSExtProc) *.
    * (ORACLE_HOME = D:\oracle\product\10.2.0\db_1)*
    * (= Extproc program) *.
    *)*
    *(SID_DESC =*)
    * (GLOBAL_DBNAME = TEST1) *.
    * (ORACLE_HOME = D:\oracle\product\10.2.0\db_1)*
    * (SID_NAME = TEST1) *.
    *)*
    *)*

    TEST1 =
    *(DESCRIPTION =*)
    * (ADDRESS = (PROTOCOL = TCP) (HOST = Desktop029.tvsil.com)(PORT = 1521)) *.
    *)*

    SID_LIST_ORCL =
    *(SID_LIST =*)
    *(SID_DESC =*)
    * (GLOBAL_DBNAME = TEST1) *.
    * (ORACLE_HOME = D:\oracle\product\10.2.0\db_1)*
    * (SID_NAME = TEST1) *.
    *)*
    *)*

    LISTENER =
    *(DESCRIPTION =*)
    * (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC)) *.
    *)*

    ORCL =
    *(DESCRIPTION =*)
    * (ADDRESS = (PROTOCOL = TCP) (HOST = Desktop041.tvsil.com)(PORT = 1522)) *.
    *)*

    Well, it's certainly the most, uh, listener.ora interesting I've ever seen... where did you find with this?

    Server tnsnames.ora

    TEST1 =
    *(DESCRIPTION =*)


    * (ADDRESS = (PROTOCOL = TCP) (HOST = Desktop029.tvsil.com)(PORT = 1521)) *.
    *(CONNECT_DATA =*)
    * (SERVER = DEDICATED) *.
    * (SERVICE_NAME = TEST1) *.
    *)*
    *)*

    ORCL =
    *(DESCRIPTION =*)
    * (ADDRESS = (PROTOCOL = TCP) (HOST = Desktop041.tvsil.com)(PORT = 1522)) *.
    *(CONNECT_DATA =*)
    * (Service_name = ORCL). *
    *)*
    *)*

    EXTPROC_CONNECTION_DATA =
    *(DESCRIPTION =*)
    *(ADDRESS_LIST =*)
    * (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1)) *.
    *)*
    *(CONNECT_DATA =*)
    * (SID = PLSExtProc) *.
    * (PRESENTATION = RO) *.
    *)*
    *)*

    customer listener.ora (orcl)

    A listener.ora on the client makes as much sense as a radiator on a 1965 Volkswagen. The listener is strictly a process on the server side. That's the whole reason to live is to 'listen' (where its name) for connection requests.

    Customer tnsnames.ora

    LISTENER_TEST1 =
    * (ADDRESS = (PROTOCOL = TCP) (HOST = Desktop029.tvsil.com)(PORT = 1521)) *.

    TEST1 =
    *(DESCRIPTION =*)
    * (ADDRESS = (PROTOCOL = TCP) (HOST = Desktop029.tvsil.com)(PORT = 1521)) *.
    *(CONNECT_DATA =*)
    * (SERVER = DEDICATED) *.
    * (SERVICE_NAME = TEST1) *.
    *)*
    *)*

    ORCL =
    *(DESCRIPTION =*)
    *(ADDRESS_LIST =*)
    (* (ADDRESS = (PROTOCOL = TCP)(HOST = desktop041.tvsil.com) (PORT = 1522))) *.
    *(CONNECT_DATA =*)
    * (Service_name = ORCL). *
    *)*
    *)*

    EXTPROC_CONNECTION_DATA =
    *(DESCRIPTION =*)
    *(ADDRESS_LIST =*)
    * (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC2)) *.
    *)*
    *(CONNECT_DATA =*)
    * (SID = PLSExtProc) *.
    * (PRESENTATION = RO) *.
    *)*
    *)*

    OK, let's clear up a few things.

    First of all, as mentioned, the listener is purely a process on the client side. There is therefore no use to a listener.ora on the client.

    Second, a single listener, listening on a single port, can serve several databases multiple editions in multiple oracle homes. He listens to a connection, it puts in place (on a different listening port on) and then is out of the picture for this connection. It establishes the connection, but not the support it. Your listener.ora is much more complex (dare I say convoluted) as necessary.

    On the client side (the server can also act as a client) and the tnsnames.ora is used to resolve an alias (a tns service name) to a real destination on the network.

    Suppose you have the following in your tnsnames.ora:

    larry =
      (DESCRIPTION =
        (ADDRESS_LIST =
          (ADDRESS = (PROTOCOL = TCP)(HOST = myhost)(PORT = 1521))
        )
        (CONNECT_DATA =
          (SERVICE_NAME = curley)
        )
      )
    

    Now, when you issue a connect, say like this:

    $> sqlplus scott/tiger@larry
    

    TNS will appear in your tnsnames.ora for an entry called "larry". Then, tns sends a request to (PORT = 1521) on (HOST = myhost) to aid (PROTOCOL = TCP), requesting a connection to (SERVICE_NAME = curley).

    Where's (HOST = myhost) on the network? When the request is passed to tns to the next layer in the network stack, the name "myhost" resolves to an IP address, either via a file 'hosts' local, through DNS, or possibly other mechanisms being used less. Alternatively, you can hard-code the IP (HOST = 123.456.789.101) in the tnsnames.ora.

    Then, the request arrives (port = 1521) on (HOST = myhost). If all goes well, there is a listener on myhost configured to listen on (PORT = 1521), and this listener knows (SERVICE_NAME = curley). If so, you'll be connected.

    What can go wrong?

    First, there may not be an entry for 'larry' in your tnsnames file. In this case, you get "ORA-12154: TNS: could not resolve the connect identifier specified" no need to go looking for a problem on the host, with the listener, etc.. If you cannot place a phone call because you do not know the number (can't phone your telephone book or can't find the group you're looking for it contained therein) you don't look at problems at the switchboard.

    Perhaps the entry for larry was found, but myhost could not be resolved to an IP address (for example there is no entry for myhost in the local hosts file). This will mean by "ORA-12545: Connect failed because target host or object does not exist.

    Maybe there is an entry for MyServer in the local hosts file, but it specified a bad IP address. This will mean by "ORA-12545: Connect failed because target host or object does not exist.

    Maybe the INVESTIGATION period was good, but there is no listener running: "ORA-12541: TNS:no listener.

    Maybe the INVESTIGATION period was good, there is a listener to myhost, but he is listening on a different port. "ORA-12560: TNS:protocol adapter error.

    Maybe the INVESTIGATION period was good, there is a listener to myhost, listening on the specified port, it's unknown SERVICE_NAME = curley. "ORA-12514: TNS:listener is not currently of service requested in connect descriptor.

  • Can not find the file init for the database instance

    I have installed Oracle 10 g under Linux CentOS, run netca to create listener.ora and tnsnames.ora files, then I run dbca to create the myodb database and orcl instance.



    Now when I run dbstart, in the boot log, that it is said that he could not find the file orcl example init. so that the database myodb, he says:

    < em > / oracle/product/10.2.0/db_1/bin/dbstart: database instance "myodb' hot began.





    < /em > my questions:



    1. why it is said when I run dbstart both myodb & orcl are instances of database, I created myodb as the General database, while orcl corresponds to the instance, here it says:

    instance of < em > data treatment "orcl": journal file /oracle/product/10.2.0/db_1/startup.log

    Database instance "myodb' of treatment: save the /oracle/product/10.2.0/db_1/startup.log file



    < /em > is the name of the General database is considered an instance itself and can be used alternatively with the instance of word?



    2 when I created the database using dbca, I made the password for users of SYSTEM & SYS.



    When I try to connect to sqlplus using the system/mypassword, here it says:



    < strong > < em > ORA-01034: ORACLE is not available

    ORA-27101: shared memory realm does not exist

    Linux error: 2: no such file or directory < /em > < / strong >



    3. the database myodb started but it is not mentioned in my tnsnames file or the listener, while one mentioned is orcl has not begun, how is it? I know I'm missing a dir for /orcl in/oracle/home/admin, something that we find for the myodb, where there is/oracle/home/admin/myodb/pfile/init file.



    How can I fix this?



    4. What is the use of the command sql, < strong > edit < facilities > system registry, told me in another thread to connect to an idle instance with sqlplus and run this command, here what I got:



    < em > ERROR on line 1:

    ORA-01034: ORACLE not available



    < /em > 5 - can I just rely on the name of the General database and forget the thing of the Forum? I'm just confused about the difference and do not know how the orcl instance was created, it has not been created with dbca, because when I run dbca he says it's already there, create another instance, so I commented the sid parameter and now I amn't during its creation and how to retrieve its files if I need to re - create it again.



    Note: it is located in the bash_profile as $ORACLE_SID = orcl, why it's the only game, while General MYODB database name is not set, can be there rather than on the instance or SID in the bash_profile?





    Sorry for the many questions, this is the thing of the instance and their related discipline, I appreciate your help.



    Thanks in advance.




    If you have only 1 instance "orcl" then the oratab file should have only 1 entry - only for "orcl". Along, only one instance "myodb" {with the db_name "myodb"} must be started.
    The database Instance is identified by the SID - IE the ORACLE_SID.

    Normally, the SID and DB_NAME are the same - and they do like default value is the same when you run dbca. You have changed probably manually the db_name in dbca.

    If the listener is running on port 1521 and is started before the database instance, the database instance automatically saves with the listener. If the listener is started after the database instance, and then the command 'ALTER SYSTEM REGISTER' in the database instance indicates PMON to register with the listener.
    If you do not want to depend on the automatic check of the database with the listener instance, then you can include the information database (SID!) in the listener.ora. In addition, which would be caused if the listener is not on the default port 1521.

    See my posting in this thread: oracle sid and database the name of for more notes.

    A database can contain multiple schemas - each schema is a different database account. In other implementations of database (non-Oracle), what is called a "database", it is called a 'plan' in Oracle - but that is created as a database account. Database accounts are listed in DBA_USERS - if a user "owns" objects, it's a 'plan', otherwise, it is only a user. {Oracle also provides a CREATE SCHEMA command to create multiple objects in a single command.}

    Hemant K Collette
    http://hemantoracledba.blogspot.com

    Published by: Hemant K grapple on November 6, 2008 09:31
    corrected "orcl" to "myodb.

  • Listener (and the database instance) does not start automatically: ORA-12514: TNS:listener does not currently of service requested in connect descriptor

    Hi all... I am a newbie with oracle database.,.

    I have the problem of monitoring:

    I installed Oracle Database 11 g R2 XE on my CentOS 6.5 guest operating system.

    I changed the host name in my CentOS so (where installed oracle 11g R2 XE) after the installation was completed successfully.

    Installation-) before and during the hostname is localhost.

    (-) After the installation, I changed the host name in VMCentOS

    From the moment where I changed the host name, nothing starts automatically. In particular, the listener and the database instance does not start automatically.

    When I start the listener manually and I try to connect to the instance of database with SQLPLUS I get this error:

    ORA-12514: TNS:listener is not currently of service requested in connect descriptor

    I think that the problem is due host name changed because I have to test and debug the object, re-installed a machine virtual operating system CentOS, re-installed oracle database 11 g and I do not have this problem. The database instance and the listener starts automatically!

    Can someone tell me if, maybe, the problem is with the host has changed? ... and why?

    P.S.: After changing the hostname I also modified the listener.ora and the tnsnames.ora by changing the HOST with the correct host name.

    Hello

    It seems that you don't install Oracle Database Express Edition (XE). If you post this question in the wrong forum.

    When you install EA or there is no script that starts the database at startup.

    If you wish, you can create by yourself. For example search for instructions to Google how to create script.

    Kind regards

    Jari

  • listener_scan1 could not find the name of service

    Hi all

    I installed 11203 on 2 node RAC cluster. I created 1 listener to scan. When I give lsnrctl status LISTENER_SCAN1, I get the below error

    AMT-01101: could not find the name of service LISTENER_SCAN1

    Please, give your suggestions and help on this issue.

    Thank you

    NR

    Hello

    Try configuring the tnsnames.ora in this format and let me know

    If you use load balancing, try

    TBESTDB =

    (DESCRIPTION =

    (ADDRESS = (PROTOCOL = TCP (PORT = 1531))(HOST = node1_vip))

    (ADDRESS = (PROTOCOL = TCP (PORT = 1531))(HOST = node2_vip))

    (LOAD_BALANCE = yes)

    (CONNECT_DATA =

    (SERVER = DEDICATED)

    (SERVICE_NAME = TBESTDB)

    )

    )

    And you can add below if you want to connect to a specific instance

    RAC1 =

    (DESCRIPTION =

    (ADDRESS = (PROTOCOL = TCP) (HOST = rac1-vip)(PORT = 1521))

    (CONNECT_DATA =

    (SERVER = DEDICATED)

    (SERVICE_NAME = rac.oracle.com)

    (INSTANCE_NAME = rac1)

    )

    )

    RAC2 =

    (DESCRIPTION =

    (ADDRESS = (PROTOCOL = TCP) (HOST = rac2-vip)(PORT = 1521))

    (CONNECT_DATA =

    (SERVER = DEDICATED)

    (SERVICE_NAME = rac.oracle.com)

    (INSTANCE_NAME = rac2)

    )

    )

    Note: Replace the SID, Servicename, hostname, port etc depending on your environment and also ensure that the tnsnames.ora should be in an appropriate format (for example: the opening and closing should be in the right order.) If you add an extra space further it will throw error..)

    Kind regards

    Pradeep. V

Maybe you are looking for