Example Storage Daemon Configuration File

An example Storage Daemon configuration file might be the following:

#
# Default Bacula Storage Daemon Configuration File
#
# For Bacula release 16.0.5 (05 April 2023) -- redhat (Blue
#
# You may need to change the name of your storage
# target in the Archive Device directive in the Device
# resources. If you change the Name and/or the Media
# Type in the Device resources, please ensure that
# bacula-dir.conf has the corresponding changes.
#
#
# Copyright (C) 2000-2020 Kern Sibbald
# License: BSD 2-Clause; see file LICENSE-FOSS
# -----------------------------------------------------

# This is a Storage Daemon definition. Here you can
# set the port that this Storage Daemon will listen on
# and this needs to match the port defined in the
# Storage and Autochanger resources in the Director
# configuration file.
# -----------------------------------------------------
Storage {
  Name = bacula-sd
  SDPort = 9103
  WorkingDirectory = "/opt/bacula/working"
  PIDDirectory = "/opt/bacula/working"
  PluginDirectory = "/opt/bacula/plugins"
  MaximumConcurrentJobs = 20
}

# This is a Director resource. It defines a Director
# allowed to communicate with this Storage Daemon. The
# Password value specified in this Director resource
# must be the same value specified in the Password
# directive defined in the corresponding Storage or
# Autochanger resource in the Director configuration.
# -----------------------------------------------------
Director {
  Name = bacula-dir
  Password = "ZPUBve6cCwPVDpHqpqyAHPaPal30S/6LgSkpOzLrvLKU"
}

# This is an Autochanger resource. For Disk
# Autochangers, both Changer Command and Changer Device
# values must be blank and /dev/null respectively. For
# a Tape Autochanger or Tape Library definition, the
# mtx-changer script must be used.
# -----------------------------------------------------
Autochanger {
  Name = DiskAutochanger
  Device = DiskAutochanger_Dev0, DiskAutochanger_Dev1, DiskAutochanger_Dev2
  ChangerCommand = ""
  ChangerDevice = /dev/null
}

# The following three resources are Device resources.
# Each may be a single device or a member of an
# Autochanger resource. These devices are all members
# of the "DiskAutochanger" Autochanger resource defined
# above. The volumes managed by this device will be
# located in the /opt/bacula/archive directory. Please note
# that for disk and tape autochangers the DriveIndex
# directives must be used.
# -----------------------------------------------------
Device {
  Name = DiskAutochanger_Dev0
  DriveIndex = 0
  DeviceType = File
  MediaType = DiskVolume
  ArchiveDevice = "/opt/bacula/archive"
  LabelMedia = Yes
  RandomAccess = Yes
  AutomaticMount = Yes
  RemovableMedia = No
  AlwaysOpen = No
  MaximumConcurrentJobs = 5
}

Device {
  Name = DiskAutochanger_Dev1
  DriveIndex = 1
  DeviceType = File
  MediaType = DiskVolume
  ArchiveDevice = "/opt/bacula/archive"
  LabelMedia = Yes
  RandomAccess = Yes
  AutomaticMount = Yes
  RemovableMedia = No
  AlwaysOpen = No
  MaximumConcurrentJobs = 5
}

Device {
  Name = DiskAutochanger_Dev2
  DriveIndex = 2
  DeviceType = File
  MediaType = DiskVolume
  ArchiveDevice = "/opt/bacula/archive"
  LabelMedia = Yes
  RandomAccess = Yes
  AutomaticMount = Yes
  RemovableMedia = No
  AlwaysOpen = No
  MaximumConcurrentJobs = 5
  Autoselect = No
}

# This is a single, stand alone Device resource. It is
# used by the Catalog Backup job and will help keep
# Catalog backups separated from all other backup data
# (different MediaType).
# -----------------------------------------------------
Device {
  Name = DiskCatalogDevice
  DeviceType = File
  MediaType = CatalogVolume
  ArchiveDevice = "/opt/bacula/archive"
  LabelMedia = Yes
  RandomAccess = Yes
  AutomaticMount = Yes
  RemovableMedia = No
  AlwaysOpen = No
  MaximumConcurrentJobs = 1
}

# This is a Messages resource. All the messages
# generated by this Storage Daemon will be sent to the
# Director specified in this Messages resource.
# -----------------------------------------------------
Messages {
  Name = Default
  Director = bacula-dir = all
  Append = "/opt/bacula/log/bacula-sd.log" = All, !Skipped
}

Go back to the Technical Reference for Storage Daemon.

Go back to the Technical Reference for Storage Daemon.