View Issue Details

IDProjectCategoryView StatusLast Update
0000146bareos-coredirectorpublic2015-03-25 19:18
Reporteruser12Assigned To 
PrioritynormalSeverityminorReproducibilityalways
Status closedResolutionfixed 
PlatformLinuxOSUbuntuOS Version12.04
Product Version12.4.2 
Fixed in Version12.4.4 
Summary0000146: Variable "Job Exit Code" in mailcommand reports always "Error" when doing copy or migration job
DescriptionVariable "Job Exit Code" in mailcommand reports always "Error" when doing copy or migration job even though copy and original backup job terminated with status "Backup OK" and no warnings at all.

From root@localhost Sat Mar 16 22:00:03 2013
Return-Path: <root@localhost>
X-Original-To: root@localhost
Delivered-To: root@localhost
Received: from sl-bareos01.bareos.lan (localhost [127.0.0.1])
        by sl-bareos01.bareos.lan (Postfix) with SMTP id BFDE840ECD
        for <root@localhost>; Sat, 16 Mar 2013 22:00:03 +0100 (CET)
From: (Bareos Tape entnehmen) <root@localhost>
Subject: Client: sl-bareos01-fd Director: sl-bareos01-dir Job Exit Code: Error UniqueJI: Copy2Tape.2013-03-16_22.00.00_06 Level: Full Jobname: Copy2Tape Since: *none* JobType: Copy Recipient: root@localhost SrcVolname: VFB-0034 DesVolname: VFB-0034, JobBytes: 288715
TagsNo tags attached.

Activities

mvwieringen

mvwieringen

2013-04-09 14:38

developer   ~0000327

Need the message definition.

user12

2013-04-09 14:39

  ~0000328

Messages {
  Name = Tapes_entnehmen
  mailcommand = "/usr/sbin/bsmtp -h mail -f \"\(Bareos Tape entnehmen\) \<%r\>\" -s \"Client: %c Director: %d Job Exit Code: %e JobId: %i UniqueJI: %j Level: %l Jobname: %n Since: %s JobType: %t Recipient: %r SrcVolname: %v DesVolname: %V, JobBytes: %b \" %r"
  mail = root@localhost = all, !skipped
  console= all, !skipped, !saved
  catalog = all, !skipped, !saved
}

user12

2013-04-10 14:30

  ~0000332

Bareos 13.2 problem Exit Code "Error" still persisting:

Message 5:
From root@localhost Sat Mar 16 22:00:05 2013
Return-Path: <root@localhost>
X-Original-To: root@localhost
Delivered-To: root@localhost
From: (Bareos Tape entnehmen) <root@localhost>
Subject: Client: sl-bareos01-fd Director: sl-bareos01-dir Job Exit Code: Error JobId: 4 UniqueJI: Copy2Tape.2013-03-16_22.00.00_05 Level: Full Jobname: Copy2Tape Since: *none* JobType: Copy Recipient: root@localhost SrcVolname: VFB-0034 DesVolname: E01001L4, JobBytes: 10562077
Sender: bareos@sl-bareos01.bareos.lan
To: root@localhost
Date: Sat, 16 Mar 2013 22:00:05 +0100 (CET)
Status: RO

user12

2013-06-03 14:08

  ~0000441

Testet with 12.4.3-657.1 - Job Exit Code: OK, when doing Backup and having run scrips executed:

03-Jun 13:59 sl-bareos01-dir JobId 159: shell command: run AfterJob "/bin/bash -c "/bin/echo Remove Tape E01003L4 from Slot 6 |/usr/sbin/bsmtp -h localhost -f root@localhost -s 'Remove Tape E01003L4 from Slot 6' root@localhost"
03-Jun 13:59 sl-bareos01-dir JobId 159: console command: run AfterJob "export storage=TSL dstslots=6 volume=E01003L4"

If a runscript "fails":
03-Jun 13:49 sl-bareos01-dir JobId 0: Connecting to Storage daemon TSL at sl-bareos01.bareos.lan:9103 ...
03-Jun 13:49 sl-bareos01-dir JobId 0: 3306 Issuing autochanger "slots" command.
03-Jun 13:49 sl-bareos01-dir JobId 0: Device "TSL" has 6 slots.
03-Jun 13:49 sl-bareos01-dir JobId 0: Connecting to Storage daemon TSL at sl-bareos01.bareos.lan:9103 ...
03-Jun 13:49 sl-bareos01-dir JobId 0: 3306 Issuing autochanger "listall" command.
03-Jun 13:49 sl-bareos01-dir JobId 0: Not all slots in destination selection are export slots and empty.

Then Job Exit Code: Error
mvwieringen adm

mvwieringen adm

2013-08-13 03:12

administrator   ~0000592

Fix committed to bareos bareos-12.4 branch with changesetid 945.
mvwieringen

mvwieringen

2015-03-25 16:51

developer   ~0001378

Fix committed to bareos2015 bareos-13.2 branch with changesetid 4235.
joergs

joergs

2015-03-25 19:18

