I've setup some backup jobs for some (mostly windows) client computer; i
mean 'client' as 'not always on'.


I've setup a job like this:

 Job {
        Name = FVG-SV-EEG

        JobDefs = DefaultJob
        Storage = SVPVE3FileMulti
        Pool = FVG-SV-EEGFilePool

        Messages = StandardClient

        Schedule = WeeklyClient
        Reschedule On Error = yes
        Reschedule Interval = 30 minutes
        Reschedule Times = 8
        Max Run Sched Time = 8 hours

        Accurate = yes
        Backups To Keep = 10
        Delete Consolidated Jobs = yes

        Client = fvg-sv-eeg-fd
        FileSet = SystemPlusStd

        Write Bootstrap = "/var/lib/bacula/FVG-SV-EEG.bsr"
 }

Because client are not always on, i've setup and aggressive reschedule,
waiting the system to go online.


Schedule is simply:

 Schedule {
        Name = WeeklyClient

        Run = Incremental mon-fri at 8:00
        Run = VirtualFull sun at 8:00
 }

so (try to) do the backup on weekdays, consolidate the full on sunday.


The pool is like:

 Pool {
        Name = FVG-SV-EEGFilePool

        Pool Type = Backup

        NextPool = FVG-SV-EEGFilePool
        Storage = SVPVE3FileMulti

        Maximum Volume Jobs = 6

        Recycle = yes
        AutoPrune = yes
        Action On Purge = Truncate
 }

EG, no volume retention (the default one, indeed) and a 'Maximum Volume
Jobs' to be able to move data in different volumes.

Every pool have 4 volumes (files), so i can have 6*4=24 jobs on the pool,
witha weekly 'virtual full' that reduce jobs to 10 consolidating them.


Setting up this, i've done some test in a lab setup and all work as
expected: i've done backups, consolidate them, jobs get purged on
consolidation and volumes with no jobs get purged too. All worked as
expected.

But reality hit me. ;-)


Typical situation now is:

*list media pool=FVG-SV-EEGFilePool 
+---------+------------+-----------+---------+----------------+----------+--------------+---------+------+-----------+-----------+---------+----------+---------------------+------------+
| mediaid | volumename | volstatus | enabled | volbytes       | volfiles | 
volretention | recycle | slot | inchanger | mediatype | voltype | volparts | 
lastwritten         | expiresin  |
+---------+------------+-----------+---------+----------------+----------+--------------+---------+------+-----------+-----------+---------+----------+---------------------+------------+
|     342 | EEG001     | Used      |       1 | 86,577,422,841 |       20 |   
31,536,000 |       1 |    0 |         0 | File      |       1 |        0 | 
2024-03-22 08:35:40 | 27,366,814 |
|     343 | EEG002     | Used      |       1 | 15,454,605,644 |        3 |   
31,536,000 |       1 |    0 |         0 | File      |       1 |        0 | 
2024-03-15 08:35:45 | 26,762,019 |
|     344 | EEG003     | Used      |       1 | 88,555,731,908 |       20 |   
31,536,000 |       1 |    0 |         0 | File      |       1 |        0 | 
2024-04-08 09:04:45 | 28,833,759 |
|     871 | EEG004     | Used      |       1 | 94,851,318,353 |       22 |   
31,536,000 |       1 |    0 |         0 | File      |       1 |        0 | 
2024-04-26 09:04:00 | 30,388,914 |
+---------+------------+-----------+---------+----------------+----------+--------------+---------+------+-----------+-----------+---------+----------+---------------------+------------+

*list jobs client=fvg-sv-eeg-fd 
+--------+------------+---------------------+------+-------+----------+----------------+-----------+
| jobid  | name       | starttime           | type | level | jobfiles | 
jobbytes       | jobstatus |
+--------+------------+---------------------+------+-------+----------+----------------+-----------+
| 17,917 | FVG-SV-EEG | 2024-03-05 15:01:40 | B    | I     |        0 |         
     0 | E         |
| 17,957 | FVG-SV-EEG | 2024-03-06 13:31:07 | B    | I     |        0 |         
     0 | E         |
