On 7/19/25 12:46 PM, Michel Figgins wrote:
>> Thanks Bill!

Hello Michel. You are welcome. :)


I have 2 jobs configured for each client that are identical other than 
storage/pool.

Do you realize that you can override the Pool and Storage in a schedule, on the 
command line, or just before submitting a job?

Using the Schedule option, then you can have one Job/Fileset configured for 
each client, and do something like:
----8<----
Schedule {
  Name = Local_and_Remote
  Run = Storage=Local  Pool=Local   Level=Full             sun at 23:00
  Run = Storage=Local  Pool=Local   Level=Incremental  mon-sat at 23:00
  Run = Storage=Remote Pool=Remote  Level=Full             sun at 20:00
  Run = Storage=Remote Pool=Remote  Level=Incremental  mon-sat at 23:00
}
----8<----

BUT... Rather, than backing up the same thing twice from each client, Copy jobs - as you mentioned in your first post - are probably a better direction to pursue.


What I have wound up doing
is firing up psql and using these:
select MAX(jobid) from Job where clientid = (select clientid from Client where 
name='server1-fd') and poolid=7 and level='F';
select MAX(jobid) from Job where clientid = (select clientid from Client where 
name='server1-fd') and poolid=7 and level='D';
select jobid from Job where clientid = (select clientid from Client where 
name='server1-fd') and poolid=7 and level='I' and jobid > (select MAX(jobid) from 
Job where clientid = 14 and poolid=7 and level='D') and jobbytes > 0;
having already figured out that poolid 7 is my local storage pool.

> (My apologies to anyone who looks at my SQL and cringes)

No need to be embarrassed if it got you what you needed... :)


The jobbytes >0 bit is because of some later jobs that failed.

That's what the "jobstatus='T'" in my example query was for. A job status of 'T' means "Backup OK", or "Backup OK -- with warnings" :)


Best regards,
Bill

--
Bill Arlofski
w...@protonmail.com

Attachment: signature.asc
Description: OpenPGP digital signature

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

Reply via email to