Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
?
Solved

How do I resolve connection errors generated while using Toad

Posted on 2010-09-13
8
Medium Priority
?
1,252 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 500 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 35

Assisted Solution

by:johnsone
johnsone earned 1000 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
Get quick recovery of individual SharePoint items

Free tool – Veeam Explorer for Microsoft SharePoint, enables fast, easy restores of SharePoint sites, documents, libraries and lists — all with no agents to manage and no additional licenses to buy.

 

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
 
LVL 78

Assisted Solution

by:slightwv (䄆 Netminder)
slightwv (䄆 Netminder) earned 500 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 35

Assisted Solution

by:johnsone
johnsone earned 1000 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

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Working with Network Access Control Lists in Oracle 11g (part 1) Part 2: http://www.e-e.com/A_9074.html So, you upgraded to a shiny new 11g database and all of a sudden every program that used UTL_MAIL, UTL_SMTP, UTL_TCP, UTL_HTTP or any oth…
Configuring and using Oracle Database Gateway for ODBC Introduction First, a brief summary of what a Database Gateway is.  A Gateway is a set of driver agents and configurations that allow an Oracle database to communicate with other platforms…
Via a live example show how to connect to RMAN, make basic configuration settings changes and then take a backup of a demo database
This video shows information on the Oracle Data Dictionary, starting with the Oracle documentation, explaining the different types of Data Dictionary views available by group and permissions as well as giving examples on how to retrieve data from th…

578 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