你好,游客 登录 注册 搜索
背景:
阅读新闻

实战演示Bacula完全恢复与不完全恢复功能

[日期:2012-05-31] 来源:Linux社区  作者:ixdba [字体:大 中 小]

2、通过增量备份进行完全恢复

执行下面操作前需要先删除FD端的备份目录。
 

  1. *status  
  2. Status available for:  
  3.      1: Director  
  4.      2: Storage  
  5.      3: Client  
  6.      4: All  
  7. Select daemon type for status (1-4): 1  
  8. f10-64-build-dir Version: 3.0.2 (18 July 2009) x86_64-unknown-linux-gnu RedHat   
  9. Daemon started 21-Aug-09 15:01, 2 Jobs run since started.  
  10.  Heap: heap=253,952 smbytes=100,693 max_bytes=223,457 bufs=280 max_bufs=312 
  11.  
  12. Scheduled Jobs:  
  13. Level          Type     Pri  Scheduled          Name               Volume 
  14. =======================================================================  
  15. Incremental    Backup    10  21-Aug-09 23:05    Client1            cicro4  
  16. Incremental    Backup    10  21-Aug-09 23:05    Client             cicro4  
  17. Incremental    Backup    10  21-Aug-09 23:05    BackupCatalog      cicro4  
  18.  
  19. Running Jobs:  
  20. Console connected at 21-Aug-09 16:32  
  21. Console connected at 21-Aug-09 16:50  
  22. No Jobs running.  
  23.  
  24. Terminated Jobs:  
  25.  JobId  Level    Files      Bytes   Status   Finished        Name   
  26. ====================================================================  
  27.     65                1         0   OK       19-Aug-09 16:58 RestoreFiles  
  28.     66                2    38.77 K  OK       19-Aug-09 16:59 RestoreFiles  
  29.     67  Full         25    145.5 M  OK       21-Aug-09 13:41 Client1  
  30.     68  Incr          2    3.908 M  OK       21-Aug-09 14:20 Client1  
  31.     69  Full         26    149.4 M  OK       21-Aug-09 14:32 Client  
  32.     70  Diff          2    3.908 M  OK       21-Aug-09 14:34 Client  
  33.     71  Diff          3    7.817 M  OK       21-Aug-09 14:35 Client  
  34.     72  Diff          4    11.72 M  OK       21-Aug-09 14:35 Client  
  35.     73  Incr          4    11.72 M  OK       21-Aug-09 15:34 Client1  
  36.     74               29    4.092 G  OK       21-Aug-09 16:35 RestoreFiles  
  37. *restore  
  38. Automatically selected Catalog: MyCatalog  
  39. Using Catalog "MyCatalog"  
  40.  
  41. First you select one or more JobIds that contain files  
  42. to be restored. You will be presented several methods  
  43. of specifying the JobIds. Then you will be allowed to  
  44. select which files from those JobIds are to be restored.  
  45.  
  46. To select the JobIds, you have the following choices:  
  47.      1: List last 20 Jobs run  
  48.      2: List Jobs where a given File is saved  
  49.      3: Enter list of comma separated JobIds to select  
  50.      4: Enter SQL list command  
  51.      5: Select the most recent backup for a client  
  52.      6: Select backup for a client before a specified time  
  53.      7: Enter a list of files to restore  
  54.      8: Enter a list of files to restore before a specified time  
  55.      9: Find the JobIds of the most recent backup for a client  
  56.     10: Find the JobIds for a backup for a client before a specified time  
  57.     11: Enter a list of directories to restore for found JobIds  
  58.     12: Select full restore to a specified JobId  
  59.     13: Cancel  
  60. Select item:  (1-13): 3  
  61. Enter JobId(s), comma separated, to restore: 67,68,73  
  62. You have selected the following JobIds: 67,68,73  
  63. #在这里,JobId为67的备份是一个完全备份,而JobId为68地备份为第一个增量  
  64. #备份,JobId为73的备份为第二个增量备份,如果还有其他增量备份,都要在  
  65. #这里指定,才能完全恢复  
  66. Building directory tree for JobId(s) 67,68,73 ...    
  67. 26 files inserted into the tree.  
  68.  
  69. You are now entering file selection mode where you add (mark) and  
  70. remove (unmark) files to be restored. No files are initially added, unless  
  71. you used the "all" keyword on the command line.  
  72. Enter "done" to leave this mode.  
  73. cwd is: /  
  74. $ mark cicro   #标记恢复  
  75. 29 files marked.  
  76. $ done       #确认操作  
  77. Bootstrap records written to /opt/bacula/var/bacula/working/f10-64-build-dir.restore.2.bsr  
  78. The job will require the following  
  79.    Volume(s)                 Storage(s)                SD Device(s)  
  80. =======================================================================  
  81.     cicro4                    dbsd                      dbdev                      
  82.  
  83. Volumes marked with "*" are online.  
  84. 29 files selected to be restored.  
  85.  
  86. Defined Clients:  
  87.      1: dbfd  
  88.      2: dbfd1  
  89. Select the Client (1-2): 1  
  90. Run Restore job  
  91. JobName:         RestoreFiles  
  92. Bootstrap:       /opt/bacula/var/bacula/working/f10-64-build-dir.restore.2.bsr  
  93. Where:           /tmp/bacula-restores  
  94. Replace:         always  
  95. FileSet:         dbfs  
  96. Backup Client:   dbfd  
  97. Restore Client:  dbfd  
  98. Storage:         dbsd  
  99. When:            2009-08-21 16:52:04  
  100. Catalog:         MyCatalog  
  101. Priority:        10  
  102. Plugin Options:  *None*  
  103. OK to run? (yes/mod/no): mod  
  104. Parameters to modify:  
  105.      1: Level  
  106.      2: Storage  
  107.      3: Job  
  108.      4: FileSet  
  109.      5: Restore Client  
  110.      6: When  
  111.      7: Priority  
  112.      8: Bootstrap  
  113.      9: Where  
  114.     10: File Relocation  
  115.     11: Replace  
  116.     12: JobId  
  117.     13: Plugin Options  
  118. Select parameter to modify (1-13): 9  
  119. Please enter path prefix for restore (/ for none): /  
  120. Run Restore job  
  121. JobName:         RestoreFiles  
  122. Bootstrap:       /opt/bacula/var/bacula/working/f10-64-build-dir.restore.2.bsr  
  123. Where:             
  124. Replace:         always  
  125. FileSet:         dbfs  
  126. Backup Client:   dbfd  
  127. Restore Client:  dbfd  
  128. Storage:         dbsd  
  129. When:            2009-08-21 16:52:04  
  130. Catalog:         MyCatalog  
  131. Priority:        10  
  132. Plugin Options:  *None*  
  133. OK to run? (yes/mod/no): yes  
  134. Job queued. JobId=75 
  135.  

至此,增量备份的完全恢复也完成了,由此可以看出增量备份的恢复与差异备份恢复之间的差异。

linux
相关资讯       Bacula  Bacula配置 
本文评论   查看全部评论 (0)
表情: 表情 姓名: 字数

       

评论声明
  • 尊重网上道德,遵守中华人民共和国的各项有关法律法规
  • 承担一切因您的行为而直接或间接导致的民事或刑事法律责任
  • 本站管理人员有权保留或删除其管辖留言中的任意内容
  • 本站有权在网站内转载或引用您的评论
  • 参与本评论即表明您已经阅读并接受上述条款