MySQL Connections

Six Stars jay
Six Stars

MySQL Connections

Hello,

I've been scratching my head trying to figure out how to connect to a different instance (connection) in MySQL and any search/help was fruitless. 
I have several Connections in MySQL, several internal and some external. Instead of recreating these connection in Talend I want to be able to connect directly to a particular connection. As an example I have
Local instance MySQL57
BSD (This is an external database)
SDB (This is another internal database)

I want to setup a metadata connection for BSD. How can I do that? 
I am trying to overcome a basic issue with the tmysqlconnection component. It gives me an error (Connection failure. You must change the Database Settings. java.lang.RuntimeException: java.sql.SQLException: Access denied for user 'xyz'@'IP Address here' (using password: YES)) when I try setup the connection directly in Talend however I'm still able to connect using MySQL connection and query the database tables. I have tried many different ways to get this working but none of them have worked so far and I'm reluctant to go back to the external company to ask them to make a change that might cause a security issue due to the sensitive nature of the data.

Thanks
Jay

Forteen Stars

Re: MySQL Connections

Not sure - what Your try to do globally,
If I correct understand You - You can create single DB connection (Left side of screen - Metadata) and define it as context based
than create as many context environment as You want 

about error

Access denied for user 'xyz'@'IP Address here' (using password: YES))

it very clean - check the user permission. How Your user (which You use to connect from Talend) defined in database:
[list=*]
  • check password

  • check allowed hosts

  • try to connect with same user from Talend Machine with mysql command line client and see what happens

  • -----------
    Six Stars jay
    Six Stars

    Re: MySQL Connections

    Thanks vapukov. You are partly correct in understanding what I want to do. I've created a single DB connection in Metadata but now get a different error message when I use the connection for BSD:
    java.lang.RuntimeException: com.mysql.jdbc.exceptions.jdbc4.CommunicationsException: Communications link failure
    The last packet sent successfully to the server was 0 milliseconds ago. The driver has not received any packets from the server.

    How is it that I can connect successfully to this external database using MySQL but not the component when I am referencing this same connection in the component?

    Jay
    Forteen Stars

    Re: MySQL Connections

    without pictures - we can only guess what are You make wrong
    it common error - I do all same, but have error only there!!! Smiley Happy
    in fact it mean - something difference in settings. Compare Your MySQL client (as I can guess MySQL Workbench) and Talend settings
    as example - MySQL Workbench could connect over ssh tunnel ...
    I just can confirm - it work!
      
    -----------
    Four Stars

    Re: MySQL Connections

    vapukov wrote:
    without pictures - we can only guess what are You make wrong
    it common error - I do all same, but have error only there!!! Smiley Happy
    in fact it mean - something difference in settings. Compare Your MySQL client (as I can guess MySQL Workbench) and Talend settings
    as example - MySQL Workbench could connect over ssh tunnel ...
    I just can confirm - it work!

    Are your MySql connection use SSH?
    I have a problem to connect to MySql with SSH, i dont know about the command on tSSH or tSystem.

    Can you tell me?

    2019 GARNER MAGIC QUADRANT FOR DATA INTEGRATION TOOL

    Talend named a Leader.

    Get your copy

    OPEN STUDIO FOR DATA INTEGRATION

    Kickstart your first data integration and ETL projects.

    Download now

    What’s New for Talend Summer ’19

    Watch the recorded webinar!

    Watch Now

    Best Practices for Using Context Variables with Talend – Part 1

    Learn how to do cool things with Context Variables

    Blog

    Migrate Data from one Database to another with one Job using the Dynamic Schema

    Find out how to migrate from one database to another using the Dynamic schema

    Blog

    Best Practices for Using Context Variables with Talend – Part 4

    Pick up some tips and tricks with Context Variables

    Blog