| 19,257 | FVG-SV-EEG | 2024-03-08 08:31:05 | B    | F     |        0 |         
     0 | A         |
| 18,114 | FVG-SV-EEG | 2024-03-10 12:00:01 | B    | F     |        0 |         
     0 | E         |
| 19,552 | FVG-SV-EEG | 2024-03-11 08:30:02 | B    | F     |        0 |         
     0 | A         |
| 18,193 | FVG-SV-EEG | 2024-03-12 12:01:14 | B    | I     |        0 |         
     0 | E         |
| 18,234 | FVG-SV-EEG | 2024-03-13 14:01:14 | B    | I     |        0 |         
     0 | E         |
| 19,846 | FVG-SV-EEG | 2024-03-14 08:00:02 | B    | F     |   14,307 | 
75,484,385,315 | T         |
| 18,318 | FVG-SV-EEG | 2024-03-15 08:30:03 | B    | I     |       43 |  
3,689,555,968 | T         |
| 18,397 | FVG-SV-EEG | 2024-03-17 12:00:00 | B    | F     |        0 |         
     0 | E         |
| 18,437 | FVG-SV-EEG | 2024-03-18 09:00:13 | B    | I     |       40 |  
3,570,969,543 | T         |
| 20,138 | FVG-SV-EEG | 2024-03-18 09:00:13 | B    | F     |        0 |         
     0 | A         |
| 20,430 | FVG-SV-EEG | 2024-03-18 09:00:13 | B    | F     |        0 |         
     0 | A         |
| 18,479 | FVG-SV-EEG | 2024-03-19 12:00:49 | B    | I     |        0 |         
     0 | E         |
| 18,521 | FVG-SV-EEG | 2024-03-20 12:00:45 | B    | I     |        0 |         
     0 | E         |
| 18,564 | FVG-SV-EEG | 2024-03-21 08:00:03 | B    | I     |       85 |  
1,605,684,111 | T         |
| 18,606 | FVG-SV-EEG | 2024-03-22 08:30:04 | B    | I     |       41 |  
3,647,025,965 | T         |
| 18,723 | FVG-SV-EEG | 2024-03-25 09:00:10 | B    | I     |       42 |  
3,383,749,970 | T         |
| 18,769 | FVG-SV-EEG | 2024-03-26 12:00:49 | B    | I     |        0 |         
     0 | E         |
| 18,811 | FVG-SV-EEG | 2024-03-27 13:00:57 | B    | I     |        0 |         
     0 | E         |
| 18,856 | FVG-SV-EEG | 2024-03-28 09:00:10 | B    | I     |       98 |  
1,933,136,717 | T         |
| 18,903 | FVG-SV-EEG | 2024-03-29 14:31:13 | B    | I     |        0 |         
     0 | E         |
| 19,005 | FVG-SV-EEG | 2024-04-01 12:00:47 | B    | I     |        0 |         
     0 | E         |
| 19,048 | FVG-SV-EEG | 2024-04-02 12:00:43 | B    | I     |        0 |         
     0 | E         |
| 19,092 | FVG-SV-EEG | 2024-04-03 12:00:42 | B    | I     |        0 |         
     0 | E         |
| 19,135 | FVG-SV-EEG | 2024-04-04 09:00:10 | B    | I     |       33 |  
2,381,893,421 | T         |
| 19,178 | FVG-SV-EEG | 2024-04-05 09:30:16 | B    | I     |       40 |  
3,141,993,344 | T         |
| 19,298 | FVG-SV-EEG | 2024-04-08 09:01:09 | B    | I     |       32 |  
2,201,965,178 | T         |
| 19,341 | FVG-SV-EEG | 2024-04-09 12:01:19 | B    | I     |        0 |         
     0 | E         |
| 19,386 | FVG-SV-EEG | 2024-04-10 12:00:44 | B    | I     |        0 |         
     0 | E         |
| 19,429 | FVG-SV-EEG | 2024-04-11 09:00:04 | B    | I     |        0 |         
     0 | A         |
| 19,472 | FVG-SV-EEG | 2024-04-12 09:00:04 | B    | I     |        0 |         
     0 | A         |
