In order to get MySQL working with a Grails app, I copied the JAR from the apt package (using Ubuntu Server 10.10, file is “/usr/share/java/mysql-connector-java-5.1.10.jar”) to the Grails application’s “lib” directory.
Then in the data source settings I changed the database URL to url = "jdbc:mysql://127.0.0.1:3306/databasename?autoreconnect=true".
But now running the app gives me the error “ClassNotFoundException: org.mysql.jdbc.Driver”. Similar problems on the mailing list didn’t provide a solution to this. I’ve also tried to add the connector as dependency (+ Maven repos) but that didn’t work either.
The JAR is obviously the correct file, so what can I do about this?
Change the driver name to: