Skip to content
Advertisement

Linux Mandriva: Tomcat can not get MySQL database connection, why?

I installed Tomcat 7 and MySQL database on Linux Mandriva, but the application is deployed in the container can not get a connection.

I wrote two simple tests, and when to run them from the client, I get the connection –

JavaScript

Part of HibernateUtil –

JavaScript

Jdbc test –

JavaScript

In these cases, I get a connection and can work with the database. But when I request from the client browser, I get a timeout. Why is that? I would be very grateful for the information.


Here is the catalina.out

JavaScript

Advertisement

Answer

I’m not familiar with Hibernate, so I don’t know if this is relevant:

“hibernate.properties not found”

“using driver: com.mysql.jdbc.Driver at URL: jdbc:mysql://—ip here—-/gibrid”

Is the IP and port the same as in your test programs?

This blog hints at configuration problems with C3PO. One comment hints at different timeout settings between Mysql and C3PO. HTH

User contributions licensed under: CC BY-SA
2 People found this is helpful
Advertisement