Auto backup mongodb & sync backup with Google Drive

Thanh Phong
Sep 6, 2018 · 1 min read


Install Google Drive

sudo add-apt-repository ppa:nilarimogard/webupd8
sudo apt-get update
sudo apt-get install grive

Auto update crontab:
sudo nano /etc/crontab

# Run every midnight
0 0 * * * root cd /var/www/html/db_backup && bash backup.sh

Welcome to a place where words matter. On Medium, smart voices and original ideas take center stage - with no ads in sight. Watch
Follow all the topics you care about, and we’ll deliver the best stories for you to your homepage and inbox. Explore
Get unlimited access to the best stories on Medium — and support writers while you’re at it. Just $5/month. Upgrade