VPS Data Backup is an important work before in article: using Seven cow cloud storage automatic backup VPS data sharing using the tools provided by the seven Cow cloud storage Qrsbox to back up the data, this article describes the next seven cows another tool Qrsync,qrsync support breakpoint upload, incremental sync, It can sync files from a user's local directory to a seven-cow cloud, synchronizing or uploading hundreds of GB or even terabytes of files without a pear.
First, software download
code is as follows |
copy code |
mkdir qrsync ### Create qrsync directory CD qrsync ### into the Qrsync directory wget http://devtools.qiniu.com/qiniu-devtools-linux_ amd64-current.tar.gz ### Download Qrsync 64-bit wget http://devtools.qiniu.com/qiniu-devtools-linux_386 -current.tar.gz ### This is 32-bit, please download the TAR-ZXVF based on your system selection Qiniu-devtools-linux_ amd64-current.tar.gz ### decompression software |
Second, create a configuration file
Qrsync read a section of JSON data as a configuration file, and if you've developed it, it's not difficult to understand the following JSON configuration file:
VI Config.json ### Create configuration file
Copy the following to the Config.json file, where you can change the parameters yourself, as described below.
The code is as follows |
Copy Code |
{ "src": "/home/your/sync_dir", "Dest": "Qiniu:access_key=<accesskey>&secret_key=<secretkey>&bucket=<bucket>& ..." , "Debug_level": 1 } |
SRC: Local source directory path, such as the above configuration file/home/your/sync_dir is the directory that needs to be uploaded.
AccessKey and Secretkey: When you sign up for seven Neu Yun storage accounts, you have a unique AccessKey and secretkey that can be viewed in the personal panel-> Key Management.
Debug_level: If the debug_level is set to 1, get the necessary log, set 0 can get detailed log.
Here is the small Z blog a section of the JSON configuration file, the effect is to/home/test the contents of this folder all uploaded to seven cow space: XZBK
The code is as follows |
Copy Code |
{ "src": "/home/test", "Dest": "QINIU:ACCESS_KEY=<ACCESSKEY>&SECRET_KEY=<SECRETKEY>&BUCKET=XZBK", "Debug_level": 1 } |
Third, start uploading
The code is as follows |
Copy Code |
Touch/home/test/abc.txt ### Create a abc.txt test file ./qrsync Config.json ### run Qrsync, upload files |
Upload success will see sync done! prompts, and then we log into the seven Neu Yun storage backstage, find XZBK this space, see Abc.txt file has been successfully uploaded.
Iv. Summary
has successfully completed seven cattle real-name certification users have free 10G space and 10G traffic, participate in seven Neu Yun storage Green Business plan can also receive a free 1000 yuan voucher. Using the Qrsync tool backup VPS Data is a very good choice, and seven Neu Yun storage upload and download speed are very satisfied, we may wish to try.