Having a visual way to explore the database, run queries, take backups, view database schema, etc. is oftentimes quite handy. If you have your favorite SQL client and/or if you feel like using a CLI might not be the best choice for your situation, here’s a quick step-by-step guide that on connecting to AWS Aurora using a desktop client.
Finding necessary connection info in AWS console
- Log in to the AWS console
- Go to RDS
- Click Database instances
- Select the instance you want to connect to
- Note the endpoint and the port number for your connection
Connecting to AWS Aurora using a desktop SQL client
I’m using DBeaver as a client, but a similar process should for the Workbench and other utilities (here’s a quick list of the tools that might work for you).
Here’re the steps for DBeaver:
- Go to “Database”
- Select “New database connection”
- Select SQL
- Pick MySQL or MariaDB (if you’re using MySQL)
- Optional: it may prompt you to install the driver if you’re doing it for the first time. Just go through the steps in the wizard and DBeaver will find and install the driver automatically for you.
- Enter connection info: hostname (endpoint from the step above), port (from the step above), user name and password (If you’re the DB admin, you should be able to use your master user credentials you entered when setting up the cluster. If you’re not an admin – your DB admin will/should give the credentials.)
- Hit “Finish” and give it a few seconds to load
Notes:
If you got all the settings right and still have trouble connecting (e.g. getting a connection timeout error), you may want to check if your IP address was added to the security group associated with the database instance you’re trying to access. AWS is using security groups to control access from certain IP ranges and ports, and by default, this access is turned off, so you’ll need to verify if you are allowed to connect from/with the IP and port you’re using.
Useful links:
Amazon docs on creating an Aurora cluster
AWS docs on connecting to Aurora