View Issue Details

IDProjectCategoryView StatusLast Update
0001308bareos-coreGeneralpublic2023-07-18 15:47
ReporterRuth Ivimey-Cook Assigned Tobruno-at-bareos  
PrioritynormalSeverityfeatureReproducibilityalways
Status closedResolutionwon't fix 
Platformamd64OSLinuxOS VersionUbuntu 20.04
Product Version19.2.9 
Summary0001308: If a job fails, but has written files to tape, don't leave tape full of undescribed data.
DescriptionIf a job fails to complete, currently the job is terminated and AFAICT no records are added to the database describing it. Nevertheless, the job exists on tape and is consuming tape space - potentially several tapes.

I would like the behaviour to be modified to either:

1. Cleanup, that is, return the tapes and catalogue to a similar state to before the failed job started:
  - the tape drive is rewound to the end of the last good job and tape-eod written there.
  - If the job spanned multiple complete tapes, those tapes are marked for recycling in the appropriate way in the database.
  - If the job started on a not-mounted tape then the operator is prompted (email/console) to insert it for an 'eod' to be written, with the option of not doing so and leaving that tape Full.


2. Describe what was written in the DB: Let the job be described in the catalogue completely, up to the point of failure.
  - This may involve rewinding the tape to find the end of the good data, or even doing a full scan of the tape (or even the job, though pref not!).
  - I'm not sure whether bareos retains enough info to properly continue from this state, but ideally a subsequent Incr or Diff backup following this would be able to back up the 'right' things, bearing in mind the failed job.


3. Work harder at not failing at all: If a tape error happens, call the operator and provide ways to carry on.
  For example,
  - if there is an error when re-reading the end of tape block, rewind further and rescan the written data to determine what is there, and write an eof, then carry on with a new tape in the usual way.
  - If the tape drive itself fails in some way, enable the operator to direct the job onto another drive and carry on.
TagsNo tags attached.

Activities

Int

Int

2021-08-18 10:55

reporter   ~0004211

I would like to see that feature too.
For rewinding tapes and reusing the space a mechanism to handle WORM tapes would have to be implemented, since these can not be reused.
bruno-at-bareos

bruno-at-bareos

2023-07-18 15:47

manager   ~0005206

While it is still not yet fully implemented, you should check the checkpoint feature in Bareos 22.1.0
Actually with checkpoints enabled, you will be able to restore the written data to volumes.

It will answer part of your described feature.

Issue History

Date Modified Username Field Change
2021-01-19 02:06 Ruth Ivimey-Cook New Issue
2021-08-18 10:55 Int Note Added: 0004211
2023-07-18 15:47 bruno-at-bareos Assigned To => bruno-at-bareos
2023-07-18 15:47 bruno-at-bareos Status new => closed
2023-07-18 15:47 bruno-at-bareos Resolution open => won't fix
2023-07-18 15:47 bruno-at-bareos Note Added: 0005206