bareos: master 1542a628

Author Committer Branch Timestamp Parent
Sebastian Sura Bareos Bot master 2025-01-31 12:56 master f49e255d Pending
Changeset stored: remove code paths that ignore reservation

All jobs reserve a viable volume to use when they reserve a device.
Sadly some code paths ignored this and instead just used the currently
mounted device for writing regardless of whether it was reserved by
somebody else or not.

This caused weird `Volume X wanted by Device Y is in use by device Z`
error messages as device Y actually reserved volume X, but device Z
simply decided to use it as it was currently mounted, which ultimately
cause an operator message to be sent out.

As volumes that are currently mounted in the device are preferred for
reservation anyways, we simply remove the `IsSuitableVolumeMounted()`
code paths.

If this becomes a problem in the future we can simply try to reserve
the currently mounted volume and use it if it worked.
mod - core/src/stored/acquire.cc Diff File
mod - core/src/stored/device_control_record.h Diff File
mod - core/src/stored/mount.cc Diff File