Listener

DBA Geral (instalação, configuração do banco, scripts do Sql*Plus, shell scripts, batch scripts, etc...)
Post Reply
mjr
Rank: Estagiário Pleno
Rank: Estagiário Pleno
Posts: 5
Joined: Thu, 04 Oct 2007 9:47 am
Location: Brasilia - DF

Good morning to all

I would like to make an appointment to improve the configuration of my bank. I am using Windows 2003 and Oracle10G version 10.2.0.

My bank has no patches because it is a free version and use in my house to make certification practices.

I would like to learn how to configure the listener because it seems that at the time of installation the listener does not add the bank in the list, but we have to add it after that?

I do not know why it works equally, I believe locally works well but when you want to do some network operation there will not work.

Good here has the listener file.ora

Select all

# listener.ora Network Configuration File: C:\oracle\product\10.2.0\db_1\network\admin\listener.ora 
# Generated by Oracle configuration tools. 
 
SID_LIST_LISTENER = 
  (SID_LIST = 
    (SID_DESC = 
      (SID_NAME = PLSExtProc) 
      (ORACLE_HOME = C:\oracle\product\10.2.0\db_1) 
      (PROGRAM = extproc) 
    ) 
  ) 
 
LISTENER = 
  (DESCRIPTION_LIST = 
    (DESCRIPTION = 
      (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1)) 
      (ADDRESS = (PROTOCOL = TCP)(HOST = oracle10.STAR-WAR)(PORT = 1521)) 
    ) 
  )
and here TNSNAMES.ORA

Select all

# tnsnames.ora Network Configuration File: C:\oracle\product\10.2.0\db_1\network\admin\tnsnames.ora 
# Generated by Oracle configuration tools. 
 
ORCL = 
  (DESCRIPTION = 
    (ADDRESS = (PROTOCOL = TCP)(HOST = oracle10.STAR-WAR)(PORT = 1521)) 
    (CONNECT_DATA = 
      (SERVER = DEDICATED) 
      (SERVICE_NAME = orcl) 
    ) 
  ) 
 
EXTPROC_CONNECTION_DATA = 
  (DESCRIPTION = 
    (ADDRESS_LIST = 
      (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1)) 
    ) 
    (CONNECT_DATA = 
      (SID = PLSExtProc) 
      (PRESENTATION = RO) 
    ) 
  )
The name of my computer and Oracle10
Dominio: Star-War
Bank name: Orcl

I would like to know how to add my orcl in the Listener.ora Because it's not there. Also do not understand what and fetch.

Sorry for my ignorance and if the question has already been answered please sign me the link

thank you very much,

Marcos
gilbertoca
Rank: DBA Sênior
Rank: DBA Sênior
Posts: 372
Joined: Tue, 24 Jan 2006 3:33 pm
Location: Palmas - TO
Contact:

With version 10, Oracle has a feature called Service Registration: http://download.oracle.com/docs/cd/B193 ... tm#i434241
to be more accurate, it automatically registers your instances created, without the need to edit the listener file.

This brings some advantages: http://download.oracle.com/docs/cd/B193 ... tm#i454523

Of course, this does not prevent you from creating one or more listener, for example, for a team of reports constructors, listening to another door.
for this, as easy to use Enterprise Manager.

Gilberto
mjr
Rank: Estagiário Pleno
Rank: Estagiário Pleno
Posts: 5
Joined: Thu, 04 Oct 2007 9:47 am
Location: Brasilia - DF

Thank you Gilberto for help and documentation.

In fact my question was headed for an error that had in the past and back, it happened.

The error and this:

Select all

ORA-12505: TNS: listener could not resolve SID given in connection description
I tried to solve but I could not.
I followed the suggestions for this link: http://www.dbmotive.com/oracle_error_co ... code=12505
and the tnsping orcl command works well, but
when I do the command

Select all

LSNRCTL SERVICES LISTENER
there no longer appears the name From the bank, says:

Select all

(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1)) e que serviço  PLSExtProc tem uma instancia com estado desconhecido.
How can I solve this?

Thank you very much,
deki41
Rank: Estagiário Júnior
Rank: Estagiário Júnior
Posts: 2
Joined: Mon, 15 Oct 2007 2:40 pm
Location: São Paulo SP

Try to set the listener in this way, swapping by your host
and the path of your oracle_home:

Select all

LISTENER = 
  (DESCRIPTION_LIST = 
    (DESCRIPTION = 
      (ADDRESS = (PROTOCOL = TCP)(HOST = SEUHOST)(PORT = 1521)) 
    ) 
    (DESCRIPTION = 
      (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC2)) 
    ) 
  ) 
 
