Hello, On Tuesday 01 August 2006 10:07, Ralf Gross wrote: > Hi, > > I have a problem with a job that finished with an error message. Job 108 > started yesterday morning and ended today at 3:55. > > Bacula 1.38.5, debian stable, postgresql 7.4.7-6sarge > > Running Jobs: > Console connected at 31-Jul-06 09:43 > JobId Level Name Status > ====================================================================== > 108 Full Bang.2006-07-29_19.00.00 is running > 109 Full BackupCatalog.2006-07-29_19.50.00 is waiting execution > 110 Full SMTCZB0003.2006-07-30_08.00.00 is waiting execution > 111 Full BackupCatalog.2006-07-30_08.20.00 is waiting execution > > [snip] > 01-Aug 02:19 bacula-sd: Spooling data again ... > 01-Aug 02:21 bacula-sd: Committing spooled data to Volume "Bang1". > Despooling 908,909,975 bytes ... > 01-Aug 02:23 bacula-dir: Max configured use duration exceeded. Marking > Volume "Bang1" as Used. > 01-Aug 02:23 bacula-sd: Sending spooled attrs to the Director. Despooling > 241,550,790 bytes ... > 01-Aug 03:55 bacula-dir: Bang.2006-07-29_19.00.00 Warning: Error updating > job record. sql_update.c:169 Update problem: affected_rows=0 > 01-Aug 03:55 bacula-dir: Bang.2006-07-29_19.00.00 Warning: Error getting > job record for stats: sql_get.c:287 No Job found for JobId 108 > 01-Aug 03:55 bacula-dir: Bang.2006-07-29_19.00.00 Error: Bacula 1.38.5 > (18Jan06): 01-Aug-2006 03:55:29
Well, not having the *full* output from the job makes it a bit hard to diagnose the problem. Normally, there should be additional output with the first error that was printed (affected_rows = 0). I have seen this kind of problem when a job is pruned while the job is running. The job starts, creates a job database record, it is pruned, the job terminates, and the job record no longer exist, hence the job fails as in the second error message above. This is possible and worth checking (i.e. was anything pruned while the job ran?) but if you previously had database problems, it is not very likely to be the cause. > > * status dir > [snip] > Terminated Jobs: > JobId Level Files Bytes Status Finished Name > ======================================================================== > [snip] > 108 Full 755,497 226,024,976,679 Error 01-Aug-06 03:55 Bang > 110 Full 350,469 62,591,189,371 OK 01-Aug-06 08:55 SMTCZB0003 > 109 Full 1 348,330,920 OK 01-Aug-06 09:03 BackupCatalog > 111 Full 1 348,330,998 OK 01-Aug-06 09:12 BackupCatalog > > > * list jobs > [snip] > +-----+----------+---------+------+------+----------+----------+----------+ > |jobid| name |starttime| type | level| jobfiles | jobbytes |jobstatus | > +-----+----------+---------+------+------+----------+----------+----------+ > [snip] > | 105 |SMTCZB0003|2006-07-24 14:51:55|B|F|349,640|62,232,279,458|T| > | 110 |SMTCZB0003|2006-08-01 03:55:33|B|F|350,469|62,591,189,371|T| > | 109 |BackupCatalog|2006-08-01 08:55:07|B|F|1|348,330,920|T| > | 111 |BackupCatalog|2006-08-01 09:03:35|B|F|1|348,330,998|T| > > > I have no idea what happend to job 108. It backed up all files, but failed > to update the job record at the end. The next jobs ended without errors. > > Last week I had to recover the database from a crash (see my mails from > last week with subject ERROR: duplicate key violates unique constraint). > This problem seemed to have been solved, because job 106 finished > successful. > > 106 Full 750,501 220,926,385,105 OK 26-Jul-06 03:38 Bang > > But if I check the jobs with 'list jobs' I can't find job 106 or 108. > > | 101 |BackupCatalog|2006-07-17 09:21:26| B | F | 0 | 0 | A | > | 103 |BackupCatalog|2006-07-17 10:12:33| B | F | 0 | 0 | R | > | 104 |SMTCZB0003 |2006-07-24 14:46:27| B | F | 0 | 0 | f | > | 105 |SMTCZB0003 |2006-07-24 14:51:55| B | F |349,640|62,232,279,458|T| > | 110 |SMTCZB0003 |2006-08-01 03:55:33| B | F |350,469|62,591,189,371|T| > | 109 |BackupCatalog|2006-08-01 08:55:07| B | F | 1 | 348,330,920 |T| > | 111 |BackupCatalog|2006-08-01 09:03:35| B | F | 1 | 348,330,998 |T| > > > dbcheck also shows me errors regarding job 108. > [snip] > Found 22 orphaned JobMedia records. > Print them? (yes/no): yes > > Orphaned JobMediaId=6714 JobId=108 Volume="Bang1" > Orphaned JobMediaId=6715 JobId=108 Volume="Bang1" > Orphaned JobMediaId=6716 JobId=108 Volume="Bang1" > Orphaned JobMediaId=6717 JobId=108 Volume="Bang1" > Orphaned JobMediaId=6718 JobId=108 Volume="Bang1" > Orphaned JobMediaId=6719 JobId=108 Volume="Bang1" > Orphaned JobMediaId=6720 JobId=108 Volume="Bang1" > Orphaned JobMediaId=6721 JobId=108 Volume="Bang1" > Orphaned JobMediaId=6722 JobId=108 Volume="Bang1" > Orphaned JobMediaId=6723 JobId=108 Volume="Bang1" > Orphaned JobMediaId=6724 JobId=108 Volume="Bang1" > Orphaned JobMediaId=6725 JobId=108 Volume="Bang1" > Orphaned JobMediaId=6726 JobId=108 Volume="Bang1" > Orphaned JobMediaId=6727 JobId=108 Volume="Bang1" > Orphaned JobMediaId=6728 JobId=108 Volume="Bang1" > Orphaned JobMediaId=6729 JobId=108 Volume="Bang1" > Orphaned JobMediaId=6730 JobId=108 Volume="Bang1" > Orphaned JobMediaId=6731 JobId=108 Volume="Bang1" > Orphaned JobMediaId=6732 JobId=108 Volume="Bang1" > Orphaned JobMediaId=6733 JobId=108 Volume="Bang1" > Orphaned JobMediaId=6734 JobId=108 Volume="Bang1" > Orphaned JobMediaId=6735 JobId=108 Volume="Bang1" > Checking for orphaned File entries. This may take some time! > Found 1103096 orphaned File records. > Checking for orphaned Path entries. This may take some time! > Found 174 orphaned Path records > Checking for orphaned Filename entries. This may take some time! > Found 108 orphaned Filename records. > [snip] > > > It seems that I still have a db problem. What can I look for and how can I > fix it? Any ideas? Here again, you didn't show provide all the information -- most importantly did you run dbcheck so that it would correct those errors? It will not by default modify the database. Until you run it and let it modify the database, the inconsistencies will remain. ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys -- and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV _______________________________________________ Bacula-users mailing list Bacula-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/bacula-users