-
1. Re: mysql connection refused
rgjawanda Jan 6, 2007 1:25 PM (in response to rgjawanda)Here is my datasource binding with no exceptions.
13:24:40,333 INFO [WrapperDataSourceService] Bound connection factory for resource adapter for ConnectionManager 'jboss.jca:service=DataSourceBinding,name=MySqlDSL to JNDI name 'java:MySqlDSL'
13:24:41,641 INFO
Here is the actual exception
13:17:18,695 WARN [JBossManagedConnectionPool] Throwable while attempting to get a new connection: null
org.jboss.resource.JBossResourceException: Could not create connection; - nested throwable: (com.mysql.jdbc.CommunicationsException: Communications link failure due to underlying exception:
** BEGIN NESTED EXCEPTION **
java.net.SocketException
MESSAGE: java.net.ConnectException: Connection refused
STACKTRACE:
java.net.SocketException: java.net.ConnectException: Connection refused
at com.mysql.jdbc.StandardSocketFactory.connect(StandardSocketFactory.java:156)
at com.mysql.jdbc.MysqlIO.(MysqlIO.java:284)
at com.mysql.jdbc.Connection.createNewIO(Connection.java:2569)
at com.mysql.jdbc.Connection.(Connection.java:1485)
at com.mysql.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:266)
at org.jboss.resource.adapter.jdbc.local.LocalManagedConnectionFactory.createManagedConnection(LocalManagedConnectionFactory.java:151)
at org.jboss.resource.connectionmanager.InternalManagedConnectionPool.createConnectionEventListener(InternalManagedConnectionPool.java:508)
at org.jboss.resource.connectionmanager.InternalManagedConnectionPool.getConnection(InternalManagedConnectionPool.java:207)
at org.jboss.resource.connectionmanager.JBossManagedConnectionPool$BasePool.getConnection(JBossManagedConnectionPool.java:534) -
2. Re: mysql connection refused
peterj Jan 7, 2007 2:45 PM (in response to rgjawanda)The "connection refused" error message typically means that the server is not listening on the port, or that the firewall has the port blocked. Did you change the default port for MySQL (it usually uses port 3306)? Have you tried turning off iptables (I assume that is the firewall you are using)?
-
3. Re: mysql connection refused
rgjawanda Jan 9, 2007 1:17 PM (in response to rgjawanda)It was a little confusing but I got it working.
I had changed the port tp 3305 and thought I fixed the xml configuration file. It now works. Thanks for your post.