Google Cloud SQL - Backup prod and restore on dev instance
To test your code in cloud sql you need a realistic data load. The best way to get this is the backup and restore your production database. Note that you need to make sure you anonymize the data sufficiently immediately after the restore to protect your customers identities. Go to google api console. https://code.google.com/apis/console/ you need to be logged in to your google account for this. Find the name of the storage bucket in cloud storage or create a new one. Go back into Cloud sql console and export data. Give the name of the file as date-prod: june-17-2013-prod Back up will take a while. Once it is completed download the file to your local machine. Decompress it, its in gzip format. This outputs both the mysql db and the required prod db. Use the following shell commands (bash) to get rid of the mysql stuff: grep -in ‘create database’ your_file_name The output gives you the line numbers of the creates (that's what the n is for, the i ig...