How do I troubleshoot problems connecting to Amazon Aurora?

Last updated: 2019-05-10

How do I troubleshoot problems connecting to an Amazon Relational Database Service (Amazon RDS) cluster or instance that's running Amazon Aurora?

Short Description

Here are common causes for issues connecting to an Amazon Aurora DB cluster or instance:

  • The Aurora DB cluster or instance is still being created and is not yet in the available state.
  • The DB instance security group, ACLs, or a local firewall are blocking the connection from the source instance or its IP addresses.
  • The route table that is associated with the subnets of your Amazon Virtual Private Cloud (Amazon VPC) isn't allowing or routing traffic from your local machine or DB instance.
  • The DB instance isn't publicly accessible when connecting from a local machine through the internet.
    DNS name resolution is failing, potentially because the client isn't connecting to the correct Aurora endpoint.
  • The Amazon RDS DB instance is undergoing instance recovery or failover because of an issue with the underlying hardware or database process, respectively.

Resolution

For help with resolving common connection problems on Amazon RDS, including Aurora instances, see How do I resolve problems connecting to my Amazon RDS database instance?

For Aurora DB clusters, be sure that your client is connecting to the correct endpoint. Because Amazon Aurora is a managed service, you must connect to Aurora DNS endpoints using MySQL client tools.

Be sure that you connect to the correct Aurora endpoint. To verify the cluster, reader, and custom endpoints that your client is currently connecting to, follow these steps:

1.    Open the Amazon RDS console.

2.    Choose Databases from the navigation pane.

3.    Choose your DB cluster from the group of resources, and then review the cluster details under the endpoint section of Connectivity & Security.

4.    Verify connectivity to the endpoint using telnet / nc:

telnet <RDS endpoint> <port number>
nc <RDS endpoint> <port number>

5.    After you connect, verify that you are connected to reader or writer endpoint by running the following command:

"SHOW GLOBAL VARIABLES LIKE 'innodb_read_only'; "

The innodb_read_only variable is set to ON if you are connected to an Aurora replica. If the variable is set to OFF, you are connected to the primary instance.


Did this article help you?

Anything we could improve?


Need more help?