Hi, I uploaded a large (+1.5GB) gzipped SQL file to my dropplet and would like to add it to my MySQL DB hosted on a managed database. Since there is no SSH on managed DB how should I uncompress and install my SQL file?
Thanks!
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
Hi @cmurph, is this a backup/data import that you would like to ingest into the instance?
Hi @cmurph,
You can add droplet ID to MySQL managed database trusted source so that you will be able to access the managed database from the droplet where you have placed (+1.5GB) gzipped SQL file (backup file); Then you can run the below command to import data (make changes to command with your database cluster hostname, password, database name, and SQL file name).
gunzip < backupfile.sql.gz| mysql -u doadmin -p'password' -h db-mysql-xxxx-xxxxx-do-user-xxxxxxx-0.b.db.ondigitalocean.com -P 25060 -D databasename
For more information on importing data to MySQL managed database check the below link : https://docs.digitalocean.com/products/databases/mysql/how-to/import-databases/
I hope this helps!
Regards, Rajkishore
Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.
Full documentation for every DigitalOcean product.
The Wave has everything you need to know about building a business, from raising funding to marketing your product.
Stay up to date by signing up for DigitalOcean’s Infrastructure as a Newsletter.
New accounts only. By submitting your email you agree to our Privacy Policy
Scale up as you grow — whether you're running one virtual machine or ten thousand.
Sign up and get $200 in credit for your first 60 days with DigitalOcean.*
*This promotional offer applies to new accounts only.