Hello Christoph,
You're right, the mail messages are about the new backup job that writes data from the previous job(s)/volume(s) to the new job(s)/volume(s).
From: Bacula <bacula AT uni-koblenz DOT de>To: bacula AT uni-koblenz DOT deSubject: Bacula: Backup OK of clientname Incremental02-Oct 05:09 bacula-dir JobId 697689: Using Device "LTO4-0" to write.02-Oct 05:09 bacula-sd JobId 697689: Elapsed time=00:00:04, Transfer rate=89.96 M Bytes/second02-Oct 05:09 bacula-sd JobId 697689: Sending spooled attrs to the Director. Despooling 26,284 bytes …
The above three messages are from director and storage daemon:
src/dird/msgchan.c
348 if (ok) {
349 Jmsg(jcr, M_INFO, 0, _("Using Device \"%s\" to write.\n"), device_name.c_str());
350 }
src/stored/append.c
341 Jmsg(dcr->jcr, M_INFO, 0, _("Elapsed time=%02d:%02d:%02d, Transfer rate=%s Bytes/second\n"),
342 job_elapsed / 3600, job_elapsed % 3600 / 60, job_elapsed % 60,
343 edit_uint64_with_suffix(jcr->JobBytes / job_elapsed, ec));
src/stored/spool.c:
715 jcr->sendJobStatus(JS_AttrDespooling);
716 Jmsg(jcr, M_INFO, 0, _("Sending spooled attrs to the Director. Despooling %s bytes ...\n"),
717 edit_uint64_withsrc/stored/append.c_commas(size, ec1));
And it is possible that various other messages could be logged for this new backup job, like the bellow:
07-Oct 23:40 bacula-server-dir JobId 3: Created new Volume="WritePool-0002", Pool="WritePool", MediaType="File2" in catalog.
...
07-Oct 23:40 bacula-server-sd JobId 3: Labeled new Volume "WritePool-0002" on file device "FileChgr2-Dev1" (/opt/bacula/disks/disk2).
07-Oct 23:40 bacula-server-sd JobId 3: Wrote label to prelabeled Volume "WritePool-0002" on file device "FileChgr2-Dev1" (/opt/bacula/disks/disk2)
So, there will be a lot of code that will log this messages for the new backup job and not for the copy job.
Maybe this could be solved by setting wjcr->jcr_msgs = jcr->jcr_msgs in src/dird/mac.c. This way, all the messages from the new backup job (wjcr), would be treated by the same message resource as the Copy/Migration job.
I'm not sure about which approach would be better for debugging issues with copy and migrate jobs.
I'm also sending this message to the bacula-devel for appreciation.
Best regards,
Ana