Forum Stats

  • 3,826,076 Users
  • 2,260,592 Discussions
  • 7,896,782 Comments

Discussions

ORA-12505, TNS:listener does not currently know of SID given in connect descriptor

2»

Answers

  • sandeep.c
    sandeep.c Member Posts: 7

    a) I tried "lsnrctl stop" but it said

    LSNRCTL for 64-bit Windows: Version 11.2.0.1.0 - Production on 06-NOV-2013 02:45

    :44

    Copyright (c) 1991, 2010, Oracle.  All rights reserved.

    Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC1521)))

    TNS-01190: The user is not authorized to execute the requested listener command

    So, I tried stopping it from services.msc,i.e,stopping the service "OracleOraDb11g_home1TNSListener"

    b) ren listener.ora listener.ora.sav => Gave me Access  denied error.

    So,I renamed the file manually.

    lsnrctl status gave me the following output.

    LSNRCTL for 64-bit Windows: Version 11.2.0.1.0 - Production on 06-NOV-2013 02:52

    :45

    Copyright (c) 1991, 2010, Oracle.  All rights reserved.

    Connecting to (ADDRESS=(PROTOCOL=tcp)(HOST=)(PORT=1521))

    STATUS of the LISTENER

    ------------------------

    Alias                     LISTENER

    Version                   TNSLSNR for 64-bit Windows: Version 11.2.0.1.0 - Produ

    ction

    Start Date                06-NOV-2013 02:52:19

    Uptime                    0 days 0 hr. 0 min. 26 sec

    Trace Level               off

    Security                  ON: Local OS Authentication

    SNMP                      OFF

    Listener Log File         d:\app\sandeep\diag\tnslsnr\Sandeep-PC\listener\alert\

    log.xml

    Listening Endpoints Summary...

      (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=Sandeep-PC)(PORT=1521)))

    The listener supports no services

    The command completed successfully

    -------------------------------------------------------------------------------

    lsnrctl service gave me the following output...

    LSNRCTL for 64-bit Windows: Version 11.2.0.1.0 - Production on 06-NOV-2013 02:53

    :43

    Copyright (c) 1991, 2010, Oracle.  All rights reserved.

    Connecting to (ADDRESS=(PROTOCOL=tcp)(HOST=)(PORT=1521))

    Services Summary...

    Service "orcl" has 1 instance(s).

      Instance "orcl", status READY, has 1 handler(s) for this service...

        Handler(s):

          "DEDICATED" established:6 refused:0 state:ready

             LOCAL SERVER

    Service "orclXDB" has 1 instance(s).

      Instance "orcl", status READY, has 1 handler(s) for this service...

        Handler(s):

          "D000" established:0 refused:0 current:0 max:1022 state:ready

             DISPATCHER <machine: SANDEEP-PC, pid: 4736>

             (ADDRESS=(PROTOCOL=tcp)(HOST=Sandeep-PC)(PORT=61533))

    The command completed successfully

    -------------------------------------------------------------------------------

    I can now see "Instance "orcl", status READY, has 1 handler(s) for this service..."

    I tried running my Java code and now I have the OP...

    Connected to the Oracle database...

    Now,all what I did was stopping the listener service,renaming the listener.ora file and starting the service again.

    Please correct me if I am wrong at any point.

  • sb92075
    sb92075 Member Posts: 42,196 Blue Diamond

    previously listener.ora contained bad or incorrect data.

    by eliminating the file which is NOT required to start or use the listener, the default values provided success.

    sb92075
  • sandeep.c
    sandeep.c Member Posts: 7

    Thanks a ton Ed.Marking the question as answered.

    Regards,
    Sandeep

This discussion has been closed.