Bacula-users

Re: [Bacula-users] Bacula 7.2.0 job complete disappeared after backup

2015-09-11 13:21:07
Subject: Re: [Bacula-users] Bacula 7.2.0 job complete disappeared after backup
From: Bill Arlofski <waa-bacula AT revpol DOT com>
To: bacula-users AT lists.sourceforge DOT net
Date: Fri, 11 Sep 2015 13:16:37 -0400
On 09/09/2015 07:17 AM, Wanderlei Huttel wrote:
> The log file!
> 08-Set 22:10 bacula-sd JobId 1609: Elapsed time=00:10:21, Transfer rate=7.373 
> M Bytes/second
> 08-Set 22:10 bacula-sd JobId 1609: Sending spooled attrs to the Director. 
> Despooling 1,630 bytes ...
> 08-Set 22:10 bacula-dir JobId 1609: Warning: Error updating job record. 
> bdb.h:101 Update failed: affected_rows=0 for UPDATE Job SET 
> JobStatus='T',EndTime='2015-09-08 
> 22:10:38',ClientId=13,JobBytes=4578900197,ReadBytes=12587146777,JobFiles=4,JobErrors=1,VolSessionId=14,VolSessionTime=1441722251,PoolId=13,FileSetId=47,JobTDate=1441761038,RealEndTime='2015-09-08
>  22:10:38',PriorJobId=0,HasBase=0,PurgedFiles=0 WHERE JobId=1609
> 08-Set 22:10 bacula-dir JobId 1609: Warning: Error getting Job record for Job 
> report: ERR=sql_get.c:307 No Job found for JobId 1609
> 08-Set 22:10 bacula-dir JobId 1609: Error: Bacula bacula-dir 7.2.0 (14Aug15):


Wanderlei,

The error is triggered when the job finished writing data to tape, and the SD
wanted to de-spool attributes for job 1609. The database complained that this
jobid did not exist, so the update to the db failed, and bacula fails the job.

Now, I have recently seen a job fail in the exact same manner when a volume
which Bacula had written to was _manually_ purged after Bacula had used it and
moved on to another tape.  Customer basically shot themselves in the foot for
this job.

You have the same problem, except yours is a configuration issue. See this:

----8<----
08-Set 22:09 bacula-sd JobId 1609: End of medium on Volume "Volume-VM-0001"
Bytes=3,999,937,524 Blocks=62,003 at 08-Set-2015 22:09.
08-Set 22:09 bacula-dir JobId 1609: Error: sql_create.c:387 Volume
"Volume-VM-0001" already exists.
08-Set 22:09 bacula-dir JobId 1609: Purging oldest volume "Volume-VM-0001"
08-Set 22:09 bacula-dir JobId 1609: 1 File on Volume "Volume-VM-0001" purged
from catalog.
08-Set 22:09 bacula-dir JobId 1609: There are no more Jobs associated with
Volume "Volume-VM-0001". Marking it purged.
----8<----

Bacula is mis-configured and is set to purge the oldest volume. Using this
option This is not recommended unless you have carefully calculated the number
of volumes required in the pool, and their retention periods.

So, immediately after it finished with volume=Volume-VM-0001, it needed a new
one and purged the only one available as it is configured to do.

You should paste your pool configuration for pool=VM so that we may help you
configure it correctly.

Bill



-- 
Bill Arlofski
http://www.revpol.com/bacula
-- Not responsible for anything below this line --

------------------------------------------------------------------------------
_______________________________________________
Bacula-users mailing list
Bacula-users AT lists.sourceforge DOT net
https://lists.sourceforge.net/lists/listinfo/bacula-users