| 19,593 | FVG-SV-EEG | 2024-04-15 08:30:05 | B    | I     |        0 |         
     0 | A         |
| 19,636 | FVG-SV-EEG | 2024-04-16 14:01:02 | B    | I     |        0 |         
     0 | E         |
| 19,680 | FVG-SV-EEG | 2024-04-17 12:00:51 | B    | I     |        0 |         
     0 | E         |
| 19,723 | FVG-SV-EEG | 2024-04-18 08:30:03 | B    | I     |       30 |  
2,381,449,046 | f         |
| 19,726 | FVG-SV-EEG | 2024-04-18 08:51:32 | B    | I     |        0 |         
     0 | A         |
| 19,767 | FVG-SV-EEG | 2024-04-19 09:00:11 | B    | I     |      138 | 
12,691,682,035 | T         |
| 19,887 | FVG-SV-EEG | 2024-04-22 09:00:45 | B    | I     |       83 |  
2,603,861,904 | T         |
| 19,930 | FVG-SV-EEG | 2024-04-23 12:00:44 | B    | I     |        0 |         
     0 | E         |
| 19,973 | FVG-SV-EEG | 2024-04-24 12:01:18 | B    | I     |        0 |         
     0 | E         |
| 20,016 | FVG-SV-EEG | 2024-04-25 13:00:59 | B    | I     |        0 |         
     0 | E         |
| 20,059 | FVG-SV-EEG | 2024-04-26 09:00:42 | B    | I     |       34 |  
2,002,216,571 | T         |
| 20,179 | FVG-SV-EEG | 2024-04-29 08:30:07 | B    | I     |        0 |         
     0 | A         |
| 20,222 | FVG-SV-EEG | 2024-04-30 12:00:42 | B    | I     |        0 |         
     0 | E         |
| 20,265 | FVG-SV-EEG | 2024-05-01 12:00:46 | B    | I     |        0 |         
     0 | E         |
| 20,308 | FVG-SV-EEG | 2024-05-02 15:33:18 | B    | I     |        0 |         
     0 | f         |
| 20,351 | FVG-SV-EEG | 2024-05-03 08:30:05 | B    | I     |        0 |         
     0 | A         |
| 20,471 | FVG-SV-EEG | 2024-05-06 09:00:10 | B    | I     |        0 |         
     0 | A         |
| 20,514 | FVG-SV-EEG | 2024-05-07 12:01:18 | B    | I     |        0 |         
     0 | E         |
| 20,557 | FVG-SV-EEG | 2024-05-08 16:00:49 | B    | I     |        0 |         
     0 | A         |
| 20,601 | FVG-SV-EEG | 2024-05-09 08:30:34 | B    | I     |        0 |         
     0 | R         |
+--------+------------+---------------------+------+-------+----------+----------------+-----------+

EG, all volumes marked as 'Used' (so, at least for me, with 6 jobs inside),
terminated jobs scattered around different volumes, and backup clearly
'stalled'.

I've three question.

1) Volumes get marked 'Used' when they reach 6 jobs in a volume.

  26-Apr 09:00 lnfbacula-dir JobId 20059: Max Volume jobs=6 exceeded. Marking 
Volume "EEG004" as Used.

 but get 'purged' only when there's no more jobs whithin? So if i scatter
 jobs within volumes, i quickly exaust the volumes, right?

 Also, even if i'm sure that volume X have less then 6 jobs, if i force it:

        *update volume=EEG001 volstatus=Append
        New Volume status is: Append

 quickly bacula:

        09-May 15:54 lnfbacula-dir JobId 0: Max Volume jobs=6 exceeded. Marking 
Volume "EEG001" as Used.

 put it on Used state.


2) There's some way i can get the 'jobs in volume X'? I can query jobs for
 volume, but i've not found a way to query volumes for jobs


3) In this setup failed jobs make only noise; there's some way to delete/purge
 failed jobs?

 Or there's some way i can setup the 'RunScript {}' job property to delete
 failed jobs?



Thanks.

-- 
  Il backup รจ quella cosa che andava fatta prima.
                                        (Proverbio Cinese, Simone Aliprandi)




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

Reply via email to