kagasu / DBAutoBackup

Backup your MySQL(MariaDB) to Google Drive automatically

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

DBAutoBackup

Backup your MySQL(MariaDB) to Google Drive automatically

Requirements

Set up

  1. Initialize gdrive
$ gdrive
Go to the following link in your browser: https://accounts.google.com/o/oauth2/auth?client_id=...

Enter verification code:
  1. Edit config.json
$ vim config.json
  1. Change permission
$ chmod 777 /path/to/DBAutoBackup -R
  1. Add cron
$ crontab -e

# DBAutoBackup(Everyday PM 16:00)
0 16 * * * /path/to/DBAutoBackup/start.sh 1> /dev/null 2> /dev/null

How to decrypt

$ openssl aes-256-cbc -d -in my_db.gz.enc -out my_db.gz -pass pass:09c9ea1ca79842da94df882d20887bb6

FAQ

  • what is "period" ?
    old backup file delete period.
    default is 14 days.

About

Backup your MySQL(MariaDB) to Google Drive automatically


Languages

Language:Python 98.1%Language:Shell 1.9%