developer   ~0001536

Due to the reimport of the Github repository to bugs.bareos.org, the status of some tickets have been changed. These tickets will be closed again.
Sorry for the noise.

Related Changesets

bareos: bareos-12.4 9d5f6267

2013-05-04 13:15

mvwieringen adm

Ported: N/A

Details Diff
Return right returnvalue on import/export/move cmd.

We were always returning 0 (e.g. operation failed) for
the import/export/move commands. This makes any runscript fail
any next runscript and the Job also fails.

Fixes 0000146: Variable "Job Exit Code" in mailcommand reports always
"Error" when doing copy or migration job
Fixes 0000155: runafterjob doesn't get executed if a runscript directive is
placed before the directive runafterjob
Affected Issues
0000146, 0000155
mod - src/dird/ua_impexp.c Diff File

bareos2015: bareos-12.4 729d2238

2013-05-04 15:15

mvwieringen

Ported: N/A

Details Diff
Return right returnvalue on import/export/move cmd.

We were always returning 0 (e.g. operation failed) for
the import/export/move commands. This makes any runscript fail
any next runscript and the Job also fails.

Fixes 0000146: Variable "Job Exit Code" in mailcommand reports always
"Error" when doing copy or migration job
Fixes 0000155: runafterjob doesn't get executed if a runscript directive is
placed before the directive runafterjob
Affected Issues
0000146, 0000155
mod - src/dird/ua_impexp.c Diff File

bareos: master b93d0fdb

2013-05-04 21:25

mvwieringen adm

Ported: N/A

Details Diff
Return right returnvalue on import/export/move cmd.

We were always returning 0 (e.g. operation failed) for
the import/export/move commands. This makes any runscript fail
any next runscript and the Job also fails.

Fixes 0000146: Variable "Job Exit Code" in mailcommand reports always
"Error" when doing copy or migration job
Fixes 0000155: runafterjob doesn't get executed if a runscript directive is
placed before the directive runafterjob
Affected Issues
0000146, 0000155
mod - src/dird/ua_impexp.c Diff File

bareos2015: bareos-13.2 f59a541b

2013-05-04 23:25

mvwieringen

Ported: N/A

Details Diff
Return right returnvalue on import/export/move cmd.

We were always returning 0 (e.g. operation failed) for
the import/export/move commands. This makes any runscript fail
any next runscript and the Job also fails.

Fixes 0000146: Variable "Job Exit Code" in mailcommand reports always
"Error" when doing copy or migration job
Fixes 0000155: runafterjob doesn't get executed if a runscript directive is
placed before the directive runafterjob
Affected Issues
0000146, 0000155
mod - src/dird/ua_impexp.c Diff File

Issue History

Date Modified Username Field Change
2013-04-09 14:07 user12 New Issue
2013-04-09 14:38 mvwieringen Note Added: 0000327
2013-04-09 14:38 mvwieringen Assigned To => mvwieringen
2013-04-09 14:38 mvwieringen Status new => feedback
2013-04-09 14:39 user12 Note Added: 0000328
2013-04-09 14:39 user12 Status feedback => assigned
2013-04-10 14:30 user12 Note Added: 0000332
2013-04-12 16:22 mvwieringen Status assigned => acknowledged
2013-04-23 16:29 mvwieringen Changeset attached => bareos master c48f866f
2013-04-23 16:29 mvwieringen Status acknowledged => closed
2013-04-23 16:29 mvwieringen Resolution open => fixed
2013-04-23 16:29 mvwieringen Changeset attached => bareos Branch-12.4 e47164f2
2013-04-23 16:31 mvwieringen Assigned To mvwieringen =>
2013-04-23 16:31 mvwieringen Fixed in Version => 12.4.4
2013-04-23 17:40 mvwieringen Status closed => resolved
2013-06-03 14:08 user12 Note Added: 0000441
2013-06-03 14:08 user12 Status resolved => closed
2013-06-03 14:08 user12 Assigned To => user12
2013-08-13 03:12 mvwieringen adm Changeset attached => bareos master b93d0fdb
2013-08-13 03:12 mvwieringen adm Changeset attached => bareos bareos-12.4 9d5f6267
2013-08-13 03:12 mvwieringen adm Note Added: 0000592
2013-08-13 03:12 mvwieringen adm Assigned To user12 => mvwieringen adm
2013-08-13 03:12 mvwieringen adm Status closed => resolved
2013-08-13 09:32 mvwieringen adm Assigned To mvwieringen adm =>
2013-08-13 09:32 mvwieringen adm Status resolved => closed
2015-03-25 16:51 mvwieringen Changeset attached => bareos2015 bareos-12.4 729d2238
2015-03-25 16:51 mvwieringen Changeset attached => bareos2015 bareos-13.2 f59a541b
2015-03-25 16:51 mvwieringen Note Added: 0001378
2015-03-25 16:51 mvwieringen Status closed => resolved
2015-03-25 19:18 joergs Note Added: 0001536
2015-03-25 19:18 joergs Status resolved => closed