Bacula 复制作业找不到设备

Bacula 复制作业找不到设备

我在现场有一台 bacula 服务器,它定期备份我的所有服务器。现在我正尝试创建复制作业,将所有完整备份复制到异地。但我仍然收到错误:

设备“FileStorage”不在 SD 设备资源中。

这很奇怪,因为现场存储设备称为:FileStorage,而异地存储设备称为:OffsiteFileStorage。(如果我重命名异地设备,作业就会挂起)如果我尝试定期备份到异地存储,一切正常。

配置文件:

bacula-storage.conf (现场)

Storage {
  Name = Offsite
    Address = offsite.example.com
    SDPort = 9103
    Password = "password"
    Device = "OffsiteFileStorage"
    Media Type = File
    }


Storage {
  Name = File
    Address = bacula.example.com
    SDPort = 9103
    Password = "password"
    Device = FileStorage
    Media Type = File
    }

Pool {
  Name = Server-Full-Pool
  Pool Type = Backup
  Storage = File
  Recycle = yes
  AutoPrune = yes
  Volume Retention = 6 months
  Maximum Volumes = 40 # Limit number of Volumes in Pool
  Maximum Volume Bytes = 10G
  LabelFormat = "Server-Full"
  RecyclePool = Scratch
  Next Pool = Offsite-Pool
  Cleaning Prefix = "CLN"
  }

Pool {
    Name = Offsite-Pool
    Pool Type = Backup
    Storage = Offsite
    Volume Use Duration = 1 day
    Volume Retention = 6 months
    Scratch Pool = Offsite-Scratch
    RecyclePool = Offsite-Scratch
    File Retention =  1 year
    Job Retention =  1 year
    LabelFormat = "Copy-full"
    Cleaning Prefix = "CLN"
    }

Job {
    Name = "OffsiteCopyFull"
    Type = Copy
    Pool = Server-Full-Pool
    Schedule = "WeeklyOffsiteCopy"
    Client = None
    FileSet = None
    Selection Type = PoolUncopiedJobs
    Maximum Concurrent Jobs = 1
    Storage = Offsite
    Messages = Standard
    Priority = 10
    Write Bootstrap = "/var/spool/bacula/offsite-copy-%c.bsr"
    }

Schedule {
  Name = "WeeklyOffsiteCopy"
  Run = Full tue at 11:02
}

Client {
  Name = None
  Address = localhost
  Catalog = MyCatalog
  Password = "NoNe"          # password for FileDaemon
}

FileSet {
  Name = None
  Include {
      Options {
         signature = MD5
      }
  }
}

bacula-sd.conf (现场)

Storage {                             # definition of myself
  Name = bacula-sd
  SDPort = 9103                  # Director's port
  WorkingDirectory = "/var/spool/bacula"
  Pid Directory = "/var/run"
  Maximum Concurrent Jobs = 20
  Heartbeat Interval = 1 Minute            # Prevents timeouts
}

Director {
  Name = bacula-dir
  Password = "password"
}

Device {
  Name = FileStorage
  Media Type = File
  Archive Device = /storage/raid5/BACKUP/
  LabelMedia = yes;                   # lets Bacula label unlabeled media
  Random Access = Yes;
  AutomaticMount = yes;               # when device opened, read it
  RemovableMedia = no;
  AlwaysOpen = no;
}

bacula-sd.conf (异地)

Storage {                             # definition of myself                                                                                                                                                       
  Name = bacula-sd                                                                                                                                                                                                 
  SDPort = 9103                  # Director's port                                                                                                                                                                 
  WorkingDirectory = "/var/spool/bacula"                                                                                                                                                                           
  Pid Directory = "/var/run"                                                                                                                                                                                       
  Maximum Concurrent Jobs = 20                                                                                                                                                                                     
  Heartbeat Interval = 1 Minute            # Prevents timeouts                                                                                                                                                     
}                                                                                                                                                                                                                  

Director {                                                                                                                                                                                                         
  Name = bacula-dir                                                                                                                                                                                                
  Password = "password"                                                                                                                                                                                     
}                                                                                                                                                                                                                  


                                                                                                                                                                                                                 Device {                                                                                                                                                                                                           
  Name = OffsiteFileStorage                                                                                                                                                                                        
  Media Type = File                                                                                                                                                                                                
  Archive Device = /Backup/Offsite/                                                                                                                                                                                
  LabelMedia = yes;                   # lets Bacula label unlabeled media                                                                                                                                          
  Random Access = yes;                                                                                                                                                                                             
  AutomaticMount = yes;               # when device opened, read it                                                                                                                                                
  RemovableMedia = no;                                                                                                                                                                                             
  AlwaysOpen = no;                                                                                                                                                                                                 
}   

答案1

据我所知,在存储守护进程之间复制作业仍然是不可能的。

目前是的。目前,迁移和复制作业都限制为使用单个 SD 作为源和目标,因为 Bacula 中目前没有协议可以让一个 SD 直接与另一个 SD 通信。(请参阅此处的第二个答案:http://bacula.10910.n7.nabble.com/Migration-Copy-jobs-from-Storage-daemon-to-another-td66239.html

我想到唯一的解决方案是使用一些较低级别的协议(例如 nfs)安装异地位置,并从源服务器上的同一个存储守护进程中使用它。

相关内容