使用Dropbox备份网站附件和数据库


Notice: Undefined index: HTTP_USER_AGENT in /var/www/html/cuijunwei/wp-content/plugins/crayon-syntax-highlighter/util/crayon_util.class.php on line 793

Notice: Undefined index: HTTP_USER_AGENT in /var/www/html/cuijunwei/wp-content/plugins/crayon-syntax-highlighter/util/crayon_util.class.php on line 793

Notice: Undefined index: HTTP_USER_AGENT in /var/www/html/cuijunwei/wp-content/plugins/crayon-syntax-highlighter/util/crayon_util.class.php on line 793

Notice: Undefined index: HTTP_USER_AGENT in /var/www/html/cuijunwei/wp-content/plugins/crayon-syntax-highlighter/util/crayon_util.class.php on line 793

Notice: Undefined index: HTTP_USER_AGENT in /var/www/html/cuijunwei/wp-content/plugins/crayon-syntax-highlighter/util/crayon_util.class.php on line 793

Notice: Undefined index: HTTP_USER_AGENT in /var/www/html/cuijunwei/wp-content/plugins/crayon-syntax-highlighter/util/crayon_util.class.php on line 793

Notice: Undefined index: HTTP_USER_AGENT in /var/www/html/cuijunwei/wp-content/plugins/crayon-syntax-highlighter/util/crayon_util.class.php on line 793

Notice: Undefined index: HTTP_USER_AGENT in /var/www/html/cuijunwei/wp-content/plugins/crayon-syntax-highlighter/util/crayon_util.class.php on line 793

Notice: Undefined index: HTTP_USER_AGENT in /var/www/html/cuijunwei/wp-content/plugins/crayon-syntax-highlighter/util/crayon_util.class.php on line 793

Notice: Undefined index: HTTP_USER_AGENT in /var/www/html/cuijunwei/wp-content/plugins/crayon-syntax-highlighter/util/crayon_util.class.php on line 793

Notice: Undefined index: HTTP_USER_AGENT in /var/www/html/cuijunwei/wp-content/plugins/crayon-syntax-highlighter/util/crayon_util.class.php on line 793

Notice: Undefined index: HTTP_USER_AGENT in /var/www/html/cuijunwei/wp-content/plugins/crayon-syntax-highlighter/util/crayon_util.class.php on line 793

1.登录Dropbox后,打开Apps页面,点击 Create App 按钮,创建一个App

2.登录vps获取最新的上传dropbox脚本

3.配置

4.然后根据提示输入Access token:

然后输入下面命令测试,显示

就没问题了

想重新配置可以把

目录下的隐藏的

文件删除再配置。

5.然后我们创建自己的备份脚本

输入下面内容

然后改为可执行文件:

运行的时候就输入下面的代码即可:

然后通过 cron 来设置定时运行脚本:

加入以下代码,:wq 保存

由于vps和dropbox都在国外,亲测备份特别快,国内的话可以考虑用七牛云。
关于那备份脚本的更多用法参考项目github主页。

全文转载自:https://blog.fazero.me/2016/09/10/backup-vps-to-dropbox/

发表评论

电子邮件地址不会被公开。 必填项已用*标注