On 08/09/2018 01:00 PM, Steven Hammond wrote:
> We are looking at implementing a tape check procedure.  Essentially, once a
> quarter we will routinely verify that various tapes are still readable and we
> can actually restore files from them (as a test). Our volumes are YEARLY,
> MONTHLY, WEEKLY, and DAILY.  I was wondering if there might be a way to store
> in the database with the volume somewhere a date, for example, of when we last
> tested the tape. Yes, I could just create a spreadsheet and keep track, but I
> didn't know if there was already a feature in Bacula (we are using version
> 9.06).  Any suggestions would be greatly appreciated.
> Steven Hammond
> Technical Chemical Company
> Cleburne, TX

Hello Steve,

OK, this script is finished and attached as promised.

In addition to adding a comment to all the volumes that were read in a
specified restore job (or appending a volume comment if one already exists),
this script will do the same for the restore job itself so an admin can also
quickly know which Restore jobs have had their volumes commented, and which
have not.

Just edit some variables near the top including the volume and job comment
'templates' and you should be set.

I have tested this script extensively here, and it works exactly as expected,
but since I do make a couple 'sql' calls from in bconsole to update the volume
and job comment fields, please review this script carefully, and test in a
sandbox environment if there are any concerns.

Hope this is useful to someone 'as-is', or maybe as an example to do something
else.   :)

I'll post it to my website at some later time.

Best regards,


Bill Arlofski
-- Not responsible for anything below this line --

Attachment: checkAndCommentOnRestoreVolumesAndJobs.sh
Description: application/shellscript

Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
Bacula-users mailing list

Reply via email to