Getting DB mysql error

I am getting access denied error while connecting mysql (screenshot attached)
ALso I have added all the AWS IPs in whitelist

Hi @sumitrathi

Connection errors are so frustrating aren’t they? Sorry to see that.

I assume you’ve double checked your credentials with your local MySQL client, like TablePlus or SequelPro.

Have you made sure that the database’s configuration allows all IPs to connect to it with mysql.conf? How To Allow Remote Access to MySQL | DigitalOcean

You mentioned allowing IP addresses, just not sure if you mean in your AWS EC2 security groups or some other firewall between the MySQL database and this workflow.

Yes credentials are correct and I am able to connect the database using workbench tool.
I am taking to this list of IPs

Hi @sumitrathi ,

Thanks for sharing the exact list you’re referring to for IP addresses to whitelist.

In this case those are IP addresses for HTTP requests, not Database connections.

Please refer to this documentation for MySQL and other non HTTP connections: Network / IP range

thanks for your quick reply.
If I want to connect mysql using above mentioned workflow (mysql.createconnection) then how can I connect

This link explains how you can setup a MySQL connection through a bastion server:

And here’s an example workflow using SSH tunneling to achieve that: https://pipedream.com/@dylburger/run-a-query-on-mysql-via-ssh-tunnel-p_rvCxrNB/edit

getting this error

From what I can I see, it looks like the SSH connection isn’t working. There are number of things to try:

  1. Make sure port 22 is open on the SSH server
  2. Make sure the SSH server is allowing connections from remote IP addresses

The SSH connection is just a security measure for those who can’t allow any IP address to access their MySQL server.

If SSH continues to give you trouble and you’re not restrained by unblocking all IP addresses, then allowing your MySQL server to be connected from any IP address is an option.

Hi,
SSH part is OK, Now getting connection timeout

Hi @sumitrathi ,

It looks the host property on like 19 is "localhost" which means that the workflow is trying to connect to MySQL running on itself.

Could you try updating the "localhost" property to match your MySQL server running outside of your workflow?