DIR 請求的 Bacula 裝置「FileStorage」無法開啟或不存在

DIR 請求的 Bacula 裝置「FileStorage」無法開啟或不存在

我正在嘗試設定 bacula 來遠端備份我的機器。

我的配置如下:

Job {
  Name = "LocalBackup"
  JobDefs = "DefaultJob"
}

Job {
  Name = "RemoteBackup"
  JobDefs = "DefaultJob"
  Client = ClientMachine-fd
  Pool = RemoteFile
}

Job {
  Name = "RestoreRemote"
  Type = Restore
  Client=ClientMachine-fd
  FileSet="Full Set"
  Storage = File     
  Pool = Default
  Messages = Standard
  Where = /bacula/restore
}

我的客戶端配置如下所示:

Client {
  Name = ClientMachine-fd
  Address = ClientMachine.DomainName.com
  FDPort = 9102 
  Catalog = MyCatalog
  Password = "u2LK-yBrQzfiEsc6NWftHEhymmdPWsklN"          # password for Remote FileDaemon
  File Retention = 30 days            # 30 days
  Job Retention = 6 months            # six months
  AutoPrune = yes                     # Prune expired Jobs/Files
}

當我運行此配置並首先查找客戶端的狀態時,我收到以下訊息:

ClientMachine-fd Version: 5.2.6 (21 February 2012)  x86_64-pc-linux-gnu ubuntu 14.04
Daemon started 01-Oct-15 13:14. Jobs: run=0 running=0.
 Heap: heap=270,336 smbytes=15,823 max_bytes=15,970 bufs=48 max_bufs=49
 Sizeof: boffset_t=8 size_t=8 debug=0 trace=0 
Running Jobs:
Director connected at: 01-Oct-15 13:53
No Jobs running.
====

Terminated Jobs:
====
*

現在我希望運行我的工作,但收到以下訊息:

    01-Oct 11:54 BackupServer-dir JobId 4: Start Backup JobId 4, Job=RemoteBackup.2015-10-01_11.54.23_05
01-Oct 11:54 BackupServer-sd JobId 4: Error: dev.c:120 Unable to stat device /nonexistant/path/to/file/archive/dir: ERR=No such file or directory
01-Oct 11:54 BackupServer-sd JobId 4: Warning: 
     Device "FileStorage" requested by DIR could not be opened or does not exist.
01-Oct 11:54 BackupServer-sd JobId 4: Error: dev.c:120 Unable to stat device /nonexistant/path/to/file/archive/dir: ERR=No such file or directory
01-Oct 11:54 BackupServer-sd JobId 4: Warning: 
     Device "FileStorage" requested by DIR could not be opened or does not exist.
01-Oct 11:54 BackupServer-sd JobId 4: Error: dev.c:120 Unable to stat device /nonexistant/path/to/file/archive/dir: ERR=No such file or directory
01-Oct 11:54 BackupServer-sd JobId 4: Warning: 
     Device "FileStorage" requested by DIR could not be opened or does not exist.
01-Oct 11:54 BackupServer-sd JobId 4: Fatal error: Device reservation failed for JobId=4: Jmsg Job=RemoteBackup.2015-10-01_11.54.23_05 type=5 level=1443700465 BackupServer-sd JobId 4: Warning: 
     Device "FileStorage" requested by DIR could not be opened or does not exist.

01-Oct 11:54 BackupServer-dir JobId 4: Fatal error: 
     Storage daemon didn't accept Device "FileStorage" because:
     3924 Device "FileStorage" not in SD Device resources.
01-Oct 11:54 BackupServer-dir JobId 4: Error: Bacula BackupServer-dir 5.2.6 (21Feb12):
  Build OS:               i686-pc-linux-gnu ubuntu 14.10
  JobId:                  4
  Job:                    RemoteBackup.2015-10-01_11.54.23_05
  Backup Level:           Full (upgraded from Incremental)
  Client:                 "ClientMachine-fd" 5.2.6 (21Feb12) x86_64-pc-linux-gnu,ubuntu,14.04
  FileSet:                "Full Set" 2015-10-01 11:39:29
  Pool:                   "RemoteFile" (From Job resource)
  Catalog:                "MyCatalog" (From Client resource)
  Storage:                "File" (From Job resource)
  Scheduled time:         01-Oct-2015 11:54:21
  Start time:             01-Oct-2015 11:54:25
  End time:               01-Oct-2015 11:54:25
  Elapsed time:           0 secs
  Priority:               10
  FD Files Written:       0
  SD Files Written:       0
  FD Bytes Written:       0 (0 B)
  SD Bytes Written:       0 (0 B)
  Rate:                   0.0 KB/s
  Software Compression:   None
  VSS:                    no
  Encryption:             no
  Accurate:               no
  Volume name(s):         
  Volume Session Id:      2
  Volume Session Time:    1443699984
  Last Volume Bytes:      0 (0 B)
  Non-fatal FD errors:    1
  SD Errors:              0
  FD termination status:  
  SD termination status:  
  Termination:            *** Backup Error ***

誰能告訴我為什麼會發生這種事?

答案1

關於:

3924 設備“FileStorage”不在 SD 設備資源中。

  • 和中的應該Media Type相同。bacula.sd.confbacula-dir.conf

10 月 1 日 11:54 BackupServer-sd JobId 4:錯誤:dev.c:120 無法統計裝置 /nonexistant/path/to/file/archive/dir:ERR=沒有這樣的檔案或目錄

  • 您可能忘記更改,Archive Device因為/nonexistant/path/to/file/archive/dir這是它附帶的預設值。

答案2

此錯誤訊息表示檔案儲存設備配置不正確。幾年前我用巴庫拉做過很多事,但現在我已經不記得了。但是您需要檢查 baculadirector 守護程序和媒體守護程序的設定檔(bacula-dir.conf、bacula-sd.conf)並編輯「DefaultJob」的作業屬性以獲得可用的設定。

JobDefs = "DefaultJob"

表示bacula嘗試備份到標準檔案儲存設備,而該設備實際上並不存在。還有這個:

Storage daemon didn't accept Device "FileStorage" because:
3924 Device "FileStorage" not in SD Device resources.

檢查儲存守護程序的配置,然後您就可以修復它。無論如何,預設值相當晦澀,只能用作範例,因此您需要更多地撓頭並閱讀文件!

相關內容