***** DVDs=$(bc <<< "$Bytes / (4724464025.6 ^ 2)") ============================================================================== Heitor Medrado de Faria - LPIC-III | ITIL-F 02 a 13 de Março - Novo Treinamento Telepresencial Bacula: http://www.bacula.com.br/?p=2174 61 8268-4220 Site: www.bacula.com.br | Facebook: heitor.faria | Gtalk: heitorfa...@gmail.com ===============================================================================
----- Mensagem original ----- > De: "Heitor Faria" <hei...@bacula.com.br> > Para: "S McGraw" <smcg2...@frii.com> > Cc: bacula-users@lists.sourceforge.net > Enviadas: Sexta-feira, 27 de fevereiro de 2015 11:08:23 > Assunto: Re: [Bacula-users] Status of Python api? > > > > That's an interesting suggestion. I was worried the "estimate" > > command might be very slow but it seemed quick enough. Perhaps a > > potential problem might be a difference between the estimate and > > actual bytes, perhaps because a large file was created in the > > interim. > > > > Another possibility occurred to me prompted by your idea... again > > in a RunBeforeJob script, label a fixed number of volumes (I can > > put a fairly accurate upper bound on the backup data size for each > > client) and after the job delete the volumes that were not used. > > I'm not immediately sure the best way to determine which weren't > > used but I think that won't be too hard. I guess the risk here > > is that if the after job failed for some reason, the unused volumes > > would be left in the pool and would be used the next night. > > Mr. McGraw: I know it's not you want but I got curious, if you wanna test... > > create_volumes_before_job.sh: > > Bytes=$(echo "estimate job=BackupClient1 level=$Level" | bconsole | sed > '/bytes=/!d;s/^.*bytes=//;s/[.,]//g') > echo "==== Job total Bytes=$Bytes ====" > DVDs=$(bc <<< "$Bytes / (4.4 * 1024 ^ 2)") > echo "==== DVDs required=$DVDs ====" > for ((Counter=0; Counter<=$DVDs; Counter++)) > { > echo "label pool=Default storage=File1 volume=BackupClient1-$Counter" > |bconsole > Counter=$((Counter + 1)) > } > > ------------------------------------------------------------------------------ > Dive into the World of Parallel Programming The Go Parallel Website, > sponsored > by Intel and developed in partnership with Slashdot Media, is your hub for > all > things parallel software development, from weekly thought leadership blogs to > news, videos, case studies, tutorials and more. Take a look and join the > conversation now. http://goparallel.sourceforge.net/ > _______________________________________________ > Bacula-users mailing list > Bacula-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/bacula-users > ------------------------------------------------------------------------------ Dive into the World of Parallel Programming The Go Parallel Website, sponsored by Intel and developed in partnership with Slashdot Media, is your hub for all things parallel software development, from weekly thought leadership blogs to news, videos, case studies, tutorials and more. Take a look and join the conversation now. http://goparallel.sourceforge.net/ _______________________________________________ Bacula-users mailing list Bacula-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/bacula-users