Hello Nick,

On Fri, Nov 25, 2022 at 4:00 PM Nick Bright <nbri...@kwikom.com> wrote:

> On 11/25/22 04:45, Ana Emília M. Arruda wrote:
> The easiest way is to allow Bacula to automatically prune Jobs and Files
> from the Catalog. It means to have "AutoPrune = Yes" in both the Client
> resource and in the Pool resource.
> I already had AutoPrune = yes in both the client and pool; I had found
> this in my searches before posting here.
> All backups over the weekend failed with "need more volumes".
Can you share your pool resource configuration here? Bacula has many
directives to different ways to recycle volumes, it would be nice to see
how you have the pool configured.

> Now, to force the prune of volumes that have the VolumeRetention (value
> defined in the Pool resource) expired, the command is:
> * prune volume expired yes
> This command is dangerous, it will delete all jobs and files associated
> with any volume by comparing only the "VolumeRetention" of the volume. This
> value is defined in the Pool resource, but it is specific for a volume and
> Bacula will check the value in the "volretention" field in the Media table
> in the Bacula database for each volume.
> This command still reports nothing to prune for all 310 volumes as of this
> morning, and I had run "update volume fromallpools" last week after
> reducing retention times; though it does now report the volumes as "Expired"
> Then running the command again, it gives me some prompts about pruning
> files/jobs/volume/stats/snapshots/events then a client to choose.
Right. This is expected.

> I choose a client, it reports "Pruned Files from 6 Jobs for client" and
> pending backups started executing.
Ok, so you got volumes pruned and reused.

> Then, to truncate volumes you must have the following configuration in the
> Pool resource:
> ActionOnPurge = Truncate
> Already had this present as well.

> After that, you will be able to "truncate volumes in Purged status" using
> the following command:
> * truncate volume allpools storage=File1
> This command reports "No volumes found to perform the command"
This command will only apply to volumes in "Purged" status. If they have
been reused, there will be no volume to truncate. Please check if it works
having at least one volume in Purged status.

> So; with your help I see how to manually prune files, but this seems
> inelegant. The system should automatically be pruning or at least allowing
> me to overwrite the old data - it ought to be cyclical - use the available
> disk space (17T) to back up systems, letting old backups fall off
> automatically so that new backups can take their place.
> Is needing to manually remove stale backups the intended behavior of the
> system, or have I done something incorrectly?
Bacula will automatically reuse volumes, but it will not destroy data if
the retention hasn't expired yet.
It would be nice if you could share the pool resource configuration and a
job log reporting no volume available to use.
The best approach is to reuse volumes as soon as they have retention
expired,  but to not keep the pool too tight as it may happen Bacula can't
create a new volume or reuse any.
Limiting the pool size (in bytes or in number of volumes) and keeping a
retention that can fit into this pool size is ideal.


> ---------------------------------
> -  Nick Bright                  -
> -  KwiKom Communications        -
> -  Office 800-379-7292          -
> -  Direct 620-228-5653          -
> -  Web https://www.kwikom.com/  -
> ---------------------------------
Bacula-users mailing list

Reply via email to