Skip to content

systemtests: autochanger add testrunner-restore-non-present-volume#2476

Merged
BareosBot merged 18 commits intobareos:masterfrom
bruno-at-bareos:restore-from-volume-not-present
Jan 20, 2026
Merged

systemtests: autochanger add testrunner-restore-non-present-volume#2476
BareosBot merged 18 commits intobareos:masterfrom
bruno-at-bareos:restore-from-volume-not-present

Conversation

@bruno-at-bareos
Copy link
Contributor

@bruno-at-bareos bruno-at-bareos commented Dec 8, 2025

This PR aims to introduce a new systemtests for autochanger.
We want to test a restore with a non present volume (like exported tapes).

We review and improve also the existing testrunner:

  • systemtests: autochanger improve invalidate_tape.sh by supporting mt cpio
  • systemtests: autochanger separate log_home and tmp usage
  • autochanger: export release_all_devices in functions.local
  • systemtests: autochanger add testrunner-restore-non-present-volume
  • allow several concurrent restores

Please check

  • Short description and the purpose of this PR is present above this paragraph
  • Your name is present in the AUTHORS file (optional)

If you have any questions or problems, please give a comment in the PR.

Helpful documentation and best practices

Checklist for the reviewer of the PR (will be processed by the Bareos team)

Make sure you check/merge the PR using devtools/pr-tool to have some simple automated checks run and a proper changelog record added.

General
  • Is the PR title usable as CHANGELOG entry?
  • Purpose of the PR is understood
  • Commit descriptions are understandable and well formatted
  • Required backport PRs have been created
  • Correct milestone is set
Tests
  • Decision taken that a test is required (if not, then remove this paragraph)
  • The choice of the type of test (unit test or systemtest) is reasonable
  • Testname matches exactly what is being tested
  • On a fail, output of the test leads quickly to the origin of the fault

@bruno-at-bareos bruno-at-bareos added this to the 26.0.0 milestone Dec 8, 2025
@bruno-at-bareos bruno-at-bareos self-assigned this Dec 8, 2025
Copy link
Contributor

@sebsura sebsura left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I didnt review everything, i just looked at some parts.

@bruno-at-bareos bruno-at-bareos force-pushed the restore-from-volume-not-present branch from f3dfe1a to a5db6db Compare January 5, 2026 09:34
@bruno-at-bareos
Copy link
Contributor Author

@sebsura it look like I addressed all of yours remarks.
Please could you check it (especially locally) if everything build and tests works as expected.

@bruno-at-bareos bruno-at-bareos force-pushed the restore-from-volume-not-present branch from cc9ce50 to f085d95 Compare January 12, 2026 11:00
Copy link
Contributor

@sebsura sebsura left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the great work!

bruno-at-bareos and others added 14 commits January 15, 2026 09:49
- set Testname so the variable exist
- add mt cpio detection: mt cpio doesn't work with status on no tape
  loaded.
- add license
- use log_home for logging action
- tmp is used for bconsole action
- follow shellcheck recommendation
- add release all drives
- use redirection and simplify extraction limiting subshell with awk

Signed-off-by: Bruno Friedmann <bruno.friedmann@bareos.com>
- autochanger test: add test restore with non present media to track
  warnings and reading issue after mount request
- describe completely what we expect to find and what's not.
- make restore concurrent possible by changing the Maximum Concurrent
  Jobs in RestoreFiles.conf.in
- update copyright year

Signed-off-by: Bruno Friedmann <bruno.friedmann@bareos.com>
- simplify loop by using one line of echo
- update copyright year
Co-authored-by: Sebastian Sura <124262655+sebsura@users.noreply.github.com>
- restores happen in tmp
- list_of_jobis stay in tmp as shared between tests
Signed-off-by: Bruno Friedmann <bruno.friedmann@bareos.com>
use correct command for restore jobid without select all,
this make the restore more reliable in terms of expected results.

Signed-off-by: Bruno Friedmann <bruno.friedmann@bareos.com>
@bruno-at-bareos bruno-at-bareos force-pushed the restore-from-volume-not-present branch from f085d95 to c4adcb5 Compare January 15, 2026 08:51
Signed-off-by: Bruno Friedmann <bruno.friedmann@bareos.com>
Signed-off-by: Bruno Friedmann <bruno.friedmann@bareos.com>
@bruno-at-bareos bruno-at-bareos force-pushed the restore-from-volume-not-present branch from a2fa9c3 to b36952b Compare January 20, 2026 14:14
@BareosBot BareosBot merged commit c66516a into bareos:master Jan 20, 2026
1 check was pending
@bruno-at-bareos bruno-at-bareos deleted the restore-from-volume-not-present branch March 4, 2026 10:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug This addresses a bug requires backport to 25

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants