Mysqldump from AWS RDS database

October 04, 2012

It's really no different than any other normal dump. I suggest running it from your EC2 instance or another remote server, to skip out any latency found in your local connection (unless you have a decent connection unlike the most of us in the UK).

In which case SSH into either the EC2 instance or another remote server which has been granted access to the AWS RDS instance using either the EC2 Security Group or a CIDR/IP address or range.

You'll obviously need to make sure mysqldump is installed on your remote server (should be in most cases).

Once you've satisfied the above, simply run the following:

mysqldump -u username -p --host hostname_of_rds_endpoint your_database_table_name | gzip > my_rds_save_file.sql.gze

About me

Hello! I'm David Heward, how are you going? I'm a Senior Devops/Build Engineer, specialising in AWS & Cloud Automation. Based in London. Strong 10+ year background in Software development. Have a read of my blog. Have a look at some of my working projects. Contact me at @davehewy or on Linkedin.