0

I am about to embark on a project which will require a lot of documentation and since I have a spare Pi, I think it would be really useful to use it to store this documentation in a custom MySQL database. Now of course this is very important information to me and I don't want to lose it so what I want to do is back the database up daily and then upload that to some sort of cloud storage. I prefer OneDrive but Dropbox would do as well.

Does anyone know if this is possible? I don't really want to install any sort of client, all I want a script to do is grab the latest MySQL backup, and upload it to perhaps a shared directory on one of the aforementioned cloud services.

I found the below link which I'll try, so if anyone has used it and can provide feedback, that would be good.

https://github.com/fkalis/bash-onedrive-upload

Any assistance would be greatly appreciated!

  • Let me google that for you lmgtfy.com/?q=raspberry+pi+upload+dropbox+script – rob Feb 26 '15 at 8:08
  • Wow, thanks. I never knew I could use Google to find stuff! Where has this been all my life? Next time, don't comment with stupid crap like that. Down vote me and move the hell along. – Trido Feb 26 '15 at 9:02
1

Yes, this should be possible.

For that purpose I would write a simple shell script which consists of 2 parts:

  1. Create a backup of the database
  2. Upload that database dump to %cloudStorage

Then I would set up a daily cronjob that executes that script.

Now you know that you can use Google to find stuff, you should be able to search for something like mysqldump for part 1, and bash upload dropbox for part 2. I assume there's also a lot of documentation about cronjob out there.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.