7 Replies Latest reply: Aug 23, 2013 9:36 AM by JeanParis RSS

    Tnsping failure issue

    JeanParis

      Hi,

       

      I'm not sure if I am in the proper forum.

      I have installed the 11G RDBMS with the sample database on Linux 6 for 64 bits.

      On another pc running Windows 7 I also have a sample database 11g.

      To set up sqlnet files I have followed all the advices in this link:

       

      Oracle Database 11g Release 2 (11.2) Installation On CentOs en mode manuel - Wiki.Tapriuneclak.com

       

      When I enter tnsping sid_name from a Windows cmd, I get a "timed out" error.

      Each pc can ping the other one.

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

      Here is the sqlnet.ora on the win7 pc:

       

      SQLNET.AUTHENTICATION_SERVICES= (NTS)

       

      NAMES.DIRECTORY_PATH= (TNSNAMES, EZCONNECT)

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

      And the listener.ora on the win 7 pc:

       

      SID_LIST_LISTENER =

        (SID_LIST =

          (SID_DESC =

            (SID_NAME = CLRExtProc)

            (ORACLE_HOME = E:\app\jbmp8z77\product\11.2.0\dbhome_1)

            (PROGRAM = extproc)

            (ENVS = "EXTPROC_DLLS=ONLY:E:\app\jbmp8z77\product\11.2.0\dbhome_1\bin\oraclr11.dll")

          )

        )

       

      LISTENER =

        (DESCRIPTION_LIST =

          (DESCRIPTION =

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

            (ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521))

          )

        )

       

      ADR_BASE_LISTENER = E:\app\jbmp8z77

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

      And the tnsnames.ora on the Win 7 pc:

      ORACLR_CONNECTION_DATA =

        (DESCRIPTION =

          (ADDRESS_LIST =

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

          )

          (CONNECT_DATA =

            (SID = CLRExtProc)

            (PRESENTATION = RO)

          )

        )

       

      ORASAME =

        (DESCRIPTION =

          (ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521))

          (CONNECT_DATA =

            (SERVER = DEDICATED)

            (SERVICE_NAME = orasame)

          )

        )

       

       

      ORARIM =

        (DESCRIPTION =

          (ADDRESS = (PROTOCOL = TCP)(HOST = ol6jbm)(PORT = 1521))

          (CONNECT_DATA =

            (SERVER = DEDICATED)

            (SERVICE_NAME = orarim)

          )

        )

       

       

       

      LISTENER_ORASAME =

        (ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521))

       

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

      I have not disabled the firewall on the Linux pc.

       

      I think maybe there is a parameter in the spfile to tell the Oracle database on the linux server that it can accept remote connexions, but I can't find it.

       

      Many thanks for your help

        • 1. Re: Tnsping failure issue
          botang(唐波)

          1) There is NOT a parameter to tell  the Oracle database on the linux server that it can accept remote connexions.

          2) check linux firewall:

          root#]  iptables -L -n

           

          to see if your port (1521) is filtered.

           

          3) check win7 firewall too

          • 2. Re: Tnsping failure issue
            EdStevens

            JeanParis wrote:

             

            Hi,

             

            I'm not sure if I am in the proper forum.

            I have installed the 11G RDBMS with the sample database on Linux 6 for 64 bits.

            On another pc running Windows 7 I also have a sample database 11g.

            To set up sqlnet files I have followed all the advices in this link:

             

            Oracle Database 11g Release 2 (11.2) Installation On CentOs en mode manuel - Wiki.Tapriuneclak.com

             

            When I enter tnsping sid_name from a Windows cmd, I get a "timed out" error.

             

            Too bad you didn't show us the actual command and response.  Copy and paste from that command session would have been very helpful.

             

             

             

            Each pc can ping the other one.

            That's a good start.

             

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

            Here is the sqlnet.ora on the win7 pc:

             

            SQLNET.AUTHENTICATION_SERVICES= (NTS)

             

            NAMES.DIRECTORY_PATH= (TNSNAMES, EZCONNECT)

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

            And the listener.ora on the win 7 pc:

             

            SID_LIST_LISTENER =

              (SID_LIST =

                (SID_DESC =

                  (SID_NAME = CLRExtProc)

                  (ORACLE_HOME = E:\app\jbmp8z77\product\11.2.0\dbhome_1)

                  (PROGRAM = extproc)

                  (ENVS = "EXTPROC_DLLS=ONLY:E:\app\jbmp8z77\product\11.2.0\dbhome_1\bin\oraclr11.dll")

                )

              )

             

            LISTENER =

              (DESCRIPTION_LIST =

                (DESCRIPTION =

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

                  (ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521))

            BZZT!  configuring the listener for 'localhost' absolutely guarantees that the listener will never receive a request from any other machine.  A listener configured for localhost is pretty much useless.  It should sepcify HOST=<the routable ip address of the machine>  or HOST=<a machine name that will resolve to the routable IP address of the machine>

             

                )

              )

             

            ADR_BASE_LISTENER = E:\app\jbmp8z77

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

            And the tnsnames.ora on the Win 7 pc:

            ORACLR_CONNECTION_DATA =

              (DESCRIPTION =

                (ADDRESS_LIST =

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

                )

                (CONNECT_DATA =

                  (SID = CLRExtProc)

                  (PRESENTATION = RO)

                )

              )

             

            ORASAME =

              (DESCRIPTION =

                (ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521))

            Again, localhost is not routable.  When a client process (this is basic networking, not oracle) requests a message be sent to 'localhost', the request never leaves the machine from which it originates.

             

                (CONNECT_DATA =

                  (SERVER = DEDICATED)

                  (SERVICE_NAME = orasame)

                )

              )

             

             

            ORARIM =

              (DESCRIPTION =

                (ADDRESS = (PROTOCOL = TCP)(HOST = ol6jbm)(PORT = 1521))

                (CONNECT_DATA =

                  (SERVER = DEDICATED)

                  (SERVICE_NAME = orarim)

                )

              )

             

             

             

            LISTENER_ORASAME =

              (ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521))

             

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

            I have not disabled the firewall on the Linux pc.

             

            I think maybe there is a parameter in the spfile to tell the Oracle database on the linux server that it can accept remote connexions, but I can't find it.

            There is no such parameter.  It's not up to the database to determine from where it will accept connections.

             

            Start here: http://edstevensdba.wordpress.com/2011/02/09/sqlnet_overview/  (Help! I can’t connect to my database  )

             

             

            Many thanks for your help

            There is no such

            • 3. Re: Tnsping failure issue
              JeanParis

              Hi,

               

              I replaced all "localhost" entries with the name of the win 7 pc in the "etc\drivers\hosts" file.

              I deactivated the antivirus firewall on the pc win 7.

              I restarted the listener on the win 7 pc and entered again "tnsping orarim".

              I get the error "TNS-12535".

               

              Many thanks for your help.

              • 4. Re: Tnsping failure issue
                sb92075

                JeanParis wrote:

                 

                Hi,

                 

                I replaced all "localhost" entries with the name of the win 7 pc in the "etc\drivers\hosts" file.

                I deactivated the antivirus firewall on the pc win 7.

                I restarted the listener on the win 7 pc and entered again "tnsping orarim".

                I get the error "TNS-12535".

                 

                Many thanks for your help.

                 

                12535, 00000, "TNS:operation timed out"

                // *Cause: The requested operation could not be completed within the time out

                // period.

                // *Action: Look at the documentation on the secondary errors for possible

                // remedy. See SQLNET.LOG to find secondary error if not provided explicitly.

                // Turn on tracing to gather more information.

                 

                 

                Most likely problem is a Firewall on or between client & DB Server

                • 5. Re: Tnsping failure issue
                  EdStevens

                  JeanParis wrote:

                   

                  Hi,

                   

                  I replaced all "localhost" entries with the name of the win 7 pc in the "etc\drivers\hosts" file.

                   

                  I could read that two ways ...

                  Did you modify the listener.ora, replacing 'localhost' with the name of the host, as found in the hosts file? 

                  Or did you modify the hosts file itself, messing up the required 'localhost' entries?

                   

                  I deactivated the antivirus firewall on the pc win 7.

                  I restarted the listener on the win 7 pc and entered again "tnsping orarim".

                  I get the error "TNS-12535".

                  Again, too bad you didn't show us the actual command and response.  Copy and paste from that command session would have been very helpful the first time.  It would have been very helpful this time.  Is there some reason you seem to refuse to use it?

                   

                  Many thanks for your help.

                  Help us to help you by showing what you actually did (copy and paste) instead of describing what you think you did.

                  • 6. Re: Tnsping failure issue
                    JeanParis

                    Hi

                     

                    I just typed

                    "service ipchains stop", but this Linux don't seem to know it.

                    Then I typed

                    "service iptables stop"

                    And I got three messages [OK]

                    Then I typed from the Dos windows

                    DOS>tnsping orarim

                    And I got the OK before I finished typing...That's Isaac Asimov fast....

                    Many thanks for your help

                    • 7. Re: Tnsping failure issue
                      JeanParis

                      I'm sorry I did not properly fill in my message.

                      I'll try better next time.

                      At the moment I got it working thanks to you.