Hello,

On 7/6/2006 5:10 PM, Ludovic Strappazon wrote:
> Hi Mark,
> 
> I've written a nagios shell script to check my pools in the way you 
> describe.
> I also remember that Arno Lehmann did something similar in perl (it is 
> distibuted with the bacula sources)

Erm, no, not really.
I considered adding such a function to the baculareport scrip I created, 
but never actually found it necessary. But I really like to see what 
you've got :-)

> Regards,
> Ludovic Strappazon.
> 
> [EMAIL PROTECTED] a écrit :
> 
>> Is there any way to have bacula predict how many volumes will be 
>> needed for the next night's backup?
>> My goal is to make sure that the autochanger is always loaded with 
>> enough tapes
>> to handle the next night's backup, without changing tapes every day.
>>
>> I'm interested in having bacula notify me in advance that it guesses 
>> that the
>> following night's backup will require "N" volumes. I don't want to run
>> "estimate" for each client (which is a time-consuming and resource 
>> intensive
>> action), and then sum the results. It would be great if bacula made 
>> use of
>> information that's in the database to get the average of the sizes of 
>> the last
>> "X" backups of the same level that's scheduled for the next backup 
>> (ie., full,
>> incremental, differential) for each client, and then added a user-defined
>> fudge-factor (maybe 10%) to guess at the size of the upcoming backup 
>> for all
>> scheduled jobs.

I would even try to estimate the expected growth (does *anybody* have 
backup sets that become smaller over time?) from the existing backups. 
Simply assume a linear growth and add the observed error to your result. 
Or something. I would need to brush up my mathematical / statistical 
knowledge a bit :-)

>> For example, most of our non-full backups are under 100GB for all clients
>> combined, so our autochanger can run for a long time without manually 
>> removing
>> full tapes and putting in new ones. However, full backups can be 
>> anywhere from
>> 40GB to over 2TB (depending on the client). To reduce contention, full 
>> backups
>> are set up with a staggered schedule--each client does a "full" on a 
>> different
>> night. It would be nice to get some warning from bacula that the next 
>> night's
>> backup will "probably" take 6 volumes, so that I can make sure the 
>> enough empty
>> (or over-writeable) tapes are loaded.
>>
>>
>> Any suggestions about scripting such an "early warning system"? I'm 
>> thinking of something like:
>>
>> ----------- bad pseudo-code ---------------------------
>>     foreach $client sqlquery("Get list of clients scheduled to backup 
>> tonight")
>>     {
>>         $backup_level=sqlquery("Get level of next backup for $client");

One problem might be to get the pool the next backup goes to.

>>         $size=average(sqlquery "size in GB of all backups for
>>                 $client of $backup_level");
>>     
>>         $predictedsize=$total + $size;
>>     }
>>
>>     $predictedsize=$predictedsize * $fudgefactor;

This would need to be calculated per pool, IMO.

>>     foreach $volsize (sqlquery("Select VolumeSize in GB
>>                     where VolumeStatus='Full'"))
>>     {
>>         $volsizetotal=$volsize + $volsizetotal;
>>         $volcount++;     }
>>
>>     $average_GB_to_fill_volume=$volsizetotal/$volcount;

I do have some function to estimate volume capacity in baculareport.pl 
which is a little more complicated, but still gives reasonable results :-)

>>     $volumes_needed=$predictedsize / $average_GB_to_fill_volume;
>>
>>     roundup($volumes_needed);
>>
>>     print "There will be $volumes_needed needed for tonight's backup";
>> ------------ EO bad pseudo-code 
>> -------------------------------------------
>>

Apart from my obsession with with putting backups of different levels to 
different pools and storage devices, I fully agree - such a script would 
be a nice addition.

Arno

>>
>> Thanks,
>>
>> Mark
>> ----
>> Mark Bergman                      [EMAIL PROTECTED]
>> System Administrator
>> Section of Biomedical Image Analysis             215-662-7310
>> Department of Radiology,           University of Pennsylvania
>>
>> http://pgpkeys.pca.dfn.de:11371/pks/lookup?search=mark.bergman%40.uphs.upenn.edu
>>  
>>
>>
>>
>>
>> The information contained in this e-mail message is intended only for 
>> the personal and confidential use of the recipient(s) named above. If 
>> the reader of this message is not the intended recipient or an agent 
>> responsible for delivering it to the intended recipient, you are 
>> hereby notified that you have received this document in error and that 
>> any review, dissemination, distribution, or copying of this message is 
>> strictly prohibited. If you have received this communication in error, 
>> please notify us immediately by e-mail, and delete the original message.
>>
>> Using Tomcat but need to do more? Need to support web services, security?
>> Get stuff done quickly with pre-integrated technology to make your job 
>> easier
>> Download IBM WebSphere Application Server v.1.0.1 based on Apache 
>> Geronimo
>> http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
>> _______________________________________________
>> Bacula-users mailing list
>> Bacula-users@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/bacula-users
>>
>>   
> 
> 
> 
> ------------------------------------------------------------------------
> 
> Using Tomcat but need to do more? Need to support web services, security?
> Get stuff done quickly with pre-integrated technology to make your job easier
> Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
> http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
> 
> 
> ------------------------------------------------------------------------
> 
> _______________________________________________
> Bacula-users mailing list
> Bacula-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/bacula-users

-- 
IT-Service Lehmann                    [EMAIL PROTECTED]
Arno Lehmann                  http://www.its-lehmann.de


Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Bacula-users mailing list
Bacula-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bacula-users

Reply via email to