--- /dev/null
+
+ This patch fixes a bug that cause storage to create JOBMEDIA records
+ for every block written to tape.
+
+ This Patch works with 2.2.8-jobmedia.patch
+
+ Apply this patch to Bacula 2.2.8 (and possibly any prior 2.2.x version) with:
+
+ cd <bacula-source>
+ patch -p0 <2.2.8-jobmedia-fix.patch
+ ./configure <your-options>
+ make
+ ...
+ make install
+
+
+Index: src/stored/block.c
+===================================================================
+--- src/stored/block.c (revision 6531)
++++ src/stored/block.c (working copy)
+@@ -374,7 +374,6 @@
+ if (dcr->NewVol) {
+ /* Note, setting a new volume also handles any pending new file */
+ set_new_volume_parameters(dcr);
+- dcr->NewFile = false; /* this handled for new file too */
+ } else {
+ set_new_file_parameters(dcr);
+ }
+Index: src/stored/device.c
+===================================================================
+--- src/stored/device.c (revision 6531)
++++ src/stored/device.c (working copy)
+@@ -226,6 +226,7 @@
+ }
+ set_new_file_parameters(dcr);
+ jcr->NumWriteVolumes++;
++ dcr->NewVol = false;
+ }
+
+ /*
for the first record during a restore rather than seek directly to
it.
+ You have to apply 2.2.8-jobmedia-fix.patch too.
+
Apply this patch to Bacula 2.2.8 (and possibly any prior 2.2.x version) with:
cd <bacula-source>
patch -p0 <2.2.8-jobmedia.patch
+ patch -p0 <2.2.8-jobmedia-fix.patch
./configure <your-options>
make
...