自拍偷在线精品自拍偷,亚洲欧美中文日韩v在线观看不卡

GitHub標(biāo)星14K!程序員人手必備的開源備份工具

開發(fā) 開發(fā)工具
備份軟件已經(jīng)是一個老生常談的話題了,今天,猿妹要和大家分享一個備份工具——restic。

[[436814]]

備份軟件已經(jīng)是一個老生常談的話題了,今天,猿妹要和大家分享一個備份工具——restic。

Restic是一種快速、高效、免費和開源的備份應(yīng)用程序,它通過AES-256加密保護你的數(shù)據(jù),Restic 還利用重復(fù)數(shù)據(jù)刪除來幫助節(jié)省備份空間。此外,Restic 與大多數(shù)主要的云提供商兼容,支持三大操作系統(tǒng)(Linux、macOS、Windows)和一些較小的操作系統(tǒng)(FreeBSD、OpenBSD)。

 

目前,Restic已經(jīng)在Github上標(biāo)星 14.6K,累計分支 999 個(Github地址:https://github.com/restic/restic)

首先,你可以從源代碼編譯restic或從發(fā)布頁面下載它。一旦安裝好restic,就可以開始備份:

  1. $ restic init --repo /tmp/backup 
  2. enter password for new backend: 
  3. enter password again: 
  4. created restic backend 085b3c76b9 at /tmp/backup 
  5. Please note that knowledge of your password is required to access the repository. 
  6. Losing your password means that your data is irrecoverably lost. 

并添加一些數(shù)據(jù):

  1. $ restic --repo /tmp/backup backup ~/work 
  2. enter password for repository: 
  3. scan [/home/user/work] 
  4. scanned 764 directories, 1816 files in 0:00 
  5. [0:29] 100.00%  54.732 MiB/s  1.582 GiB / 1.582 GiB  2580 / 2580 items  0 errors  ETA 0:00 
  6. duration: 0:29, 54.47MiB/s 
  7. snapshot 40dc1520 saved 

接下來,你可以restic restore用于恢復(fù)文件,要獲取所有備份快照的列表,可以使用以下的命令:

  1. restic -r b2:bucketname:/ snapshots 

例如:

  1. $ restic -r b2:g534fbucket:/ snapshots 
  2. enter password for repository:  
  3. ID Date Host Tags Directory 
  4. ---------------------------------------------------------------------- 
  5. d864c465 2018-03-27 15:20:42 client /home/curt/Documents 

如果你要恢復(fù)整個快照,就運行以下命令:

  1. restic -r b2:bucketname:/ restore snapshotID --target restoreDirectory 

例如:

  1. $ restic -r b2:g534fbucket:/ restore d864c465 --target ~ 
  2. enter password for repository:  
  3. restoring <Snapshot d864c465 of [/home/curt/Documents] at 2018-03-27 15:20:42.833131988 -0400 EDT by curt@client> to /home/curt 

如果該目錄仍然存在于你的系統(tǒng)上,請確保為restoreDirectory指定不同的位置。例如:

  1. restic -r b2:g534fbucket:/ restore d864c465 --target /tmp 

要恢復(fù)單個文件,請運行如下命令:

  1. $ restic -r b2:g534fbucket:/restore snapshotID --target restoreDirectory --include filename 

例如:

  1. $ restic -r b2:g534fbucket:/ restore d864c465 --target /tmp --include file1.txt 
  2. enter password for repository:  
  3. restoring <Snapshot d864c465 of [/home/curt/Documents] at 2018-03-27 15:20:42.833131988 -0400 EDT by curt@client> to /tmp 

 

責(zé)任編輯:趙寧寧 來源: 開源最前線
相關(guān)推薦

2021-04-26 14:44:44

程序員技能開發(fā)者

2020-12-30 10:35:49

程序員技能開發(fā)者

2021-04-09 16:25:00

GitHub代碼開發(fā)者

2022-10-24 09:00:47

畫圖工具程序員XMind

2021-03-02 09:34:15

GitHub倉庫代碼

2020-06-16 11:09:13

程序員技能開發(fā)者

2020-01-13 13:00:59

程序員技能開發(fā)者

2019-05-16 09:13:31

Github定理開發(fā)

2020-12-08 10:23:42

程序員PPT開發(fā)

2022-03-25 22:57:37

系統(tǒng)設(shè)計架構(gòu)

2019-12-24 11:13:02

GitHub代碼開發(fā)者

2019-08-09 18:08:13

程序員技能開發(fā)者

2019-04-23 13:51:43

程序員技能開發(fā)者

2020-10-13 17:10:24

GithubRedis數(shù)據(jù)庫

2020-11-10 10:46:57

開源后臺管理系統(tǒng)Base Admin

2018-06-12 10:15:56

2019-07-05 10:45:27

Java程序員編程語言

2019-08-22 11:09:26

程序員技能開發(fā)者

2017-11-28 09:10:10

程序員工具Github

2021-02-01 07:02:19

GitHub 倉庫程序員
點贊
收藏

51CTO技術(shù)棧公眾號