8 Replies Latest reply: Jun 12, 2014 12:06 PM by prasad.puranik RSS

    11g and 12c om the same windows machine. listened for 12c not sarting up

    prasad.puranik

      Hi,

       

      I have installed 12c on a windows machine which already has an 11g running. After install, the listener for 12c is not starting up while the one for 11g continue to work fine. I've specified 1522 as port. Here's my listener.ora...

       

      SID_LIST_LISTENER =

        (SID_LIST =

          (SID_DESC =

            (SID_NAME = CLRExtProc)

            (ORACLE_HOME = D:\app\Administrator\product\12.1.0\dbhome_1)

            (PROGRAM = extproc)

            (ENVS = "EXTPROC_DLLS=ONLY:D:\app\Administrator\product\12.1.0\dbhome_1\bin\oraclr12.dll")

          )

        )

       

       

      LISTENER =

        (DESCRIPTION_LIST =

          (DESCRIPTION =

            (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1522))

            (ADDRESS = (PROTOCOL = TCP)(HOST = <hostname.domain.com>)(PORT = 1522))

          )

        )

       

      and here's tnsnames.ora...

      MY12C =

        (DESCRIPTION =

          (ADDRESS = (PROTOCOL = TCP)(HOST = <hostname.domain.com>)(PORT = 1522))

          (CONNECT_DATA =

            (SERVER = DEDICATED)

            (SERVICE_NAME = MY12C)

          )

        )

       

       

      ORACLR_CONNECTION_DATA =

        (DESCRIPTION =

          (ADDRESS_LIST =

            (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC))

          )

          (CONNECT_DATA =

            (SID = CLRExtProc)

            (PRESENTATION = RO)

          )

        )

       

       

      I've changed the environment variable ORACLE_HOME to point to D:\app\Administrator\product\12.1.0\dbhome_1.

       

      When I go to windows services and try starting the listener, it starts and then stops immediately. If I do lsnrctl start from command promt then I get,,

       

      C:\Users\Administrator>lsnrctl start

      LSNRCTL for 64-bit Windows: Version 12.1.0.1.0 - Production on 11-JUN-2014 02:00:42

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

      Starting tnslsnr: please wait...

      Failed to start service, error 0.

      TNS-12560: TNS:protocol adapter error

       

      What am I doing wrong?

       

      Regards,

        • 1. Re: 11g and 12c om the same windows machine. listened for 12c not sarting up
          EdStevens

          First off, you don't need two listeners.

           

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

          Please stay after school and write the following sentence 100 times:

           

          One single listener, using the default name of LISTENER and the default port of 1521, is quite capable of -- indeed, WAS DESIGNED TO -- service multiple databases of multiple versions running from multiple homes.  Multiple listeners simply adds complications, and for no gain whatsoever.

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

          When running with Grid Infrastructure, run the listener from the GI home.

          When running a multi-version system, run the listener from the highest version home.

          • 2. Re: 11g and 12c om the same windows machine. listened for 12c not sarting up
            BPeaslandDBA

            Go to the Services utility and stop the Listener service for the 11g home. Then set the service to Disabled so that it won't start any more. Next, run the 12c Net Configuration Assistant utility to create a new 12c listener. This will also create the Windows service to autostart the Listener on host reboots.

             

             

            HTH,

            Brian

            • 3. Re: 11g and 12c om the same windows machine. listened for 12c not sarting up
              rp0428
              After install, the listener for 12c is not starting up while the one for 11g continue to work fine

              Then just add the appropriate 12c entries to the 11g listener file. You only need one listener.

              • 4. Re: 11g and 12c om the same windows machine. listened for 12c not sarting up
                prasad.puranik

                Thanks Ed. Although I didn't write it down 100 times, I get what you mean. I have now set up a test environment to try this out and have configured only one listener (the 12c one) as you said (with default port - 1521). Now what I'm seeing is it's able to connect to only one instance at a time. If I start the 11g service first and 12c service next, then I can connect only to 11g instance. On trying to connect to 12c instance, I get this error..

                ORA-12528, TNS:listener: all appropriate instances are blocking new connections

                 

                 

                All my searches on this error are telling me to wait for some time and try again because the database might not be started yet. But I checked and both the databases are up and running. I can connec to them using sql plus on the lcoal machine.

                 

                 

                Note that if I start 12c service first and then 11g, then I can connect only to 12c and on trying to connect to 11g I get the same error.

                 

                 

                This is my connect string for 11g..

                jdbc:oracle:thin:@machinename.domainname:1521:orcl

                and this is for 12c..

                jdbc:oracle:thin:@machinename.domainname:1521:orcl12c

                 

                 

                Here's my tnsnames.ora..

                # tnsnames.ora Network Configuration File: C:\Oracle\product\12.1.0\dbhome_1\network\admin\tnsnames.ora

                # Generated by Oracle configuration tools.

                ORACLR_CONNECTION_DATA =

                  (DESCRIPTION =

                    (ADDRESS_LIST =

                      (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521))

                    )

                    (CONNECT_DATA =

                      (SID = CLRExtProc)

                      (PRESENTATION = RO)

                    )

                  )

                 

                 

                LISTENER_ORCL12C =

                  (ADDRESS = (PROTOCOL = TCP)(HOST = machinename.domainname)(PORT = 1521))

                 

                 

                ORCL =

                  (DESCRIPTION =

                    (ADDRESS = (PROTOCOL = TCP)(HOST = machinename.domainname)(PORT = 1521))

                    (CONNECT_DATA =

                      (SERVER = DEDICATED)

                      (SERVICE_NAME = orcl.domainname)

                    )

                  )

                 

                 

                and here's listener.ora...

                # listener.ora Network Configuration File: C:\Oracle\product\12.1.0\dbhome_1\network\admin\listener.ora

                # Generated by Oracle configuration tools.

                SID_LIST_LISTENER =

                  (SID_LIST =

                    (SID_DESC =

                      (SID_NAME = CLRExtProc)

                      (ORACLE_HOME = C:\Oracle\product\12.1.0\dbhome_1)

                      (PROGRAM = extproc)

                      (ENVS = "EXTPROC_DLLS=ONLY:C:\Oracle\product\12.1.0\dbhome_1\bin\oraclr12.dll")

                    )

                  )

                LISTENER =

                  (DESCRIPTION_LIST =

                    (DESCRIPTION =

                      (ADDRESS = (PROTOCOL = TCP)(HOST = machinename.domainname)(PORT = 1521))

                    )

                  )

                 

                 

                Not sure what I am missing.

                • 5. Re: 11g and 12c om the same windows machine. listened for 12c not sarting up
                  EdStevens

                  prasad.puranik wrote:

                   

                  Thanks Ed. Although I didn't write it down 100 times, I get what you mean. I have now set up a test environment to try this out and have configured only one listener (the 12c one) as you said (with default port - 1521). Now what I'm seeing is it's able to connect to only one instance at a time. If I start the 11g service first and 12c service next, then I can connect only to 11g instance. On trying to connect to 12c instance, I get this error..

                  ORA-12528, TNS:listener: all appropriate instances are blocking new connections

                   

                   

                  All my searches on this error are telling me to wait for some time and try again because the database might not be started yet. But I checked and both the databases are up and running. I can connec to them using sql plus on the lcoal machine.

                   

                   

                  Note that if I start 12c service first and then 11g, then I can connect only to 12c and on trying to connect to 11g I get the same error.

                   

                   

                  This is my connect string for 11g..

                  jdbc:oracle:thin:@machinename.domainname:1521:orcl

                  and this is for 12c..

                  jdbc:oracle:thin:@machinename.domainname:1521:orcl12c

                   

                   

                  Here's my tnsnames.ora..

                  If you are using jdbc thin client, your are NOT using your tnsnames.ora, so whatever is in that is irrelevent.  The only service tnsnames.ora provides is a resolution of an alias to a machine:port:service, and that spec is already in your connection string.

                   

                   

                   

                  <snip>

                   

                  Not sure what I am missing.

                  how about the output of 'lsnrctl status' and 'lsnrctl services'?  THOSE commands tell us what the listener is actually doing, irrespective of a listener.ora file that may or may not have been used by the particular listener.

                  • 6. Re: 11g and 12c om the same windows machine. listened for 12c not sarting up
                    prasad.puranik

                    ok.. Here's the output...

                     

                     

                     

                     

                     

                    C:\Users\Administrator>lsnrctl status

                     

                     

                    LSNRCTL for 64-bit Windows: Version 12.1.0.1.0 - Production on 12-JUN-2014 06:32:12

                     

                     

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

                     

                     

                    Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=IDCDVNOC701.BLRQELAB.LOCAL)(PORT=1521)))

                    STATUS of the LISTENER

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

                    Alias                     LISTENER

                    Version                   TNSLSNR for 64-bit Windows: Version 12.1.0.1.0 - Production

                    Start Date                12-JUN-2014 02:54:52

                    Uptime                    0 days 3 hr. 37 min. 20 sec

                    Trace Level               off

                    Security                  ON: Local OS Authentication

                    SNMP                      OFF

                    Listener Parameter File   C:\Oracle\product\12.1.0\dbhome_1\network\admin\listener.ora

                    Listener Log File         C:\Oracle\diag\tnslsnr\IDCDVNOC701\listener\alert\log.xml

                    Listening Endpoints Summary...

                      (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=IDCDVNOC701.BLRQELAB.LOCAL)(PORT=1521)))

                    Services Summary...

                    Service "CLRExtProc" has 1 instance(s).

                      Instance "CLRExtProc", status UNKNOWN, has 1 handler(s) for this service...

                    Service "orcl" has 1 instance(s).

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

                    Service "orcl.BLRQELAB.LOCAL" has 1 instance(s).

                      Instance "orcl12c", status BLOCKED, has 1 handler(s) for this service...

                    Service "orclXDB" has 1 instance(s).

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

                    The command completed successfully

                     

                     

                     

                     

                     

                     

                     

                     

                    C:\Users\Administrator>lsnrctl services

                     

                     

                    LSNRCTL for 64-bit Windows: Version 12.1.0.1.0 - Production on 12-JUN-2014 06:34:32

                     

                     

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

                     

                     

                    Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=IDCDVNOC701.BLRQELAB.LOCAL)(PORT=1521)))

                    Services Summary...

                    Service "CLRExtProc" has 1 instance(s).

                      Instance "CLRExtProc", status UNKNOWN, has 1 handler(s) for this service...

                        Handler(s):

                          "DEDICATED" established:0 refused:0

                             LOCAL SERVER

                    Service "orcl" has 1 instance(s).

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

                        Handler(s):

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

                             LOCAL SERVER

                    Service "orcl.BLRQELAB.LOCAL" has 1 instance(s).

                      Instance "orcl12c", status BLOCKED, has 1 handler(s) for this service...

                        Handler(s):

                          "DEDICATED" established:0 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: IDCDVNOC701, pid: 5812>

                             (ADDRESS=(PROTOCOL=tcp)(HOST=IDCDVNOC701.BLRQELAB.LOCAL)(PORT=59983))

                    The command completed successfully

                    • 7. Re: 11g and 12c om the same windows machine. listened for 12c not sarting up
                      EdStevens

                      prasad.puranik wrote:

                       

                      ok.. Here's the output...

                       

                       

                       

                       

                       

                      C:\Users\Administrator>lsnrctl status

                       

                       

                      LSNRCTL for 64-bit Windows: Version 12.1.0.1.0 - Production on 12-JUN-2014 06:32:12

                       

                       

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

                       

                       

                      Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=IDCDVNOC701.BLRQELAB.LOCAL)(PORT=1521)))

                      STATUS of the LISTENER

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

                      Alias                     LISTENER

                      Version                   TNSLSNR for 64-bit Windows: Version 12.1.0.1.0 - Production

                      Start Date                12-JUN-2014 02:54:52

                      Uptime                    0 days 3 hr. 37 min. 20 sec

                      Trace Level               off

                      Security                  ON: Local OS Authentication

                      SNMP                      OFF

                      Listener Parameter File   C:\Oracle\product\12.1.0\dbhome_1\network\admin\listener.ora

                      Listener Log File         C:\Oracle\diag\tnslsnr\IDCDVNOC701\listener\alert\log.xml

                      Listening Endpoints Summary...

                        (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=IDCDVNOC701.BLRQELAB.LOCAL)(PORT=1521)))

                      Services Summary...

                      Service "CLRExtProc" has 1 instance(s).

                        Instance "CLRExtProc", status UNKNOWN, has 1 handler(s) for this service...

                      Service "orcl" has 1 instance(s).

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

                      Service "orcl.BLRQELAB.LOCAL" has 1 instance(s).

                        Instance "orcl12c", status BLOCKED, has 1 handler(s) for this service...

                      Service "orclXDB" has 1 instance(s).

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

                      The command completed successfully

                       

                       

                       

                       

                       

                       

                       

                       

                      C:\Users\Administrator>lsnrctl services

                       

                       

                      LSNRCTL for 64-bit Windows: Version 12.1.0.1.0 - Production on 12-JUN-2014 06:34:32

                       

                       

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

                       

                       

                      Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=IDCDVNOC701.BLRQELAB.LOCAL)(PORT=1521)))

                      Services Summary...

                      Service "CLRExtProc" has 1 instance(s).

                        Instance "CLRExtProc", status UNKNOWN, has 1 handler(s) for this service...

                          Handler(s):

                            "DEDICATED" established:0 refused:0

                               LOCAL SERVER

                      Service "orcl" has 1 instance(s).

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

                          Handler(s):

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

                               LOCAL SERVER

                      Service "orcl.BLRQELAB.LOCAL" has 1 instance(s).

                        Instance "orcl12c", status BLOCKED, has 1 handler(s) for this service...

                          Handler(s):

                            "DEDICATED" established:0 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: IDCDVNOC701, pid: 5812>

                               (ADDRESS=(PROTOCOL=tcp)(HOST=IDCDVNOC701.BLRQELAB.LOCAL)(PORT=59983))

                      The command completed successfully

                      Do you see anything suspicious in the above output?

                      If no, why not?

                      If yes, what have you done to research it?

                       

                       

                       

                       

                      What is the name of the 11g database?

                      What is the name of the 12c database?

                       

                      select instance_name from v$instance;

                      show parameter local_listener

                      show parameter service_names

                      • 8. Re: 11g and 12c om the same windows machine. listened for 12c not sarting up
                        prasad.puranik

                        A disclaimer first. This is the first time i'm setting up an oracle database, let alone a dual database set up. So requesting you to be a bit patient with my ignorance.

                         

                        The BLOCKED one seems to be obviously not right. But researching on that message didn't get me anywhere new.

                         

                        Name of 11g database is orcl. Of 12c it is orcl12c.


                        running select instance_name from v$instance; on both the databases give me the same names (orcl and orcl12c).

                         

                        This is from 12c..

                        SQL> select instance_name from v$instance;

                        INSTANCE_NAME

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

                        orcl12c

                         

                        SQL> show parameter local_listener

                        NAME                                 TYPE        VALUE

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

                        local_listener                       string      LISTENER_ORCL12C

                         

                        SQL> show parameter service_names

                        NAME                                 TYPE        VALUE

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

                        service_names                        string      orcl.BLRQELAB.LOCAL

                         

                        this is from 11g

                        SQL> select instance_name from v$instance;

                        INSTANCE_NAME

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

                        orcl

                         

                        SQL> show parameter local_listener

                        NAME                                 TYPE        VALUE

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

                        local_listener                       string

                         

                        SQL> show parameter service_names

                        NAME                                 TYPE        VALUE

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

                        service_names                        string      orcl

                         

                        I see that there is no local listener for 11g. And I don't understand why the service name for 12c is showing as orcl.BLRQELAB.LOCAL. Is should be orcl12c, right?