SID_LIST_LISTENER = 
  (SID_LIST_LISTENER = 
  (SID_LIST = 
    (SID_DESC = 
      (SID_NAME = PLSExtProc) 
      (ORACLE_HOME = E:\oracle\ora92) 
      (PROGRAM = extproc) 
    ) 
    (SID_DESC = 
      (GLOBAL_DBNAME = ORCL) 
      (ORACLE_HOME = E:\oracle\ora92) 
      (SID_NAME = ORCL) 
 
     ) 
  )
mjr
Rank: Estagiário Pleno
Rank: Estagiário Pleno
Posts: 5
Joined: Thu, 04 Oct 2007 9:47 am
Location: Brasilia - DF

Hello Deki41

Sorry, I do not understand,
look at that I only have Oracle 10g, and Listener and TNSNames is exactmost as I have on the computer.

Sorry for the confusion, the link I spent not and because I have Oracle10 and 9 on the computer, I just put this because it has a similar problem.

What do you recommend?

Brigade
deki41
Rank: Estagiário Júnior
Rank: Estagiário Júnior
Posts: 2
Joined: Mon, 15 Oct 2007 2:40 pm
Location: São Paulo SP

MJR,
I copied your code (Listener) and add what probably
was missing for orcl instance, okay, I think that's this:

Select all

# listener.ora Network Configuration File: C:\oracle\product\10.2.0\db_1\network\admin\listener.ora  
# Generated by Oracle configuration tools.  
 
SID_LIST_LISTENER =  
  (SID_LIST =  
    (SID_DESC =  
      (SID_NAME = PLSExtProc)  
      (ORACLE_HOME = C:\oracle\product\10.2.0\db_1)  
      (PROGRAM = extproc) 
 
  ) 
  (SID_DESC =  
    (GLOBAL_DBNAME = ORCL)  
    (ORACLE_HOME = C:\oracle\product\10.2.0\db_1)  
    (SID_NAME = ORCL)  
    )  
  )  
 
LISTENER =  
  (DESCRIPTION_LIST =  
    (DESCRIPTION =  
      (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1))  
      (ADDRESS = (PROTOCOL = TCP)(HOST = oracle10.STAR-WAR)(PORT = 1521))  
    )  
  ) 
gilbertoca
Rank: DBA Sênior
Rank: DBA Sênior
Posts: 372
Joined: Tue, 24 Jan 2006 3:33 pm
Location: Palmas - TO
Contact:

See:

Select all

 
gilberto@ti-des05:~> echo $TNS_ADMIN 
/opt/oracle/product/10.1.0.2.0/db_1/network/admin 
 
gilberto@ti-des05:~> ll /opt/oracle/product/10.1.0.2.0/db_1/network/admin 
total 28 
drwxrwxr-x  3 oracle oinstall 4096 2007-10-15 14:01 . 
drwxrwxr-x 11 oracle oinstall 4096 2007-10-15 13:56 .. 
-rwxrwxr-x  1 oracle oinstall   92 2006-08-09 10:07 protocol.obs 
-rwxrwxr-x  1 oracle oinstall   87 2006-08-09 10:01 protocol.ora 
drwxrwxr-x  2 oracle oinstall 4096 2006-01-24 14:28 samples 
-rwxrwxr-x  1 oracle oinstall  287 2006-08-09 10:33 sqlnet.ora 
-rwxrwxr-x  1 oracle oinstall 1460 2007-10-15 14:01 tnsnames.ora 
gilberto@ti-des05:~> 
There is no static listener!

There is also no entry of my instance (mine) in the tnsnames.ora file:

Select all

gilberto@ti-des05:~> cat /opt/oracle/oracleDevSuite/network/admin/tnsnames.ora 
# tnsnames.ora Network Configuration File: /opt/oracle/oracleDevSuite/network/admin/tnsnames.ora 
# Generated by Oracle configuration tools. 
 
gilberto@ti-des05:~>     
But I can See that the dynamic listener is working:

Select all

oracle@ti-des05:~> lsnrctl status 
 
LSNRCTL for Linux: Version 10.1.0.2.0 - Production on 15-OUT-2007 16:07:30 
 
Copyright (c) 1991, 2004, Oracle.  All rights reserved. 
 
