From: Mantis B. T. <no...@bu...> - 2012-02-15 08:20:06
|
The following issue has been CLOSED ====================================================================== http://bugs.bacula.org/view.php?id=1831 ====================================================================== Reported By: linuxaos Assigned To: ====================================================================== Project: bacula Issue ID: 1831 Category: bat Reproducibility: always Severity: major Priority: normal Status: closed Resolution: open Fixed in Version: ====================================================================== Date Submitted: 2012-02-13 18:39 UTC Last Modified: 2012-02-15 08:19 UTC ====================================================================== Summary: bacula 5.2.5: bat restored a file only once. Afterward, I get an error: "Can't create restore list" Description: When I try to do a restore from bat I get an error: "Can't create restore list" bconsole and bwx-console restores work fine!!!! Steps to Reproduce: This is the detailed description: >From bat, I start bRestore. I select the client (which is also the bacula server) I select the job list (the last full backup) I select /etc (any file will do, really) I drag down to restore window. Note: Estimate button is grayed out. I click on restore Run Restore window pops up. On advanced Tab I select "autochanger" as the storage and select "RestoreFilesLinux" as job name I click on "Standard" Tab. "Media Needed" does not show that the volume is in changer (it is in fact in there. I click on OK I get a popup with: "Can't create restore list" I run bacula-dir with debug of 1000 and I get: 1 cbackup-dir: bvfs.c:992-0 q=CREATE TABLE b2123 AS ( SELECT JobId, FileIndex, FileId, max(JobTDate) as JobTDate FROM btempb2123 GROUP BY PathId, FilenameId HAVING FileIndex > 0) 2 cbackup-dir: mysql.c:375-0 db_sql_query starts with CREATE TABLE b2123 AS ( SELECT JobId, FileIndex, FileId, max(JobTDate) as JobTDate FROM btempb2123 GROUP BY PathId, FilenameId HAVING FileIndex > 0) 3 cbackup-dir: mysql.c:381-0 db_sql_query failed 4 cbackup-dir: bvfs.c:994-0 Can't execute q 5 cbackup-dir: mem_pool.c:608-0 max_size=963 Additional Information: I can reproduce this 100% of the time. I have included the bacula_config file as well as all config files. There are no disk issues... Plenty of space. ====================================================================== ---------------------------------------------------------------------- (0006184) linuxaos (reporter) - 2012-02-15 04:52 http://bugs.bacula.org/view.php?id=1831#c6184 ---------------------------------------------------------------------- Solved! The problem here is this: Bat crashed hard and table: b2123 was left hanging around when it should've been deleted. When we got to line 992 of bvfs.c, we ran the query: "CREATE TABLE..." but that failed because the table was already there. Proper solution should be: First "Drop TABLE b2123" (Don't care about the status) Then "CREATE TABLE b2123" This time we do care about the status and the error would indicate and actual error with the "CREATE TABLE" So, there you have it my fellow bacula-ites. My solution(workaround) was to drop table from mysql command line. Boom! Problem solved. Thank you all for bacula. It is a fantastic product! -George Hrysanthopoulos ---------------------------------------------------------------------- (0006185) ebollengier (administrator) - 2012-02-15 08:19 http://bugs.bacula.org/view.php?id=1831#c6185 ---------------------------------------------------------------------- Thanks for your help, good idea, I will implement it. Issue History Date Modified Username Field Change ====================================================================== 2012-02-13 18:39 linuxaos New Issue 2012-02-13 18:39 linuxaos File Added: bacula_bat_bug.tgz 2012-02-15 04:52 linuxaos Note Added: 0006184 2012-02-15 08:19 ebollengier Note Added: 0006185 2012-02-15 08:19 ebollengier Status new => closed ====================================================================== |