Pentaho

 View Only

 Pentaho connection to MySql error

  • Pentaho
  • Kettle
  • Pentaho
  • Pentaho Data Integration PDI
Carlos Andiazabal's profile image
Carlos Andiazabal posted 03-14-2020 04:03

Hi Hema

 

This is Carlos from Milan (Italy). Could you help me, please?

 

From Pentaho when I click on button "Test Database Connection" it visualizes:

 

---------------------------------------------------------------------------------------------------------

Error connecting to database [test] :org.pentaho.di.core.exception.KettleDatabaseException: 

 

Error occurred while trying to connect to the database

 

 

Driver class 'org.gjt.mm.mysql.Driver' could not be found, make sure the 'MySQL' driver (jar file) is installed.

 

org.gjt.mm.mysql.Driver

 

org.pentaho.di.core.exception.KettleDatabaseException: 

 

Error occurred while trying to connect to the database

 

 

Driver class 'org.gjt.mm.mysql.Driver' could not be found, make sure the 'MySQL' driver (jar file) is installed.

 

org.gjt.mm.mysql.Driver

 

---------------------------------------------------------------------------------------------------------

 

It's evident that the problem is MySql connector.

 

- I downloaded mysql-connector-java-8.0.19.zip from MySql site

 

- unzipped it

 

- The only file .jar present is: mysql-connector-java-8.0.19.jar (in my opinion it should be 

 

mysql-connector-java-8.0.19-bin.jar but it's not present)

 

- I copied it on my data-integration\Lib but the problem remains.

 

Have you got any suggestion?

 

I'd really appreciate your feedback!

 

Best regards

 

Carlos


#Pentaho
#Kettle
#PentahoDataIntegrationPDI
Sergio Ribeiro's profile image
Sergio Ribeiro

(note that this is the same answer that I posted in the other post with the same title)

 

Hello @Carlos Andiazabal​,

 

You don't refer the Pentaho's version you're using...

At the JDBC drivers reference page (9.0) it's stated that, for MySQL, «Version 5.1.x is the most recent version supported».

There's a link to get the most recent connector (5.1.48) in that same location.

 

Regards,

 

Sérgio Ribeiro

Porto - Portugal.

 

Carlos Andiazabal's profile image
Carlos Andiazabal

Hi Sergio

 

Thank you very much for your prompt response.

 

I've downloaded and installed:

- Pentaho Data Integration-ce-9.0.0.0-423.zip 

- jdk-13.0.2_windows-x64_bin.exe 

- MySQL Server 8.0 

 

I'm thinking about reinstalling all again from scratch in view of the fact I don't see there are incompatibility between the three softwares.

 

If you have any suggestion please let me know.

 

Thanks

Sergio Ribeiro's profile image
Sergio Ribeiro

Hi @Carlos Andiazabal​,

 

JDK 13 is not supported: see https://help.pentaho.com/Documentation/9.0/Setup/Components_Reference#Java_virtual_machine

 

Regards,

 

Sérgio Ribeiro

Porto - Portugal

 

Carlos Andiazabal's profile image
Carlos Andiazabal

I solved it!!!!!!! Thanks so much Sergio!!!!

Lino Tzilacatzin Jasso Casas's profile image
Lino Tzilacatzin Jasso Casas

Hi there, I have the same problem, could you help me please??

 

Driver class 'org.gjt.mm.mysql.Driver' could not be found, make sure the 'MySQL' driver (jar file) is installed.

org.gjt.mm.mysql.Driver

 

I try to used the correponding driver that it is 8.0.23 with MySQL version but it doesn´t works....

 

Also I try onether drivers like previous version 8.0.22 and doesn´t works

 

My version of PDI is 9.1 and the version of MySQL is 8.0.23

 

Hoping your help, thanks in advance!!

Peter Sprenger's profile image
Peter Sprenger

Hi,

I have the same problem with same versions.

Thanks in advance

 

Sergio Ribeiro's profile image
Sergio Ribeiro

Hello @Peter Sprenger​ and @Lino Tzilacatzin Jasso Casas​,

 

Have you tried to used the most recent 5.1.x driver? It's 5.1.49, if I'm not mistaken.

 

Regards,

 

Sérgio Ribeiro

Porto - Portugal

 

Peter Sprenger's profile image
Peter Sprenger

Hi Sergio,

Thank you for your help! Let me first state that I am a PENTAHO newbie and have my difficulties -- apparently many commands in the manual seem not to be in the Linux/CE version.

 

However, I got it to work and for documentation reasons (at least I didn't find any suitable instructions for loading drivers) I outline what exactly I did (also to assure that I did the right thing):

 

To your question: I think the hint was to use the 5.1.49 drivers and somewhere deep in the instruction it said that you only can use version 5.1. Below are the steps I did ... please tell me if I did something wrong or unnecessary.

 

  • In 9.1 the drivers must go in /data-integration/plugins/databases/pdi-mysql-plugin/
  • In this directory I have a file called pdi-mysql-plugin-TRUNK-SNAPSHOT.jar and a file called version.xml -- both must be left untouched.
  • However, there is also a lib directory and in this directory there is a file called mysql-connector-java-5.1.23.jar
  • I copied both jars (mysql-connector-java-5.1.49.jar and a mysql-connector-java-5.1.49-bin.jar) into the directory called lib
  • Opening the 'Plugin Browser' I see both jars with their respective path

 

thank you and best regards

/peter

Sergio Ribeiro's profile image
Sergio Ribeiro

Hi @Peter Sprenger​,

 

For what you say, seems that you installed the "PDI MySql Plugin". To be honest, I've never had the need to use it but I assume that the only thing you'd need is to delete the prior "mysql-connector-java-5.1.23.jar" and replace it with the new "mysql-connector-java-5.1.49.jar" (don't copy the "-bin" jar as it can give you some problems).

 

What I normally do, is to paste the "mysql-connector-java-5.1.49.jar" into <PENTAHO>/design-tools/data-integration/lib and restart Pentaho.

 

Regards,

 

Sérgio Ribeiro

Porto - Portugal

 

Lino Tzilacatzin Jasso Casas's profile image
Lino Tzilacatzin Jasso Casas

Hi there,

 

I try the driver 8.0.23, the same as my MySQL version.

 

Also I just used that driver.