This content has been marked as final. Show 7 replies
java.sql.SQLException: Io exception: The Network Adapter could not establish the connectionMost likely you should allow connection in Windows Firewall
Thanks for the reply.
But I am able to ping the host..Should that be fine?
But I am able to ping the host..Should that be fine?not necessarily. ping uses ICMP. JDBC uses TCP.
You need to enable TCP traffic to your server IP, port 1521 (or whatever your Listener there listens on), and, for the opened connection, back from that server (whatever port) to your Client.
Or enable it for application (java executable).
Thanks for you reply again. Can you tell me how to do it?
open Control Panel, Windows Firewall, Advanced Settings.
Select Inbound Rules.
Add New Rule: Custom, All programs, proto TCP, All Local Ports, Any Local IP, Remote IP <Oracle Server Host IP>, Allow Connection.
I am thinking Some of the features including java and oracle are not working.......................
You can test connectivity via telnet to the Oracle port: "telnet dev64-scan 1521". If that opens a connection, your firewall is not in the way.
You can test your tnsnames configuration with sqlplus. If sqlplus can connect you to your instance on dev64-scan, your tnsnames and listener are correct.
If telnet and sqlplus are good and you still can't connect via jdbc, you might try a jdbc-based utility such as the SQL Explorer plugin for Eclipse, or an equivalent. If you can enter your connect information and reach the db that way, you know your jdbc drivers and configuration are correct.
Hope this helps.