do weasels way to do mass re-runs of backups
[mirror/dsa-wiki.git] / input / howto / bacula-hints.mdwn
1 ## useful bacula commands 
2
3 ### find out what was in a backup run
4  * get the job-id from the bacula mail
5  * run the following on bacula database (currently bmdb1.debian.org)
6 ```
7 select path,name from filename inner join file on filename.filenameid=file.filenameid inner join path on path.pathid=file.pathid where file.jobid=$JOBID;
8 ```
9 ### reschedule a backup run
10  * check the debian-admin-bacula archive on master for failed runs
11  * if the issue is intermittent or fixed, log in to dinis
12  * run bconsole
13  * type "run", and pick the host
14  * if necessary adjust "level", then start the backup
15
16 ### do a mass reschedule on what is needed
17 ```
18 (cd /etc/bacula/conf.d && for i in *; do h="${i%%.conf}"; /usr/lib/nagios/plugins/dsa-check-bacula -w 17h $h > /dev/null|| echo "run $h yes"; done) |tee incruns
19 ```