Solved

How do I resolve connection errors generated while using Toad

Posted on 2010-09-13
8
1,109 Views
Last Modified: 2012-05-10
I am trying to connect to a database server that is using port 1522. Whenever I try to connect from Toad on my laptop I get the following error: ORA-12170: TNS:Connect timeout occurred
When I tnsping from my laptop I get the following message: TNS-12535: TNS:operation timed out
When I connect to the database using Putty and tnsping the connection is instantaneous and the tnsping returns back the tns string and OK (0 msec)
There is no firewall on the database server I am trying to connect to. My laptop has Oracle installed and the listener is configured for port 1521. Can someone help me to resolve this issue?
0
Comment
Question by:sikyala
  • 3
  • 2
  • 2
  • +1
8 Comments
 
LVL 1

Accepted Solution

by:
mozzis earned 125 total points
ID: 33664752
The results using putty mean that you can connect to server via ssh (port 22) but not via Oracle protocol on port 1521. Are you quite certain there is no firewall on the server? That would be very unusual (as well as unwise.)
0
 

Author Comment

by:sikyala
ID: 33664769
I should have been more precise. There is no firewall blocking me from connecting to the database server.
0
 
LVL 34

Assisted Solution

by:johnsone
johnsone earned 250 total points
ID: 33665129
You say that the database is on port 1522.  What is the entry in the tnsnames.ora file for the database?  Does it reference port 1522?

You also say you have client installed on your laptop and the listener is configured for port 1521.  Are you running a listener on your laptop?  That wouldn't be required for a client connection.

I would also look in your putty setup.  You may have some port changes set up within putty that are redirecting your connection when you are connected through putty that you are not aware of.
0
 

Author Comment

by:sikyala
ID: 33665478
TNSNAMES.ORA entry:
<sid>.usae.<system name>.com =
  (DESCRIPTION =
    (ADDRESS_LIST =
      (ADDRESS = (PROTOCOL = TCP)(HOST = backupdb)(PORT = 1522))
    )
    (CONNECT_DATA =
      (SERVICE_NAME = <sid>.usae.<system name>.com)
    )
  )

Yes I have a listener on my laptop configured for port 1521 which is a part of the database server on my laptop.

0
PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

 
LVL 76

Assisted Solution

by:slightwv (䄆 Netminder)
slightwv (䄆 Netminder) earned 125 total points
ID: 33666307
TNSPING only talks to the listener. It doesn't not actually open up a connection to the database.

I know you've already said there is not a firewall between your laptop and the database server but 99.9% of the time when I see that error, it is some piece of network gear restricting the high ports.

Is the windows firewall on the laptop configured?

There are two ways around the random high-port issue with Oracle networking:  
- Configure Multi-Threaded server and you can limit the ports used to a few defined ones.
-Tell the Listener to not pick a random high port and keep everything on the listener port with the USE_SHARED_SOCKET variable.

Both of these work-arounds have negatives.
0
 
LVL 34

Assisted Solution

by:johnsone
johnsone earned 250 total points
ID: 33672598
Then the listener on the laptop does not enter into the picture.

If you use tnsping to get to the database from your laptop without an established putty connection what happens?  What happens with a putty connection established?

If tnsping works in at least one case above, then...  same questions for a database connection.

What I am thinking here is that port 1522 is allowed through the firewall and tnsping will work in all cases.  The database connection will fail without a putty connection, but due to some port forwarding or tunnelling set up in putty it will work with putty connected.

As slightwv said, these are typically firewall issues.  Something is probably letting through only port 1522.  This would allow tnsping to work in all cases, but the database connections wouldn't work in all cases.  An additional method around the port issues is to use connection manager.
0
 
LVL 1

Expert Comment

by:mozzis
ID: 33672856
OP already says tnsping does not work from laptop
0
 

Author Closing Comment

by:sikyala
ID: 33676354
johnsone you are right I had to create a  tunnel in putty and open a connection then open toad and it allowed me to log in successfully. slightwv i contacted the SAs and found out while there is no firewall on the server that is restricting connections there are some firewall restrictions based on the subnet that exist based on the location of the server if that makes any sense.
0

Featured Post

PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

Join & Write a Comment

Have you ever had to make fundamental changes to a table in Oracle, but haven't been able to get any downtime?  I'm talking things like: * Dropping columns * Shrinking allocated space * Removing chained blocks and restoring the PCTFREE * Re-or…
I remember the day when someone asked me to create a user for an application developement. The user should be able to create views and materialized views and, so, I used the following syntax: (CODE) This way, I guessed, I would ensure that use…
Via a live example show how to connect to RMAN, make basic configuration settings changes and then take a backup of a demo database
Via a live example, show how to restore a database from backup after a simulated disk failure using RMAN.

747 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now