JDBC Connection Problem
Posted by: Madi B
Date: March 06, 2005 04:15PM

Hi all,
I have been tryins to connect from linux and windows to a distant mySQL database without any success. When trying from other computers, using the same mySQL driver (driver version 3.0.9) it works juste perfect. I tried with both java versions (1.4 and 1.5)
And i also tried connection with DBVISUALIZER, SQL UNiform and directly from a java script i wrote but i still get the same message.

The error message that i get is the following :

java.sql.SQLException: Unable to connect to any hosts due to exception: java.net.ConnectException: Connection timed out: connect
at com.mysql.jdbc.Connection.createNewIO(Connection.java:1797)
at com.mysql.jdbc.Connection.<init>(Connection.java:562)
at com.mysql.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:361)
at java.sql.DriverManager.getConnection(Unknown Source)
at java.sql.DriverManager.getConnection(Unknown Source)
at com.onseven.dbvis.wrapper.DriverManagerImpl.getConnection(DriverManagerImpl.java:40)
at com.onseven.dbvis.sql.Database.doConnect(Unknown Source)
at com.onseven.dbvis.sql.Database.access$000(Unknown Source)
at com.onseven.dbvis.sql.Database$ConnectionCommand.execute(Unknown Source)
at se.pureit.util.ThreadCommand.runExecute(ThreadCommand.java:163)
at se.pureit.util.ThreadCommand.run(ThreadCommand.java:143)
at java.lang.Thread.run(Unknown Source)

Any help would be greatly appreciated.

Mahdi

Options: ReplyQuote


Subject
Written By
Posted
JDBC Connection Problem
March 06, 2005 04:15PM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.