problems connecting java and MYSQL

Hi everyone,

I am working on Suse 9.3

I have problems in connecting to MYSQL from Java.I am able to complie my java file but during execution i get the following errors.I have set my classpath to

mysql-connector-java.jar and

/usr/lib/jvm-exports/java-1.4.2-sun-1.4.2.05/jdbc-stdext-1.4.2.jar.

Errors

java.sql.SQLException: Unable to connect to any hosts due to exception: java.net.ConnectException: Connection refused

Could anyone help me to overcome this issue?

-Jegan

[535 byte] By [jagan18a] at [2007-10-1 22:45:09]
# 1
This error occurs because the mysql server is down.
cool_nitesha at 2007-7-13 14:49:45 > top of Java-index,Security,Java Secure Socket Extension (JSSE)...
# 2
If the sql server is down, it will not show such error, this error may occur due to improper declarations in ur code. Can u mention the way u r trying to connect to mysql?
UdhayaKumar_gseconea at 2007-7-13 14:49:45 > top of Java-index,Security,Java Secure Socket Extension (JSSE)...
# 3
connection = DriverManager.getConnection("jdbc:mysql://<DB IP>/....if your DB IP is not correct then also u will get this err.
nilesh_mishraa at 2007-7-13 14:49:45 > top of Java-index,Security,Java Secure Socket Extension (JSSE)...