Bacula-users

[Bacula-users] A reasonable way to get a list of files backed up in a job?

2008-05-04 17:11:37
Subject: [Bacula-users] A reasonable way to get a list of files backed up in a job?
From: "K. M. Peterson" <kmp.lists+bacula-users AT gmail DOT com>
To: Bacula-users AT lists.sourceforge DOT net
Date: Sun, 4 May 2008 17:11:28 -0400
Hi all,

We're migrating to Bacula from a fairly random system of backups, many of which used tar jobs being run on servers and then copying them to a "backup machine" (via NFS) where they were manually migrated to another medium.  (You don't want to hear what that other medium is...)

To move this migration along, I'd like to have a way to determine the files that were backed up in job, so that I can delete them.  This way, I could migrate these tar files over to our bacula machine, and then delete them once I know they are on tape.  Generally, the names are date-tagged in some way, but this isn't something that I want to rely on (in case the copy process gets hosed, and there are 'old' files that actually haven't been copied by Bacula).

If there were some reasonable way to get a list from Bacula of the files in a particular job, that would help.  I see that I can run a Verify job (say, type DiskToCatalog) and get a list of the files that have changed or otherwise differ from the state of those on the backup set, or I can get a list of files that were not saved or encountered errors using parameters in a message resource ("skipped" or "notsaved" types) in a particular backup job.  This is the converse of what I'd like to have.

There doesn't seem to be a way to determine in this way what files were backed up, or haven't been changed since a backup was made.

What I'm doing now is creating a sentinel file in the RunBeforeJob and then deleting all files "older" than this on successful completion (in a RunAfterJob) script.  This works, but it's not something that I'm particularly comfortable with - I can't think of how it might get screwed up, but I'd rather again have a positive state to check rather than the lack of a negative state.  And, I presume that I could write an SQL query of some sort and query the database - perhaps through a script talking to bconsole - but that strikes me as again not really plain enough for whomever takes over management of this task from me when I'm done with it.

Is there something that I'm missing here, either in my general approach or in how the particular code in the daemons is implemented?  I'm running 2.2.8 on OpenSUSE 10.2 with MySQL.

Thanks!
_KMP
Boston
-------------------------------------------------------------------------
This SF.net email is sponsored by the 2008 JavaOne(SM) Conference 
Don't miss this year's exciting event. There's still time to save $100. 
Use priority code J8TL2D2. 
http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone
_______________________________________________
Bacula-users mailing list
Bacula-users AT lists.sourceforge DOT net
https://lists.sourceforge.net/lists/listinfo/bacula-users