Connecting to (ADDRESS=(PROTOCOL=tcp)(PORT=1521)) 
STATUS of the LISTENER 
------------------------ 
Alias                     LISTENER 
Version                   TNSLSNR for Linux: Version 10.1.0.2.0 - Production 
Start Date                15-OUT-2007 16:07:11 
Uptime                    0 days 0 hr. 0 min. 19 sec 
Trace Level               off 
Security                  ON: Local OS Authentication 
SNMP                      OFF 
Listener Log File         /opt/oracle/product/10.1.0.2.0/db_1/network/log/listener.log 
Listening Endpoints Summary... 
  (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=ti-des05.local.secad)(PORT=1521))) 
  (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=ti-des05.local.secad)(PORT=8081))(Presentation=HTTP)(Session=RAW)) 
  (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=ti-des05.local.secad)(PORT=2111))(Presentation=FTP)(Session=RAW)) 
Services Summary... 
Service "meu" has 1 instance(s). 
  Instance "meu", status READY, has 1 handler(s) for this service... 
Service "meuXDB" has 1 instance(s). 
  Instance "meu", status READY, has 1 handler(s) for this service... 
The command completed successfully 
oracle@ti-des05:~>        
But I open another session on the client and try to connect:
(in the client)

Select all

gilberto@ti-des05:~> sqlplus scott/tiger@meu 
 
SQL*Plus: Release 10.1.0.2.0 - Production on Seg Out 15 16:08:17 2007 
 
Copyright (c) 1982, 2004, Oracle.  All rights reserved. 
 
ERROR: 
ORA-12154: TNS:could not resolve the connect identifier specified 
 
 
Enter user-name: scott 
Enter password: 
ERROR: 
ORA-01034: ORACLE not available 
ORA-27101: shared memory realm does not exist 
Linux Error: 2: No such file or directory 
 
gilberto@ti-des05:~> tnsping meu 
 
TNS Ping Utility for Linux: Version 10.1.0.2.0 - Production on 15-OUT-2007 16:13:31 
 
Copyright (c) 1997, 2003, Oracle.  All rights reserved. 
 
Used parameter files: 
/opt/oracle/oracleDevSuite/network/admin/admin/sqlnet.ora 
 
TNS-03505: Failed to resolve name 
 
99]] This is because on the client we need to configure the tnsnames.ora file to access that instance (SID) that is listening on the remote server:
(in the client)

Select all

 
oracle@ti-des05:~> vi /opt/oracle/oracleDevSuite/network/admin/tnsnames.ora 
# tnsnames.ora Network Configuration File: /opt/oracle/oracleDevSuite/network/admin/tnsnames.ora 
# Generated by Oracle configuration tools. 
 
MEU = 
  (DESCRIPTION = 
    (ADDRESS_LIST = 
      (ADDRESS = (PROTOCOL = TCP)(HOST = 10.121.1.42)(PORT = 1521)) 
    ) 
    (CONNECT_DATA = 
      (SERVICE_NAME = meu) 
    ) 
  ) 
Now we can connect:
(in the client)

Select all

 
gilberto@ti-des05:~> tnsping meu 
 
TNS Ping Utility for Linux: Version 10.1.0.2.0 - Production on 15-OUT-2007 16:15:24 
 
Copyright (c) 1997, 2003, Oracle.  All rights reserved. 
 
Used parameter files: 
/opt/oracle/oracleDevSuite/network/admin/sqlnet.ora 
 
 
Used TNSNAMES adapter to resolve the alias 
Attempting to contact (DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = TCP)(HOST = 10.121.1.42)(PORT = 1521))) (CONNECT_DATA = (SERVICE_NAME = meu))) 
OK (0 msec) 
gilberto@ti-des05:~> sqlplus scott/tiger@meu 
 
SQL*Plus: Release 10.1.0.2.0 - Production on Seg Out 15 16:15:29 2007 
 
Copyright (c) 1982, 2004, Oracle.  All rights reserved. 
 
 
Connected to: 
Oracle Database 10g Enterprise Edition Release 10.1.0.2.0 - Production 
With the Partitioning, OLAP and Data Mining options 
 
scott@MEU>                 
Gilberto
carlynhos77
Rank: Analista Sênior
Rank: Analista Sênior
Posts: 172
Joined: Mon, 24 Oct 2016 7:20 pm

Hello, good night ... Someone could help me on a data source connection, I can not make it work, see my post
https://en.glufke.net/oracle/viewtopic.php?f=6&t=10962
if any of You can help me, thank you very much

Carlynhos77@hotmail.com
Post Reply
  • Information
  • Who is online

    Users browsing this forum: No registered users and 1 guest