12 Replies Latest reply: May 1, 2012 1:18 AM by 934200 RSS

    Database listener and Application tier startup problems

    838132
      Hi All,

      I newly installed Oracle R12 and was trying to start up database listener , database and application tier.

      First when I started database listener. I was getting below errors

      LSNRCTL for Linux: Version 11.1.0.7.0 - Production on 26-SEP-2011 00:11:14

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

      Starting /u01/app/oracle/PROD/db/tech_st/11.1.0/bin/tnslsnr: please wait...

      TNSLSNR for Linux: Version 11.1.0.7.0 - Production
      System parameter file is /u01/app/oracle/PROD/db/tech_st/11.1.0/network/admin/PROD_oracleerp/listener.ora
      Log messages written to /u01/app/oracle/PROD/db/tech_st/11.1.0/log/diag/tnslsnr/oracleerp/prod/alert/log.xml
      Error listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=oracleerp.localdomain.com)(PORT=1522)))
      TNS-12542: TNS:address already in use
      TNS-12560: TNS:protocol adapter error
      TNS-00512: Address already in use
      Linux Error: 98: Address already in use


      When I started database it went fine

      and Again when i tried to start applications I was getting error

      [applmgr@oracleerp scripts]$ ./adstrtal.sh apps/apps

      You are running adstrtal.sh version 120.15


      adstrtal.sh: Database connection could not be established. Either the database is down or the APPS credentials supplied are wrong.

      USAGE: adstrtal.sh <appsusername/appspassword>


      adstrtal.sh: exiting with status 1

      When I was connecting to sql was able to conn apps/apps but was not able to start applications.


      Can anyone please help on this .. (Starting database listener and starting application tier)
        • 1. Re: Database listener and Application tier startup problems
          860213
          TNS-12542: TNS:address already in use
          TNS-12560: TNS:protocol adapter error
          TNS-00512: Address already in use
          Linux Error: 98: Address already in use
          First let us know status of listener, use below command:-
          lsnrctl status <lsnr_name>

          If it is not running then check what is holding up port 1522, use 'netstat -an | grep 1522' to check same, if possible kill session holding 1522 and then start listener.
          adstrtal.sh: Database connection could not be established. Either the database is down or the APPS credentials supplied are wrong.
          This can be due to listener issue. Test it afterwards.

          Thanks,
          JD
          • 2. Re: Database listener and Application tier startup problems
            EBSDBA
            Hi,
            ./adstrtal.sh apps/apps will only work when you have both listener and database up.



            Please post here the contents of

            1. /etc/hosts
            2. $TNS_ADMIN/listener.ora
            3. $netstat -an|grep 1522|grep LISTEN

            Thanks
            • 3. Re: Database listener and Application tier startup problems
              838132
              Hi,

              This was the current status of database listener

              [oracle@oracleerp PROD_oracleerp]$ lsnrctl status PROD

              LSNRCTL for Linux: Version 11.1.0.7.0 - Production on 26-SEP-2011 01:23:26

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

              Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=oracleerp.localdomain.co m)(PORT=1522)))
              TNS-12532: TNS:invalid argument
              TNS-12560: TNS:protocol adapter error
              TNS-00502: Invalid argument
              Linux Error: 113: No route to host

              And this was the result of command you referred. Let me know how can i proceed further

              [oracle@oracleerp PROD_oracleerp]$ netstat -an | grep 1522
              tcp 0 0 0.0.0.0:1522 0.0.0.0:* LIST EN
              • 4. Re: Database listener and Application tier startup problems
                838132
                Hi,

                Here are the ones you asked

                1)

                [oracle@oracleerp PROD_oracleerp]$ cat /etc/hosts
                # Do not remove the following line, or various programs
                # that require network functionality will fail.
                192.168.0.108 oracleerp.localdomain.com oracleerp

                127.0.0.1 localhost.localdomain localhost
                [oracle@oracleerp PROD_oracleerp]$ ifconfig
                eth0 Link encap:Ethernet HWaddr 00:0C:29:6D:82:99
                inet addr:192.168.0.117 Bcast:192.168.0.255 Mask:255.255.255.0
                inet6 addr: fe80::20c:29ff:fe6d:8299/64 Scope:Link
                UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
                RX packets:92621 errors:0 dropped:0 overruns:0 frame:0
                TX packets:15944 errors:0 dropped:0 overruns:0 carrier:0
                collisions:0 txqueuelen:1000
                RX bytes:60131103 (57.3 MiB) TX bytes:1117620 (1.0 MiB)
                Interrupt:185 Base address:0x2024

                lo Link encap:Local Loopback
                inet addr:127.0.0.1 Mask:255.0.0.0
                inet6 addr: ::1/128 Scope:Host
                UP LOOPBACK RUNNING MTU:16436 Metric:1
                RX packets:3147 errors:0 dropped:0 overruns:0 frame:0
                TX packets:3147 errors:0 dropped:0 overruns:0 carrier:0
                collisions:0 txqueuelen:0
                RX bytes:3765858 (3.5 MiB) TX bytes:3765858 (3.5 MiB)

                Is that the ip address is different in ifconfig output and is in /etc/hosts

                Is this could be reason as ipaddress is changing and not static...


                2) Output of TNS_ADMIN/listener.ora

                [oracle@oracleerp PROD_oracleerp]$ cat listener.ora
                #
                # $Header: ad8ilsnr.ora 120.3 2007/12/18 10:13:38 sbandla ship $
                #
                # ###############################################################
                #
                # This file is automatically generated by AutoConfig. It will be read and
                # overwritten. If you were instructed to edit this file, or if you are not
                # able to use the settings created by AutoConfig, refer to Metalink Note
                # 387859.1 for assistance.
                #
                # ###############################################################

                #

                #
                # Net8 definition for Database listener
                #

                PROD =
                (DESCRIPTION_LIST =
                (DESCRIPTION =
                (ADDRESS = (PROTOCOL = TCP)(HOST = oracleerp.localdomain.com)(PORT = 1522))
                )
                )

                SID_LIST_PROD =
                (SID_LIST =
                (SID_DESC =
                (ORACLE_HOME= /u01/app/oracle/PROD/db/tech_st/11.1.0)
                (SID_NAME = PROD)
                )
                )

                STARTUP_WAIT_TIME_PROD = 0
                CONNECT_TIMEOUT_PROD = 10
                TRACE_LEVEL_PROD = OFF

                LOG_DIRECTORY_PROD = /u01/app/oracle/PROD/db/tech_st/11.1.0/network/admin
                LOG_FILE_PROD = PROD
                TRACE_DIRECTORY_PROD = /u01/app/oracle/PROD/db/tech_st/11.1.0/network/admin
                TRACE_FILE_PROD = PROD
                ADMIN_RESTRICTIONS_PROD = OFF
                SUBSCRIBE_FOR_NODE_DOWN_EVENT_PROD = OFF


                IFILE=/u01/app/oracle/PROD/db/tech_st/11.1.0/network/admin/PROD_oracleerp/listener_ifile.ora
                • 5. Re: Database listener and Application tier startup problems
                  838132
                  3_)

                  netstat -an|grep 1522|grep LISTEN
                  tcp 0 0 0.0.0.0:1522 0.0.0.0:* LISTEN
                  • 6. Re: Database listener and Application tier startup problems
                    EBSDBA
                    Hi,

                    From your last output we can say that 1522 is busy. It could be listener or any other process.
                    You can check if your listener is up or not using

                    $ps -ef|grep tns

                    Also

                    Please make sure your firewall is disabled.
                    11g: TNS-12532 / ORA-12532 Reported When Firewall Is Enabled [ID 748466.1]

                    Thanks
                    • 7. Re: Database listener and Application tier startup problems
                      479344
                      Try /usr/sbin/lsof -i :1522 to get the id of the process that is occupying 1522 port.
                      • 8. Re: Database listener and Application tier startup problems
                        934200
                        Hi,
                        I too got the same error after installing Oracle Apps R12. When i start database listener it is giving the same errors as discussed above and followed the steps u mentioned but unable to start the listener......

                        I followed ur steps got the same outputs as above. When i checked the output of
                        ps -ef| grep tns got the following output
                        oraprod 3551 1 0 06:20 ? 00:00:00 /d01/prod/db/tech_st/11.1.0/bin/tnslsnr PROD -inherit

                        [root@of440 ~]# lsof -i:1521
                        COMMAND PID USER FD TYPE DEVICE SIZE NODE NAME
                        tnslsnr 3551 oraprod 8u IPv4 16028 TCP *:ncube-lm (LISTEN)
                        oracle 4402 oraprod 21u IPv4 53035 TCP 192.168.1.100:46712->of440.osmani.com:ncube-lm (SYN_SENT)
                        It means the listener is already running...and what is second line in the output... But I did not understand when i checked the status of the listener. It shows

                        [oraprod@of440 11.1.0]$ lsnrctl status PROD

                        LSNRCTL for Linux: Version 11.1.0.7.0 - Production on 01-MAY-2012 07:37:40

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

                        Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=of440.osmani.com)(PORT=1521)))
                        TNS-12535: TNS:operation timed out
                        TNS-12560: TNS:protocol adapter error
                        TNS-00505: Operation timed out
                        Linux Error: 110: Connection timed out

                        What might be the reasons for this.... and how come the listener is already running.. I just started my system.

                        and I killed the PIDs of processes shown in the above output using
                        # kill -9 3551
                        # kill -9 4402

                        Now I started the listener again, but got the following errror... different from the one which I got previously.
                        [oraprod@of440 ~]$ lsnrctl start PROD

                        LSNRCTL for Linux: Version 11.1.0.7.0 - Production on 01-MAY-2012 07:55:32

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

                        Starting /d01/prod/db/tech_st/11.1.0/bin/tnslsnr: please wait...

                        TNSLSNR for Linux: Version 11.1.0.7.0 - Production
                        System parameter file is /d01/prod/db/tech_st/11.1.0/network/admin/PROD_of440/listener.ora
                        Log messages written to /d01/prod/db/tech_st/11.1.0/log/diag/tnslsnr/of440/prod/alert/log.xml
                        Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=of440.osmani.com)(PORT=1521)))

                        Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=of440.osmani.com)(PORT=1521)))
                        TNS-12535: TNS:operation timed out
                        TNS-12560: TNS:protocol adapter error
                        TNS-00505: Operation timed out
                        Linux Error: 110: Connection timed out

                        Could u plz help me out in this matter......

                        Thanx.
                        Abbu
                        • 9. Re: Database listener and Application tier startup problems
                          Hussein Sawwan-Oracle
                          What is the entry you have in the listener.ora file?

                          Do you have proper entry in the hosts file?

                          Thanks,
                          Hussein
                          • 10. Re: Database listener and Application tier startup problems
                            934200
                            The listener.ora file contains the following output
                            #
                            # Net8 definition for Database listener
                            #

                            PROD =
                            (DESCRIPTION_LIST =
                            (DESCRIPTION =
                            (ADDRESS = (PROTOCOL = TCP)(HOST = of440.osmani.com)(PORT = 1521))
                            )
                            )

                            SID_LIST_PROD =
                            (SID_LIST =
                            (SID_DESC =
                            (ORACLE_HOME= /d01/prod/db/tech_st/11.1.0)
                            (SID_NAME = PROD)
                            )
                            )

                            STARTUP_WAIT_TIME_PROD = 0
                            CONNECT_TIMEOUT_PROD = 10
                            TRACE_LEVEL_PROD = OFF

                            LOG_DIRECTORY_PROD = /d01/prod/db/tech_st/11.1.0/network/admin
                            LOG_FILE_PROD = PROD
                            TRACE_DIRECTORY_PROD = /d01/prod/db/tech_st/11.1.0/network/admin
                            TRACE_FILE_PROD = PROD
                            ADMIN_RESTRICTIONS_PROD = OFF
                            SUBSCRIBE_FOR_NODE_DOWN_EVENT_PROD = OFF


                            IFILE=/d01/prod/db/tech_st/11.1.0/network/admin/PROD_of440/listener_ifile.ora


                            and cat /etc/hosts
                            # Do not remove the following line, or various programs
                            # that require network functionality will fail.
                            127.0.0.1 localhost.localdomain localhost
                            183.83.164.23 of440.osmani.com of440
                            • 11. Re: Database listener and Application tier startup problems
                              Hussein Sawwan-Oracle
                              Please see these docs.

                              Fatal NI Connect Error 12170, 'TNS-12535: TNS:operation timed out' Reported in 11g Alert Log [ID 1286376.1]
                              ORA-12518 / TNS-12518 Troubleshooting [ID 556428.1]
                              Oracle Net Diagnostic Examples [ID 1384945.1]
                              Oracle Net SQLNET.SEND_TIMEOUT and SQLNET.RECV_TIMEOUT Parameters and errors ORA-12170 TNS-12535 ORA-12609 ORA-12608 [ID 1335630.1]

                              Thanks,
                              Hussein
                              • 12. Re: Database listener and Application tier startup problems
                                934200
                                Ok... thnx. I will look at it.