Answer the question
In order to leave comments, you need to log in
Is it possible to backup MySQL through SaaS services?
Good afternoon, colleagues.
There is a simple task: to backup a couple of MySQL databases (on ubuntu).
I do not want to raise the second server, use dropbox too. Amazon S3 is lazy to set up.
Are there any paid SaaS formats: installed deb, registered login\password\host\database list - did it work?
Answer the question
In order to leave comments, you need to log in
#!/bin/sh
# ftp.host.ru - ftp server ip
#username:pasword to login to FTP
#mysqldumpuser MyPasword - MySQL login password
# 3 days - (I have cron backup every day). how many days ago to store backups
#Or xtrabackup
curlftpfs -v -o iocharset=UTF-8 ftp://username:[email protected]/ /mnt/
mysqldump -u mysqldumpuser -pMyPasword --opt -c -A > / root/dumpdb.sql
zip -r "/root/dumpdb.sql(`date +%F`)".zip /root/dumpdb.sql
cp "/root/dumpdb.sql(`date +%F`)". zip /mnt/
rm "/mnt/dumpdb.sql(`date --rfc-3339='date' --date "now - 3 days"`).zip"
rm "/root/dumpdb.sql(`date - -rfc-3339='date' --date "now - 3 days"`).
umount curlftpfs# ftp://username:[email protected]/
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question