AWS Glue MySQL connection problem

0

I'm trying to connect my AWS Glue in us-east-2 to my AWS RDS MySQL DB in same region.

I was following this article - https://aws.amazon.com/blogs/big-data/how-to-access-and-analyze-on-premises-data-stores-using-aws-glue/ and getting the following error

Check that your connection definition references your JDBC database with correct URL syntax, username, and password. 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.

I have created the security group for glue in default VPC and have chosen the same VPC while defining the JDBC connection in AWS Glue jdbc:mysql:/xxxxxxxxxx.us-east-2.rds.amazonaws.com:3306/{DB_NAME}

Some logs

  • Driver to be used jar:file:/tmp/mysql-connector-java.jar!/ com.mysql.jdbc.Driver
  • Connection url = jdbc:mysql:/xxxxxxxxxx.us-east-2.rds.amazonaws.com:3306/{DB_NAME} SSL certificate =
  • DomainName used for host matching =
  • Driver properties = com.amazonaws.glue.jobexecutor.commands.jdbc.JdbcDriverProperties@e9cc7a4f
  • === Driver com.mysql.jdbc.Driver@4bff1903, Version 8.0 ===
  • Starting connecter. driver com.mysql.jdbc.Driver@4bff1903
  • Attempting to connect with SSL host matching: jdbc:mysql:/xxxxxxxxxx.us-east-2.rds.amazonaws.com:3306/{DB_NAME}
  • Attempting to connect with TLS 1.2 host matching
  • TLS1.2 connection failed: 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.
  • TLS 1.2 connection to data store using host matching failed. Retrying with legacy properties.
  • TLS1.2 connection failed: 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.
  • TLS 1.2 connection to data store using host matching legacy properties failed.
  • SSL connection to data store using host matching failed. Retrying without host matching. 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.
  • Attempting to connect with SSL: jdbc:mysql:/xxxxxxxxxx.us-east-2.rds.amazonaws.com:3306/{DB_NAME}
  • Attempting to connect with TLS 1.2
  • TLS1.2 connection failed: 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.
3 Answers
0

Hi @AmerO

I have allowed all traffic in Inbound and Outbound rules of security group associated with AWS RDS instance. I suppose (correct me if I'm wrong), this should not be a problem for glue to access RDS

answered 5 months ago
0

[Updated] On the RDS side, are you allowing the IPs of the GLUE ENI in the Inbound rules for RDS Security Group? You can check the connectivity using VPC Reachability Analyzer on your AWS console. I find this article might be helpful to troubleshoot your issue: https://repost.aws/knowledge-center/glue-test-connection-failed

profile pictureAWS
AmerO
answered 5 months ago
0

@AmerO

Can you help?

answered 5 months ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions